Alan Zhao ae38e4880e [llvm-ml] Remove all file extension restrictions
After D126425 was submitted, hans@ observed that MSVC's ml.exe doesn't
care about the file's extension at all. Now, we check if the file exists
to determine whether an input filename is a valid assembly file.

To keep things consistent with clang-cl and lld-link, llvm-ml will treat
everything that's not a flag as a filename.

Reviewed By: hans

Differential Revision: https://reviews.llvm.org/D126931
2022-06-07 13:03:19 -04:00

9 lines
483 B
Plaintext

# RUN: not llvm-ml %t.blah.asm /nologo /Fo /dev/null 2>&1 | FileCheck -DMSG=%errc_ENOENT --check-prefix=ENOENT %s
# RUN: not llvm-ml /Ta /nnlogo /Fo /dev/null 2>&1 | FileCheck -DMSG=%errc_ENOENT --check-prefix=ENOENT-TA %s
# RUN: not llvm-ml - /Fo /dev/null /nnlogo 2>&1 | FileCheck -DMSG=%errc_ENOENT --check-prefix=ENOENT-FLAG %s
# ENOENT-NOT: nologo
# ENOENT: {{.*}}.blah.asm: [[MSG]]
# ENOENT-TA: /nnlogo: [[MSG]]
# ENOENT-FLAG: error: /nnlogo: [[MSG]], did you mean '/nologo'?