forked from OSchip/llvm-project
In CodeGenAction::ExecuteAction() use SourceManager::translateFileLineCol()
instead of getLocation() since we don't care about expanded macro arguments. llvm-svn: 140061
This commit is contained in:
parent
7c06d8666b
commit
27bf76d6d2
|
@ -320,7 +320,7 @@ void CodeGenAction::ExecuteAction() {
|
||||||
TheModule.reset(ParseIR(MainFileCopy, Err, *VMContext));
|
TheModule.reset(ParseIR(MainFileCopy, Err, *VMContext));
|
||||||
if (!TheModule) {
|
if (!TheModule) {
|
||||||
// Translate from the diagnostic info to the SourceManager location.
|
// Translate from the diagnostic info to the SourceManager location.
|
||||||
SourceLocation Loc = SM.getLocation(
|
SourceLocation Loc = SM.translateFileLineCol(
|
||||||
SM.getFileEntryForID(SM.getMainFileID()), Err.getLineNo(),
|
SM.getFileEntryForID(SM.getMainFileID()), Err.getLineNo(),
|
||||||
Err.getColumnNo() + 1);
|
Err.getColumnNo() + 1);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue