[PATCH] D39186: LLD: Fix large integer implicitly truncated to unsigned type warning

Konstantin Zhuravlyov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 23 09:26:43 PDT 2017


kzhuravl created this revision.
Herald added subscribers: wdng, emaste.

Patch by @b-sumner


https://reviews.llvm.org/D39186

Files:
  ELF/InputSection.h


Index: ELF/InputSection.h
===================================================================
--- ELF/InputSection.h
+++ ELF/InputSection.h
@@ -215,7 +215,7 @@
 // be found by looking at the next one) and put the hash in a side table.
 struct SectionPiece {
   SectionPiece(size_t Off, uint32_t Hash, bool Live)
-      : InputOff(Off), Hash(Hash), OutputOff(-1),
+      : InputOff(Off), Hash(Hash), OutputOff(0x7fffffffffffffffUL),
         Live(Live || !Config->GcSections) {}
 
   uint32_t InputOff;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39186.119872.patch
Type: text/x-patch
Size: 502 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171023/1f0c481a/attachment.bin>


More information about the llvm-commits mailing list