| Issue |
107674
|
| Summary |
[Clang] warning and error diagnostics when using VLAs at global scope
|
| Labels |
clang:diagnostics
|
| Assignees |
|
| Reporter |
philnik777
|
When having `-Wvla-cxx-extension` enabled, Clang diagnoses a global declaration with both a warninga and an error. It would be nice if the warning was suppressed, since it's basically useless when you can't write the code anyways.
```c++
int i = 4;
int arr[i]; // Warns about VLAs and diagnoses that they can't be used at file scope.
```
FWIW a note that `i` isn't a constant _expression_ would also be nice.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs