[PATCH] D28559: [ELF] - Do not crash if user section has name equal to one of synthetic sections.
Rafael Avila de Espindola via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 11 11:45:42 PST 2017
Rui Ueyama via Phabricator <reviews at reviews.llvm.org> writes:
> ruiu added inline comments.
>
>
> ================
> Comment at: ELF/InputSection.cpp:38-41
> + // File can absent if section is synthetic.
> + if (!Sec->getFile())
> + return ("'" + Sec->Name + "'").str();
> return (Sec->getFile()->getName() + ":(" + Sec->Name + ")").str();
> ----------------
> If a section is a synthetic section, it's output will be something like
>
> 'foo'
>
> while if it is not, it will be something like
>
> bar.o:(foo)
>
> So, apparently they are inconsistent in quoting style. That's not good.
Would you prefer
(foo)
and
bar.o:(foo)
Cheers,
Rafael
More information about the llvm-commits
mailing list