[clang] [llvm] [PowerPC][AIX] Support #pragma comment copyright for AIX (PR #178184)
Wael Yehia via cfe-commits
cfe-commits at lists.llvm.org
Tue Mar 24 21:14:13 PDT 2026
================
@@ -3541,6 +3543,39 @@ void CodeGenModule::AddDependentLib(StringRef Lib) {
LinkerOptionsMetadata.push_back(llvm::MDNode::get(C, MDOpts));
}
+/// Process copyright pragma and create LLVM metadata.
+/// #pragma comment(copyright, "string") embeds copyright information into a
+/// loadable program-data section of the object file for inclusion in the linked
+/// module.
+///
+/// Example: #pragma comment(copyright, "Copyright string")
+///
+/// This should only be called once per translation unit.
+void CodeGenModule::ProcessPragmaComment(PragmaMSCommentKind Kind,
----------------
w2yehia wrote:
I would rename ProcessPragmaComment to ProcessPragmaCommentCopyright, and get rid of the Kind parameter. As it stands, it sounds like a handler of any pragma comment but the doxygen comment says it's for copyright; not consistent.
https://github.com/llvm/llvm-project/pull/178184
More information about the cfe-commits
mailing list