2 ms·
C++ now has constexpr, so that pro is now shared by both C++ and D, somewhat (ignoring templates, D is still more versatile). That being said, C++ template met
by zamalek 8y ago
C++ now has constexpr, so that pro is now shared by both C++ and D, somewhat (ignoring templates, D is still more versatile).
That being said, C++ template metaprogramming can be pretty elegant[1] (there was a video where she describes the template functional style, but it seems to have been deleted).
[1]: https://github.com/hanickadot/compile-time-regular-expressions https://github.com/hanickadot/compile-time-regular-expressio...
- WalterBright 8y agoconstexpr accretes more power with every iteration, but it's still got a ways to go: https://en.cppreference.com/w/cpp/language/constexpr https://en.cppreference.com/w/cpp/language/constexpr https://dlang.org/spec/function.html#interpretation https://dlang.org/spec/function.html#interpretation