[PATCH] D43008: [ELF] Process linker scripts deeper when declaring symbols.
George Rimar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 7 03:19:58 PST 2018
grimar added a comment.
Looks fine for me. Suggestions below.
================
Comment at: ELF/LinkerScript.cpp:173
assert(!Ctx);
- for (BaseCommand *Base : SectionCommands) {
+ auto Fn = [](BaseCommand *Base) {
auto *Cmd = dyn_cast<SymbolAssignment>(Base);
----------------
It's large. I would make it static helper instead then.
(probably would change argument type to `SymbolAssignment*` too)
================
Comment at: test/ELF/linkerscript/version-script.s:8
+# RUN: echo "SECTIONS { .text : { bar = foo; *(.text) } } VERSION { V { global: foo; bar; local: *; }; }" > %t.script
+# RUN: ld.lld -T %t.script -shared --no-undefined-version %t.o -o %t.so
----------------
It should be multiline, because exceeds 80 columns per line limit.
Repository:
rLLD LLVM Linker
https://reviews.llvm.org/D43008
More information about the llvm-commits
mailing list