mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-01 12:24:24 +00:00
Fixing a cast-qual warning. getBufferStart() and getBufferEnd() both return a const char *, so casting to non-const was triggering a warning (even though the assignment and usage was always const anyway).
No functional changes intended. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207774 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -262,9 +262,10 @@ bool IndexedInstrProfReader::hasFormat(const MemoryBuffer &DataBuffer) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
error_code IndexedInstrProfReader::readHeader() {
|
error_code IndexedInstrProfReader::readHeader() {
|
||||||
const unsigned char *Start = (unsigned char *)DataBuffer->getBufferStart();
|
const unsigned char *Start =
|
||||||
|
(const unsigned char *)DataBuffer->getBufferStart();
|
||||||
const unsigned char *Cur = Start;
|
const unsigned char *Cur = Start;
|
||||||
if ((unsigned char *)DataBuffer->getBufferEnd() - Cur < 24)
|
if ((const unsigned char *)DataBuffer->getBufferEnd() - Cur < 24)
|
||||||
return error(instrprof_error::truncated);
|
return error(instrprof_error::truncated);
|
||||||
|
|
||||||
using namespace support;
|
using namespace support;
|
||||||
|
Reference in New Issue
Block a user