[clang] [LinkerWrapper] Use the correct empty file on Windows (PR #84322)

via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 7 06:02:19 PST 2024


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff 597be90f8b72fde59505f3650c20cf9e57b47d57 4a1e095d962e5b76d529fe579f2b449a36117c65 -- clang/tools/clang-linker-wrapper/ClangLinkerWrapper.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/clang/tools/clang-linker-wrapper/ClangLinkerWrapper.cpp b/clang/tools/clang-linker-wrapper/ClangLinkerWrapper.cpp
index 7bbdfc8bd8..0a783db896 100644
--- a/clang/tools/clang-linker-wrapper/ClangLinkerWrapper.cpp
+++ b/clang/tools/clang-linker-wrapper/ClangLinkerWrapper.cpp
@@ -411,9 +411,9 @@ fatbinary(ArrayRef<std::pair<StringRef, StringRef>> InputFiles,
   CmdArgs.push_back(Saver.save(llvm::join(Targets, ",")));
 
 #ifdef _WIN32
-    CmdArgs.push_back("-input=NUL");
+  CmdArgs.push_back("-input=NUL");
 #else
-    CmdArgs.push_back("-input=/dev/null");
+  CmdArgs.push_back("-input=/dev/null");
 #endif
   for (const auto &[File, Arch] : InputFiles)
     CmdArgs.push_back(Saver.save("-input=" + File));

``````````

</details>


https://github.com/llvm/llvm-project/pull/84322


More information about the cfe-commits mailing list