[clang] [Driver][HIP/SPIRV] Fix crash when llvm-link is executed. (PR #196074)

Alex Voicu via cfe-commits cfe-commits at lists.llvm.org
Wed May 6 07:04:12 PDT 2026


================
@@ -39,8 +39,11 @@ void AMDGCN::Linker::constructLLVMLinkCommand(
 
   ArgStringList LinkerInputs;
 
-  for (auto Input : Inputs)
-    LinkerInputs.push_back(Input.getFilename());
+  for (auto Input : Inputs) {
+    if (Input.isFilename()) {
----------------
AlexVlx wrote:

Minor nit: IIRC the style convention is no curly braces around single line controlled blocks.

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


More information about the cfe-commits mailing list