diff options
Diffstat (limited to 'lld/COFF/DriverUtils.cpp')
-rw-r--r-- | lld/COFF/DriverUtils.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lld/COFF/DriverUtils.cpp b/lld/COFF/DriverUtils.cpp index 6859e40e710b..598228550014 100644 --- a/lld/COFF/DriverUtils.cpp +++ b/lld/COFF/DriverUtils.cpp @@ -517,6 +517,13 @@ std::error_code writeImportLibrary() { return E.run(); } +void touchFile(StringRef Path) { + int FD; + if (sys::fs::openFileForWrite(Path, FD, sys::fs::F_Append)) + report_fatal_error("failed to create a file"); + sys::Process::SafelyCloseFileDescriptor(FD); +} + // Create OptTable // Create prefix string literals used in Options.td |