I would like your opinion.
I use:
constexpr only for constant values
const for values that will become constant as parameters of functions, classes and functions.
but I didn’t notice a difference between the two, just a difference in good use.
Like typename and class in templates
DanM
2
constexpr everywhere you can, otherwise const.
constexpr > const > nothing
See here on the difference:
system
Closed
5
This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.