Skip to main content

Questions tagged [template-meta-programming]

For code that uses templates to generate compile-time executed code. For ordinary use of templates, use the 'template' tag instead.

2 votes
0 answers
182 views

This is my second iteration of implementing try_lock_for/try_lock_until function templates in which I've cherry-picked a bunch ...
Ted Lyngmo's user avatar
6 votes
1 answer
236 views

I'm writing a library of IO functions for my physics laboratory class. In the meanwhile, I'm hoping to learn more about generic programming and C++20 concepts. Some context I usually came home from ...
GeometriaDifferenziale's user avatar
2 votes
1 answer
117 views

Needed to do some Meta programming. I needed to check if a class has a specific member (one case a member variable second case a member type (two distinct use cases)). Since I am writing a library, I ...
Loki Astari's user avatar
  • 97.7k
7 votes
2 answers
258 views

Prior Notification This follows a previous review of mine that addressed the core helper function named make_skippable. The composition implementation presented ...
mahush's user avatar
  • 115
3 votes
1 answer
127 views

Below is a piece of template code which allows for adding a Tag to structure or class types. ...
Sam Coutteau's user avatar
3 votes
1 answer
172 views

I have a class template that stores an std::optional<T>. A very reduced version of the class template looks like this: ...
joergbrech's user avatar
4 votes
1 answer
1k views

I needed to find a way to convert a bunch of enums to string for displaying in C++. The two main ways I found when searching was using dark magic macros or voodoo magic template metaprogramming. As I ...
adepierre's user avatar
  • 135
4 votes
2 answers
253 views

I want to do template metaprogramming to compute the conversion from std::variant<Ts...> to ...
Tom Huntington's user avatar

15 30 50 per page
1
2 3 4 5
19