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:
Argyrios Kyrtzidis 2011-09-19 20:40:38 +00:00
parent 7c06d8666b
commit 27bf76d6d2
1 changed files with 1 additions and 1 deletions

View File

@ -320,7 +320,7 @@ void CodeGenAction::ExecuteAction() {
TheModule.reset(ParseIR(MainFileCopy, Err, *VMContext));
if (!TheModule) {
// Translate from the diagnostic info to the SourceManager location.
SourceLocation Loc = SM.getLocation(
SourceLocation Loc = SM.translateFileLineCol(
SM.getFileEntryForID(SM.getMainFileID()), Err.getLineNo(),
Err.getColumnNo() + 1);