3 ms·
That is not guaranteed either: "If the size expression of a VLA has side effects, they are guaranteed to be produced except when it is a part of a sizeof expre
by haspok 7y ago
That is not guaranteed either:
"If the size expression of a VLA has side effects, they are guaranteed to be produced except when it is a part of a sizeof expression whose result doesn't depend on it."
(from: https://en.cppreference.com/w/c/language/array https://en.cppreference.com/w/c/language/array)
In the example this is not a problem, because int[printf()] means you must call printf() to get the return value and determine the size of the array.