2. "enum as manifest constant". Use static or immutable/global. Compiler should be smart enough to avoid putting immutable integers/doubles into object file as variables.

But enums aren't only used for optimization. What if you want to use a constant at compile time, as a template parameter?

Reply via email to