[llvm] d60a65a - Fix for D119899
David Blaikie via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 3 21:23:22 PST 2022
Author: David Blaikie
Date: 2022-03-04T05:19:51Z
New Revision: d60a65abb6b050e10d9efdbc56dcb2e2e4772af1
URL: https://github.com/llvm/llvm-project/commit/d60a65abb6b050e10d9efdbc56dcb2e2e4772af1
DIFF: https://github.com/llvm/llvm-project/commit/d60a65abb6b050e10d9efdbc56dcb2e2e4772af1.diff
LOG: Fix for D119899
Added:
Modified:
llvm/lib/TableGen/Parser.cpp
Removed:
################################################################################
diff --git a/llvm/lib/TableGen/Parser.cpp b/llvm/lib/TableGen/Parser.cpp
index 47882c8524ab5..0ccd564bef23d 100644
--- a/llvm/lib/TableGen/Parser.cpp
+++ b/llvm/lib/TableGen/Parser.cpp
@@ -21,6 +21,7 @@ bool llvm::TableGenParseFile(std::unique_ptr<MemoryBuffer> Buffer,
RecordKeeper Records;
Records.saveInputFilename(Buffer->getBufferIdentifier().str());
+ SrcMgr = SourceMgr();
SrcMgr.AddNewSourceBuffer(std::move(Buffer), SMLoc());
SrcMgr.setIncludeDirs(IncludeDirs);
TGParser Parser(SrcMgr, /*Macros=*/None, Records);
More information about the llvm-commits
mailing list