I have a class that contains several private static const member arrays. One of the arrays needs to be initialized using values from the other two. What is the rule on initialization order for these types of arrays? Is it the order they are declared in the class? I am concerned that arr3 may be initialized before arr1 or arr2.
.h file
class A
{
private:
static const float arr1[2];
static const float arr2[3];
static const float arr3[4];
};
The arrays can be initialized in any order the compiler feels like. If you need things to be initialized in a specific order, you'll have to do the initializations manually.