diff --git a/lld/ELF/Symbols.cpp b/lld/ELF/Symbols.cpp index ce1e89f2d080..497db842bc9b 100644 --- a/lld/ELF/Symbols.cpp +++ b/lld/ELF/Symbols.cpp @@ -254,10 +254,9 @@ void Symbol::parseSymbolVersion(Ctx &ctx) { } void Symbol::extract(Ctx &ctx) const { - if (file->lazy) { - file->lazy = false; - parseFile(ctx, file); - } + assert(file->lazy); + file->lazy = false; + parseFile(ctx, file); } uint8_t Symbol::computeBinding(Ctx &ctx) const {