forked from OSchip/llvm-project
Fix for loop sign fix in r282112 for column = 0
llvm-svn: 282119
This commit is contained in:
parent
24c073d1bb
commit
0509203952
|
@ -172,7 +172,7 @@ size_t SourceManager::DisplaySourceLinesWithLineNumbersUsingLastFile(
|
|||
m_last_file_sp->GetLine(line, src_line);
|
||||
return_value += s->Printf(" \t");
|
||||
// Insert a space for every non-tab character in the source line.
|
||||
for (size_t i = 0; i < column - 1 && i < src_line.length(); ++i)
|
||||
for (size_t i = 0; i + 1 < column && i < src_line.length(); ++i)
|
||||
return_value += s->PutChar(src_line[i] == '\t' ? '\t' : ' ');
|
||||
// Now add the caret.
|
||||
return_value += s->Printf("^\n");
|
||||
|
|
Loading…
Reference in New Issue