https://github.com/ojhunt created 
https://github.com/llvm/llvm-project/pull/196759

None

>From 2d896aa0e604901608f5a3bd297468ac4d8ffd17 Mon Sep 17 00:00:00 2001
From: Oliver Hunt <[email protected]>
Date: Sat, 9 May 2026 14:48:58 -0700
Subject: [PATCH] [clang][NFC] Actually add the testcase for #195416

---
 clang/test/SemaCXX/GH195416.cpp | 11 +++++++++++
 1 file changed, 11 insertions(+)
 create mode 100644 clang/test/SemaCXX/GH195416.cpp

diff --git a/clang/test/SemaCXX/GH195416.cpp b/clang/test/SemaCXX/GH195416.cpp
new file mode 100644
index 0000000000000..615bd23db1f0f
--- /dev/null
+++ b/clang/test/SemaCXX/GH195416.cpp
@@ -0,0 +1,11 @@
+// RUN: %clang_cc1 -std=c++20 -fsyntax-only -verify %s
+
+constexpr void gh195416() {
+  struct U {
+    struct S {};
+    static constexpr S S::bar;
+    // expected-error@-1 {{non-friend class member 'bar' cannot have a 
qualified name}}
+    // expected-error@-2 {{static data member 'bar' not allowed in local 
struct 'S'}}
+    // expected-error@-3 {{excess elements in struct initializer}}
+  };
+}

_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to