From baba78daf2b3a3ee9bfa21f1f8ff3584aa982ac8 Mon Sep 17 00:00:00 2001 From: Andrew Ng Date: Mon, 10 Jun 2024 19:39:28 +0100 Subject: [clang] Fix loss of `dllexport` for exported template specialization (#94664) When dropping DLL attributes, ensure that the most recent declaration is being checked. --- clang/lib/CodeGen/CodeGenModule.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'clang/lib/CodeGen/CodeGenModule.h') diff --git a/clang/lib/CodeGen/CodeGenModule.h b/clang/lib/CodeGen/CodeGenModule.h index dc24971..9b63f47 100644 --- a/clang/lib/CodeGen/CodeGenModule.h +++ b/clang/lib/CodeGen/CodeGenModule.h @@ -1594,6 +1594,8 @@ public: } private: + bool shouldDropDLLAttribute(const Decl *D, const llvm::GlobalValue *GV) const; + llvm::Constant *GetOrCreateLLVMFunction( StringRef MangledName, llvm::Type *Ty, GlobalDecl D, bool ForVTable, bool DontDefer = false, bool IsThunk = false, -- cgit v1.1