This is an archive of the discontinued LLVM Phabricator instance.

[NFC] Fix compiler warnings due to integer comparison of different signedness
ClosedPublic

Authored by nullptr.cpp on Sep 9 2020, 12:09 AM.

Diff Detail

Event Timeline

nullptr.cpp created this revision.Sep 9 2020, 12:09 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptSep 9 2020, 12:09 AM
nullptr.cpp requested review of this revision.Sep 9 2020, 12:09 AM

I don't have commit access, can anyone help me commit this and D86997?
Yang Fan <nullptr.cpp@gmail.com>
Thanks!

RKSimon added a subscriber: RKSimon.

Couldn't we avoid a lot of this of this casting + template ugliness by just using the <climit> / <cstdint> INT_MAX / INT32_MAX defines?

hiraditya accepted this revision.Sep 9 2020, 9:51 AM
This revision is now accepted and ready to land.Sep 9 2020, 9:51 AM

Fix by directly using INT_MAX and INT32_MAX.

nullptr.cpp edited the summary of this revision. (Show Details)Sep 9 2020, 7:28 PM

I don't have commit access, can anyone help me commit this with "Yang Fan <nullptr.cpp@gmail.com>" ?
Thanks!

This comment was removed by nullptr.cpp.
RKSimon accepted this revision.Sep 10 2020, 5:01 AM

LGTM - I'll try to commit this later today