dyung added a comment.

Taking a step back and thinking about this, the compile command uses "-S", but 
explicitly specifies the output file to be "%t/module.pcm.o" (even though it is 
generating an assembly file instead of an object file), could we change the 
test to just check for "-o {{.*}}module.pcm.o "? That would work in all cases I 
think except for the extreme corner case where that string was part of the 
build directory name.



================
Comment at: clang/test/Driver/modules.cpp:19
+// CHECK-COMPILE-SAME: {{ -o }}
+// CHECK-COMPILE-SAME: module{{2*}}.{{pcm.o|s}}
 // CHECK-COMPILE-SAME: -x pcm
----------------
I'm not sure what the regex module{{2*}} is supposed to match, or prevent from 
matching? Was this intentional?

It seems it would match "module", "module2", "module22", "module222", etc. When 
would the compiler ever generate anything other than the first? Unless you are 
trying to protect yourself against a build directory that contains module in 
the name, but I'm not sure how this helps that...


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D66176/new/

https://reviews.llvm.org/D66176



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to