diff options
Diffstat (limited to 'lld/ELF/LTO.cpp')
| -rw-r--r-- | lld/ELF/LTO.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lld/ELF/LTO.cpp b/lld/ELF/LTO.cpp index af873c6dd7c..f24327a139a 100644 --- a/lld/ELF/LTO.cpp +++ b/lld/ELF/LTO.cpp @@ -201,8 +201,10 @@ void BitcodeCompiler::add(BitcodeFile &F) { handleUndefinedAsmRefs(Sym, GV, AsmUndefinedRefs); continue; } - auto *B = dyn_cast<DefinedBitcode>(S->body()); - if (!B || B->file() != &F) + SymbolBody *B = S->body(); + if (B->kind() != SymbolBody::DefinedRegularKind) + continue; + if (B->File != &F) continue; // We collect the set of symbols we want to internalize here |

