[clang] [Clang][Sema] Support 'counted_by' attribute on FAM/pointers in anonymous unions (PR #171996)
Oliver Hunt via cfe-commits
cfe-commits at lists.llvm.org
Fri Jan 9 13:50:25 PST 2026
================
@@ -26,14 +26,20 @@ getCountAttrKind(bool CountInBytes, bool OrNull) {
: CountAttributedType::CountedBy;
}
+// Check if a RecordDecl is anonymous or will be anonymous once processing
+// completes. The anonymous flag may not be set yet during parsing.
+static bool IsAnonymousOrWillBeAnonymous(const RecordDecl *RD) {
----------------
ojhunt wrote:
Yeah, I think this change in rules was not particularly aggressively pushed, and people tend to style match surrounding code :-/
I really think that if we are going to change rules around naming we should try to automate the change across the codebase to mitigate this :-/
https://github.com/llvm/llvm-project/pull/171996
More information about the cfe-commits
mailing list