[PATCH] D147920: [clang] Add test for CWG399

Shafik Yaghmour via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 11 10:18:39 PDT 2023


shafik added a subscriber: aaron.ballman.
shafik added inline comments.


================
Comment at: clang/test/CXX/drs/dr3xx.cpp:1439
+
+namespace dr399 { // dr399: 11
+                  // NB: reuse dr244 test 
----------------
Endill wrote:
> Despite a couple of FIXME in CWG244 test (out of dozens of examples), it claims full availability since Clang 11. I'd take a more conservative approach, declaring partial support, but I think that declaring different availability for the same test would bring unnecessary confusion. So I followed CWG244 availability.
> 
> Alternative is to demote CWG244 to partial, but I'm not sure we should go back on our claims for CWG support that has been out for so long.
I think the bugs are not awful, we should file bug reports if we don't already have them. Some of them seem like they should be not too bad to fix.

CC @aaron.ballman to get a second opinion


================
Comment at: clang/test/CXX/drs/dr3xx.cpp:1492
+    // This is technically ill-formed; G is looked up in 'N::' and is not found.
+    // Rejecting this seems correct, but most compilers accept, so we do also.
+    f.N::F::~G(); // expected-error {{qualified destructor name only found in lexical scope; omit the qualifier to find this type name by unqualified lookup}}
----------------
Endill wrote:
> shafik wrote:
> > You say we accept the next line but it has an `expected-error` on it?
> It's an error because of `-pedantic-errors`. It's a warning by default.
That makes a lot more sense, I was wondering what was I missing.

Can we note that in the comment b/c it is pretty confusing otherwise. 

I wonder if there is a good reason to not make this ill-formed by default? Worth a bug report.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D147920/new/

https://reviews.llvm.org/D147920



More information about the cfe-commits mailing list