3 ms·
I'm surprised they don't support C++11 user-defined literals[1]. That seems like a perfect fit for stuff like this. [1] https://en.wikipedia.org/wiki/C%2B%2B11
by ginko 11y ago
I'm surprised they don't support C++11 user-defined literals[1]. That seems like a perfect fit for stuff like this.
[1] https://en.wikipedia.org/wiki/C%2B%2B11#User-defined_literals https://en.wikipedia.org/wiki/C%2B%2B11#User-defined_literal...
- adsche 11y agoI don't know, they would have to encode two template arguments, one of which is a freely-chosen integer, into a number of suffixes. I'd say, leave that to the user. The user can define literals for the type/exponent combinations they will use often.