[PATCH] D38955: LLD/ELF: Fix C4307: '-': integral constant overflow for MSVC15
Konstantin Zhuravlyov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 16 11:33:59 PDT 2017
kzhuravl updated this revision to Diff 119187.
kzhuravl added a comment.
Just revert.
https://reviews.llvm.org/D38955
Files:
ELF/SymbolTable.cpp
ELF/SymbolTable.h
Index: ELF/SymbolTable.h
===================================================================
--- ELF/SymbolTable.h
+++ ELF/SymbolTable.h
@@ -103,8 +103,9 @@
void assignWildcardVersion(SymbolVersion Ver, uint16_t VersionId);
struct SymIndex {
- int32_t Idx : 31;
- uint32_t Traced : 1;
+ SymIndex(int Idx, bool Traced) : Idx(Idx), Traced(Traced) {}
+ int Idx : 31;
+ unsigned Traced : 1;
};
// The order the global symbols are in is not defined. We can use an arbitrary
Index: ELF/SymbolTable.cpp
===================================================================
--- ELF/SymbolTable.cpp
+++ ELF/SymbolTable.cpp
@@ -240,13 +240,13 @@
Name = Name.take_front(Pos);
auto P = Symtab.insert(
- {CachedHashStringRef(Name), SymIndex{(int)SymVector.size(), false}});
+ {CachedHashStringRef(Name), SymIndex((int)SymVector.size(), false)});
SymIndex &V = P.first->second;
bool IsNew = P.second;
if (V.Idx == -1) {
IsNew = true;
- V = SymIndex{(int)SymVector.size(), true};
+ V = SymIndex((int)SymVector.size(), true);
}
Symbol *Sym;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D38955.119187.patch
Type: text/x-patch
Size: 1104 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171016/6ddc76b4/attachment.bin>
More information about the llvm-commits
mailing list