[PATCH] D58280: [yaml2obj][obj2yaml] - Support SHT_GNU_versym (.gnu.version) section.
George Rimar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 19 02:15:14 PST 2019
grimar marked 3 inline comments as done.
grimar added inline comments.
================
Comment at: tools/yaml2obj/yaml2elf.cpp:563
+
+ auto &OS = CBA.getOSAndAlignedOffset(SHeader.sh_offset, SHeader.sh_addralign);
+ for (uint16_t V : Section.Entries) {
----------------
jhenderson wrote:
> I don't know what the type here is, so best not to use auto, I think.
Generally, I follow the same rule, but the whole file use `auto`, so I did that for consistency.
Perhaps it is a good idea to fix it though.
================
Comment at: tools/yaml2obj/yaml2elf.cpp:565
+ for (uint16_t V : Section.Entries) {
+ Elf_Half Version = (Elf_Half)V;
+ OS.write((const char *)&Version, sizeof(Elf_Half));
----------------
jhenderson wrote:
> Do you need this cast here? It looks superfluous.
Yep :(, MSVS2017 complains:
error C2440: 'initializing': cannot convert from 'uint16_t' to 'llvm::support::detail::packed_endian_specific_integral<uint16_t,llvm::support::little,1>'
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D58280/new/
https://reviews.llvm.org/D58280
More information about the llvm-commits
mailing list