[llvm] r362084 - [llvm-readobj] - An attemp to fix BB.
George Rimar via llvm-commits
llvm-commits at lists.llvm.org
Thu May 30 03:42:47 PDT 2019
Author: grimar
Date: Thu May 30 03:42:47 2019
New Revision: 362084
URL: http://llvm.org/viewvc/llvm-project?rev=362084&view=rev
Log:
[llvm-readobj] - An attemp to fix BB.
BB failed:
http://lab.llvm.org:8011/builders/clang-armv7-linux-build-cache/builds/15062/steps/build%20stage%201/logs/stdio
Error was:
/home/buildslave/buildslave/clang-armv7-linux-build-cache/llvm/tools/llvm-readobj/ELFDumper.cpp:3540:7:
error: non-constant-expression cannot be narrowed from type 'llvm::support::detail::packed_endian_specific_integral<unsigned long long,
llvm::support::endianness::little, 1>::value_type' (aka 'unsigned long long') to 'size_t' (aka 'unsigned int') in initializer list [-Wc++11-narrowing]
StrTabSec->sh_size};
Modified:
llvm/trunk/tools/llvm-readobj/ELFDumper.cpp
Modified: llvm/trunk/tools/llvm-readobj/ELFDumper.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-readobj/ELFDumper.cpp?rev=362084&r1=362083&r2=362084&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-readobj/ELFDumper.cpp (original)
+++ llvm/trunk/tools/llvm-readobj/ELFDumper.cpp Thu May 30 03:42:47 2019
@@ -3524,7 +3524,7 @@ void GNUStyle<ELFT>::printVersionDefinit
const Elf_Shdr *StrTabSec = unwrapOrError(Obj->getSection(Sec->sh_link));
StringRef StringTable(
reinterpret_cast<const char *>(Obj->base() + StrTabSec->sh_offset),
- StrTabSec->sh_size);
+ (size_t)StrTabSec->sh_size);
const uint8_t *VerdefBuf = unwrapOrError(Obj->getSectionContents(Sec)).data();
const uint8_t *Begin = VerdefBuf;
@@ -3568,7 +3568,7 @@ void GNUStyle<ELFT>::printVersionDepende
const Elf_Shdr *StrTabSec = unwrapOrError(Obj->getSection(Sec->sh_link));
StringRef StringTable = {
reinterpret_cast<const char *>(Obj->base() + StrTabSec->sh_offset),
- StrTabSec->sh_size};
+ (size_t)StrTabSec->sh_size};
const uint8_t *VerneedBuf = SecData.data();
for (unsigned I = 0; I < VerneedNum; ++I) {
More information about the llvm-commits
mailing list