[PATCH] D104008: [ms] [llvm-ml] Warn on command-line redefinition

Nico Weber via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 10 06:02:54 PDT 2021


thakis added a comment.

I tried patching this in



================
Comment at: llvm/test/tools/llvm-ml/command_line_defines_errors.asm:1
+; RUN: not llvm-ml -filetype=s %s /Fo - /Dtest1=def /WX 2>&1 | FileCheck %s --implicit-check-not=error: --implicit-check-not=warning:
+
----------------
epastor wrote:
> I couldn't get lit to just detect the warning, for some reason. I'm open to suggestions!
Hm, works for me:

```
; RUN: llvm-ml -filetype=s %s /Fo - /Dtest1=def 2>&1 | FileCheck %s --implicit-check-not=warning:

.code

; CHECK: :[[# @LINE + 1]]:1: warning: redefining 'test1', already defined on the command line
test1 textequ <redef>

end
```

```
% out/gn/bin/llvm-lit -s -vv llvm/test/tools/llvm-ml/command_line_defines_errors.asm


Testing Time: 0.13s
  Passed: 1
```


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D104008



More information about the llvm-commits mailing list