forked from OSchip/llvm-project
Don't assert that a size_t fits into 64bit.
Avoids tautological compare warnings on 32bit platforms. llvm-svn: 337269
This commit is contained in:
parent
1f1dc636d3
commit
7f457d79ec
|
@ -136,7 +136,6 @@ SourceMgr::getLineAndColumn(SMLoc Loc, unsigned BufferID) const {
|
||||||
const char *Ptr = Loc.getPointer();
|
const char *Ptr = Loc.getPointer();
|
||||||
|
|
||||||
size_t Sz = SB.Buffer->getBufferSize();
|
size_t Sz = SB.Buffer->getBufferSize();
|
||||||
assert(Sz <= std::numeric_limits<uint64_t>::max());
|
|
||||||
unsigned LineNo;
|
unsigned LineNo;
|
||||||
if (Sz <= std::numeric_limits<uint8_t>::max())
|
if (Sz <= std::numeric_limits<uint8_t>::max())
|
||||||
LineNo = SB.getLineNumber<uint8_t>(Ptr);
|
LineNo = SB.getLineNumber<uint8_t>(Ptr);
|
||||||
|
|
Loading…
Reference in New Issue