You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(1): error C2131: expression did not evaluate to a constant
(1): note: failure was caused by a read of a variable outside its lifetime
(1): note: see usage of 'n'
Compiler returned: 2
GCC reports a similar error:
error: use of parameter outside function body before ‘]’ token
However, the clang++ in this project does not report any errors.
The text was updated successfully, but these errors were encountered:
The code is as follows:
void bar(int n, int x[n]) {}
MSVC reports an error:
GCC reports a similar error:
error: use of parameter outside function body before ‘]’ token
However, the clang++ in this project does not report any errors.
The text was updated successfully, but these errors were encountered: