================
@@ -39,7 +39,8 @@ bool Sema::SetMemberAccessSpecifier(NamedDecl *MemberDecl,
                                     AccessSpecifier LexicalAS) {
   if (!PrevMemberDecl) {
     // Use the lexical access specifier.
-    MemberDecl->setAccess(LexicalAS);
----------------
shafik wrote:

I feel like we should be catching this in `Sema::ActOnTag` here:

https://github.com/llvm/llvm-project/blob/b49701085414838deb0213b9f10b68d9d3af6b0a/clang/lib/Sema/SemaDecl.cpp#L17938-L17951

It looks like we are not b/c `TUK` is `TUK_Declataion` but we should not be 
forward declaring here either. 

The current diagnostic does not fit this case though and maybe it has to be 
tweaked some more.

CC @AaronBallman 

https://github.com/llvm/llvm-project/pull/112424
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to