[PATCH] D96109: Refactor implementation of -funique-internal-linkage-names.
David Blaikie via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Feb 18 10:48:36 PST 2021
dblaikie added inline comments.
================
Comment at: clang/lib/CodeGen/CodeGenModule.cpp:5561
+ // the mangler will not do the right thing without one.
+ if (D->getKind() == Decl::Function && !getLangOpts().CPlusPlus &&
+ cast<FunctionDecl>(D)->getType()->getAs<FunctionProtoType>() &&
----------------
aaron.ballman wrote:
> It's a bit novel to add the attribute at codegen time rather than at sema -- is there a reason this attribute should not be added to the AST from within Sema?
How would it be if this didn't use an attribute at all? If this checking was done in ItaniumMangle directly, rather than checking done here, transforming the result of the checking into an attribute, and then checking the attribute later?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D96109/new/
https://reviews.llvm.org/D96109
More information about the llvm-commits
mailing list