mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-02-04 08:16:49 +00:00
Fix off-by-two error printing diagnostics
llvm-svn: 38565
This commit is contained in:
parent
e60165fdb5
commit
4da3a353b6
@ -148,7 +148,7 @@ void DiagnosticPrinterSTDERR::HandleDiagnostic(Diagnostic::Level Level,
|
||||
// Compute the column number. Rewind from the current position to the start
|
||||
// of the line.
|
||||
ColNo = SourceMgr.getColumnNumber(Pos);
|
||||
LineStart = FilePos-ColNo-1; // Column # is 1-based
|
||||
LineStart = FilePos-ColNo+1; // Column # is 1-based
|
||||
|
||||
// Compute the line end. Scan forward from the error position to the end of
|
||||
// the line.
|
||||
|
Loading…
x
Reference in New Issue
Block a user