Skip to content

Commit 854cce2

Browse files
[ProfileData] Remove an unnecessary cast (NFC) (#148341)
getBufferStart() already returns const char *.
1 parent f1791c0 commit 854cce2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/ProfileData/SampleProfReader.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1839,7 +1839,7 @@ std::error_code SampleProfileReaderGCC::readImpl() {
18391839
}
18401840

18411841
bool SampleProfileReaderGCC::hasFormat(const MemoryBuffer &Buffer) {
1842-
StringRef Magic(reinterpret_cast<const char *>(Buffer.getBufferStart()));
1842+
StringRef Magic(Buffer.getBufferStart());
18431843
return Magic == "adcg*704";
18441844
}
18451845

0 commit comments

Comments
 (0)