[PATCH] D66466: [LLD] [COFF] Print the file name on errors writing the pdb file
Martin Storsjö via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 20 03:52:35 PDT 2019
mstorsjo created this revision.
mstorsjo added reviewers: ruiu, rnk.
Herald added a project: LLVM.
This avoids confusing contextless error messages such as "No such file or directory" if e.g. the pdb output file should be written to a nonexistent directory. (This can happen with linkrepro scripts, at least old ones.)
As this is more or less NFC, is it ok without a test?
Repository:
rLLD LLVM Linker
https://reviews.llvm.org/D66466
Files:
COFF/PDB.cpp
Index: COFF/PDB.cpp
===================================================================
--- COFF/PDB.cpp
+++ COFF/PDB.cpp
@@ -1693,6 +1693,7 @@
}
void PDBLinker::commit(codeview::GUID *guid) {
+ ExitOnError exitOnErr((config->pdbPath + ": ").str());
// Write to a file.
exitOnErr(builder.commit(config->pdbPath, guid));
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D66466.216095.patch
Type: text/x-patch
Size: 334 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190820/e2e51348/attachment.bin>
More information about the llvm-commits
mailing list