[clang] [Clang][NFC] Add test for CWG2285 "Issues with structured bindings" (PR #126421)

Vlad Serebrennikov via cfe-commits cfe-commits at lists.llvm.org
Mon Feb 24 06:19:13 PST 2025


================
@@ -196,6 +196,16 @@ void g() {
 #endif
 } // namespace cwg2277
 
+namespace cwg2285 { // cwg2285: 4
----------------
Endilll wrote:

You're right, Clang 4 behaves as expected without `#if __cplusplus`.

> Do I need to add this note in test file?

Yes, leave a comment somewhere that Clang 4 doesn't pass the test because of the wrong value of `__cplusplus`, even though it implements the DR.

https://github.com/llvm/llvm-project/pull/126421


More information about the cfe-commits mailing list