================
@@ -0,0 +1,70 @@
+// RUN: %clang_cc1 -std=gnu++20 -verify %s
+
+int foo();
+
+// VLA alias used in normal function scope — no error.
+int test0() {
+ using X = int[foo()];
+ X x;
+ return 0;
+}
+
+// VLA alias declared inside the local class itself — no error.
+int test1() {
+ struct S {
+ using X = int[foo()];
----------------
efriedma-quic wrote:
I suspect we should reject this. But probably makes sense to deal with that in
a separate patch. (I think we want to reject the typedef itself because it's
not clear when to evaluate it. Basically the same reason we reject a variably
modified type in a non-local class.)
https://github.com/llvm/llvm-project/pull/183933
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits