DLL linkage is decoupled from linkage in LLVM 3.5.

This commit is contained in:
Kai Nacke
2014-01-19 11:02:27 +01:00
parent 87afa717ae
commit a39e5582e6
2 changed files with 10 additions and 2 deletions

View File

@@ -494,7 +494,11 @@ bool GarbageCollect2Stack::runOnFunction(Function &F) {
// Ignore indirect calls and calls to non-external functions.
Function *Callee = CS.getCalledFunction();
if (Callee == 0 || !Callee->isDeclaration() ||
!(Callee->hasExternalLinkage() || Callee->hasDLLImportLinkage()))
!(Callee->hasExternalLinkage()
#if LDC_LLVM_VER < 305
|| Callee->hasDLLImportLinkage()
#endif
))
continue;
// Ignore unknown calls.