Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / llvm / test / MC / AsmParser / macro-required-argument-err.s
blob4417171bf70c6986efee64b475a10d08c0a661a4
1 # RUN: not llvm-mc -triple=x86_64 %s -o /dev/null 2>&1 | FileCheck %s --match-full-lines --strict-whitespace
3 # CHECK:{{.*}}.s:[[#@LINE+3]]:36: error: missing parameter qualifier for 'parameter' in macro 'missing_qualifier'
4 # CHECK-NEXT:.macro missing_qualifier parameter:
5 # CHECK-NEXT: ^
6 .macro missing_qualifier parameter:
8 # CHECK-NEXT:{{.*}}.s:[[#@LINE+3]]:43: error: missing parameter qualifier for 'parameter' in macro 'non_identifier_qualifier'
9 # CHECK-NEXT:.macro non_identifier_qualifier parameter:0
10 # CHECK-NEXT: ^
11 .macro non_identifier_qualifier parameter:0
13 # CHECK-NEXT:{{.*}}.s:[[#@LINE+3]]:36: error: invalid_qualifier is not a valid parameter qualifier for 'parameter' in macro 'invalid_qualifier'
14 # CHECK-NEXT:.macro invalid_qualifier parameter:invalid_qualifier
15 # CHECK-NEXT: ^
16 .macro invalid_qualifier parameter:invalid_qualifier
18 # CHECK-NEXT:{{.*}}.s:[[#@LINE+3]]:40: warning: pointless default value for required parameter 'parameter' in macro 'pointless_default'
19 # CHECK-NEXT:.macro pointless_default parameter:req=default
20 # CHECK-NEXT: ^
21 .macro pointless_default parameter:req=default
22 .endm
24 # CHECK-NEXT:{{.*}}.s:[[#@LINE+5]]:17: error: missing value for required parameter 'parameter' in macro 'missing_required'
25 # CHECK-NEXT:missing_required
26 # CHECK-NEXT: ^
27 .macro missing_required parameter:req
28 .endm
29 missing_required
31 # CHECK-NEXT:{{.*}}.s:[[#@LINE+5]]:24: error: missing value for required parameter 'second' in macro 'missing_second_required'
32 # CHECK-NEXT:missing_second_required
33 # CHECK-NEXT: ^
34 .macro missing_second_required first=0 second:req
35 .endm
36 missing_second_required
38 # CHECK-NEXT:{{.*}}.s:[[#@LINE+8]]:24: error: missing value for required parameter 'second' in macro 'second_third_required'
39 # CHECK-NEXT:second_third_required 0
40 # CHECK-NEXT: ^
41 # CHECK-NEXT:{{.*}}.s:[[#@LINE+5]]:24: error: missing value for required parameter 'third' in macro 'second_third_required'
42 # CHECK-NEXT:second_third_required 0
43 # CHECK-NEXT: ^
44 .macro second_third_required first=0 second:req third:req
45 .endm
46 second_third_required 0
48 # CHECK-NEXT:{{.*}}.s:[[#@LINE+3]]:38: error: missing value for required parameter 'second' in macro 'second_third_required'
49 # CHECK-NEXT:second_third_required third=3 first=1
50 # CHECK-NEXT: ^
51 second_third_required third=3 first=1