[lld][MachO] Fix -Wsign-compare warning (NFC)

GCC warning:
```
/llvm-project/lld/MachO/InputFiles.cpp:484:24: warning: comparison of integer expressions of different signedness: ‘int64_t’ {aka ‘long int’} and ‘uint64_t’ {aka ‘long unsigned int’} [-Wsign-compare]
484 |           return value < subsectionEntry.offset;
    |                  ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
```
This commit is contained in:
Yang Fan 2021-04-02 11:25:20 +08:00
parent c664769330
commit d441dee5c2
No known key found for this signature in database
GPG Key ID: 717E4EB972E515EF
1 changed files with 1 additions and 1 deletions

View File

@ -480,7 +480,7 @@ void ObjFile::parseSymbols(ArrayRef<structs::nlist_64> nList,
uint64_t offset = sym.n_value - sec.addr;
auto it = llvm::upper_bound(
subsecMap, offset, [](int64_t value, SubsectionEntry subsectionEntry) {
subsecMap, offset, [](uint64_t value, SubsectionEntry subsectionEntry) {
return value < subsectionEntry.offset;
});
uint32_t size = it != subsecMap.end()