All Posts

Compile Time Aggregate Introspection in C++20 - part 1: Counting Fields

Recently, there have been a number of “reflection” libraries in C++20 that purport to be pure, standard C++. I’ve worked with and on various attempts at compile time reflection in C++ through the years and have never really come up with anythig fully satisfactory. It’s done the work, but the syntax the user has to use has never really been what I’d call “natuaral”. Now it has been accomplished in a pretty clean, approachable way by a few different libraries.

Read more ...