C++: Expression must have a constant value when declaring array inside function
There is a misconception here with what const means, probably because it’s a little confusing that this works: but this doesn’t: The issue is that the array size in an array declaration must be a core constant expression. Simplified, that means an expression that’s evaluatable at compile time to be a constant. That is true in the … Read more