
The goal of this article is to use reflection, to write a template function, in order to determine if the template type parameter is containing padding. We will see, how I first took a way to complex road, but I decided to keep it in the article, since it allows to use a few more…

The compiler generates special member functions, according to different rules. These have been described, and have been summarized in a nice table, known as “Howard Hinnants’ table” (https://howardhinnant.github.io/smf.jpg, https://howardhinnant.github.io/classdecl.html). By using reflection we can verify, if this is indeed correct (which it is), as such we will refresh our knowledge of the table, and see…

Parsing program options, most of us re-invented that wheel, or at a given moment we stopped doing that and for example switched to the boost libraries. We define some option “–foo value” (or things like –foo=value …), we loop over the program arguments, try to see if they contain our –foo, parse the next one,…

I know, I am busy writing on modules, but reflection is so important and powerful, I have to write something about that first. So I choose a little practical example for making your custom types printable. Our Mission The challenge of this article is to write a universal printer/formatter, so that we can format (nearly)…