propagate linemarker flags down into the the line table, currently
ignoring include stack push/pop info though.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63719 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Lex/PPDirectives.cpp b/lib/Lex/PPDirectives.cpp
index fa57ab3..1548792 100644
--- a/lib/Lex/PPDirectives.cpp
+++ b/lib/Lex/PPDirectives.cpp
@@ -693,7 +693,7 @@
PP.Lex(FlagTok);
if (FlagTok.is(tok::eom)) return false;
- if (GetLineValue(FlagTok, FlagVal, diag::err_pp_linemarker_invalid_flag,PP))
+ if (GetLineValue(FlagTok, FlagVal, diag::err_pp_linemarker_invalid_flag, PP))
return true;
// We must have 4 if there is yet another flag.
@@ -761,9 +761,11 @@
IsSystemHeader, IsExternCHeader, *this))
return;
}
-
- // FIXME: do something with the #line flag info.
- SourceMgr.AddLineNote(DigitTok.getLocation(), LineNo, FilenameID);
+
+ // Create a line note with this information.
+ SourceMgr.AddLineNote(DigitTok.getLocation(), LineNo, FilenameID,
+ IsFileEntry, IsFileExit,
+ IsSystemHeader, IsExternCHeader);
}