forked from OSchip/llvm-project
Use a temporary varaible to improve readability. NFC.
llvm-svn: 314120
This commit is contained in:
parent
9297af60db
commit
f5db0b36ff
|
@ -436,15 +436,11 @@ void LinkerScript::fabricateDefaultCommands() {
|
|||
for (auto &KV : Config->SectionStartMap)
|
||||
StartAddr = std::min(StartAddr, KV.second);
|
||||
|
||||
auto Expr = [=] {
|
||||
return std::min(StartAddr, Config->ImageBase + elf::getHeaderSize());
|
||||
};
|
||||
Opt.Commands.insert(Opt.Commands.begin(),
|
||||
make<SymbolAssignment>(".",
|
||||
[=] {
|
||||
return std::min(
|
||||
StartAddr,
|
||||
Config->ImageBase +
|
||||
elf::getHeaderSize());
|
||||
},
|
||||
""));
|
||||
make<SymbolAssignment>(".", Expr, ""));
|
||||
}
|
||||
|
||||
// Add sections that didn't match any sections command.
|
||||
|
|
Loading…
Reference in New Issue