[PATCH] D120812: [AST] Use RecoveryExpr to model a DeclRefExpr which refers to an invalid Decl.
Sam McCall via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Mar 2 07:03:21 PST 2022
sammccall accepted this revision.
sammccall added a comment.
This revision is now accepted and ready to land.
Very nice! I thought we had considered and rejected this in the past, but I think it was rather allowing lookup to find invalid decls in cases where it doesn't today.
================
Comment at: clang/test/SemaCXX/constructor-initializer.cpp:252
B(const String& s, int e=0) // expected-error {{unknown type name}}
- : A(e), m_String(s) , m_ErrorStr(__null) {} // expected-error {{no matching constructor}} expected-error {{does not name}}
+ : A(e), m_String(s) , m_ErrorStr(__null) {} // expected-error {{no matching constructor}} expected-error {{does not name}} expected-error {{member initializer 'm_ErrorStr' does not name}}
B(const B& e)
----------------
update the other expected-error to to say what it refers to, too?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D120812/new/
https://reviews.llvm.org/D120812
More information about the cfe-commits
mailing list