AaronBallman wrote: > Propagating the abi tag from the first namespace declaration to later > declarations is fine; the problem is propagating tags backwards.
+1, it's pretty normal behavior for attributes to be (inherited and) additive on redeclarations. But propagating attribute information backwards is generally not something we do. In those cases, we usually require the first declaration to carry all the information instead. > In terms of the implementation, the way this patch is written, it has the > side-effect that the mangling of a symbol depends on when we decide to mangle > it. We typically don't wait for the end of the translation unit before we > start mangling values. Yeah, that seems be problematic. For example, we sometimes need to get the mangled name for things as part of diagnostic checking: https://github.com/llvm/llvm-project/blob/ddc7d4b3b43be5ef26671c19035761fb84a40388/clang/lib/Sema/SemaDeclAttr.cpp#L1761 https://github.com/llvm/llvm-project/pull/224826 _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
