mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-26 09:18:56 +00:00
Fix FileCheck crash when fuzzy scanning starting at the end of the file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@90065 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -398,7 +398,7 @@ void Pattern::PrintFailureInfo(const SourceMgr &SM, StringRef Buffer,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (BestQuality < 50) {
|
if (Best != StringRef::npos && BestQuality < 50) {
|
||||||
// Print the "possible intended match here" line if we found something
|
// Print the "possible intended match here" line if we found something
|
||||||
// reasonable.
|
// reasonable.
|
||||||
SM.PrintMessage(SMLoc::getFromPointer(Buffer.data() + Best),
|
SM.PrintMessage(SMLoc::getFromPointer(Buffer.data() + Best),
|
||||||
|
Reference in New Issue
Block a user