================
@@ -142,7 +142,7 @@ constexpr int arb(int n) { // expected-note {{declared 
here}}
                expected-note {{function parameter 'n' with unknown value 
cannot be used in a constant expression}}
 }
 constexpr long Overflow[(1 << 30) << 2]{}; // expected-warning {{requires 34 
bits to represent}} \
-                                              expected-warning {{variable 
length array folded to constant array as an extension}} \
+                                              expected-error {{variable length 
array declaration not allowed at file scope}} \
----------------
efriedma-quic wrote:

The diagnostic shouldn't be hard to fix; it's just a matter of using the form 
of Evaluate() that returns notes.

For the actual behavior here... we could pass the flag to allow undefined 
behavior when we do this folding, I guess, but I'd rather not.  Or if we do, it 
should be a DefaultError diagnostic.

https://github.com/llvm/llvm-project/pull/99579
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to