|
24 | 24 | // RUN: %target-swift-frontend -swift-version 5 -emit-sil -load-plugin-library %t/%target-library-name(MacroDefinition) %s -module-name MacroUser -o - -g | %FileCheck --check-prefix CHECK-SIL %s
|
25 | 25 |
|
26 | 26 | // Debug info IR testing
|
| 27 | +// RUN: %target-swift-frontend -swift-version 5 -dwarf-version=4 -emit-ir -load-plugin-library %t/%target-library-name(MacroDefinition) %s -module-name MacroUser -o - -g | %FileCheck --check-prefix CHECK-IR-DWARF4 %s |
27 | 28 | // RUN: %target-swift-frontend -swift-version 5 -dwarf-version=5 -emit-ir -load-plugin-library %t/%target-library-name(MacroDefinition) %s -module-name MacroUser -o - -g | %FileCheck --check-prefix CHECK-IR %s
|
28 | 29 |
|
29 | 30 | // Execution testing
|
@@ -71,7 +72,7 @@ struct MemberNotCovered {
|
71 | 72 | // expected-note@-1 {{in expansion of macro 'NotCovered' here}}
|
72 | 73 |
|
73 | 74 | // CHECK-DIAGS: error: declaration name 'value' is not covered by macro 'NotCovered'
|
74 |
| - // CHECK-DIAGS: CONTENTS OF FILE @__swiftmacro_9MacroUser0023macro_expandswift_elFCffMX69_2_33_4361AD9339943F52AE6186DD51E04E91Ll10NotCoveredfMf_.swift |
| 75 | + // CHECK-DIAGS: CONTENTS OF FILE @__swiftmacro_9MacroUser0023macro_expandswift_elFCffMX70_2_33_4361AD9339943F52AE6186DD51E04E91Ll10NotCoveredfMf_.swift |
75 | 76 | // CHECK-DIAGS: var value: Int
|
76 | 77 | // CHECK-DIAGS: END CONTENTS OF FILE
|
77 | 78 | }
|
@@ -163,9 +164,10 @@ func testFileID(a: Int, b: Int) {
|
163 | 164 | // CHECK-AST: macro_expansion_expr type='String'{{.*}}name=line
|
164 | 165 | print("Builtin result is \(#fileID)")
|
165 | 166 | print(
|
166 |
| - // CHECK-IR-DAG: ![[L1:[0-9]+]] = distinct !DILocation(line: [[@LINE+3]], column: 5 |
| 167 | + // CHECK-IR-DAG: ![[L1:[0-9]+]] = distinct !DILocation(line: [[@LINE+4]], column: 5 |
167 | 168 | // CHECK-IR-DAG: ![[L2:[0-9]+]] = distinct !DILocation({{.*}}inlinedAt: ![[L1]])
|
168 | 169 | // CHECK-IR-DAG: !DIFile(filename: "{{.*}}@__swiftmacro_9MacroUser0023macro_expandswift_elFCffMX{{.*}}_12customFileIDfMf_.swift", {{.*}}source: "{{.*}}MacroUser/macro_expand.swift{{.*}}// original-source-range: {{.*}}")
|
| 170 | + // CHECK-IR-DWARF4: {{(target triple = .*-unknown-windows-msvc)|(!DIFile\(filename: ".*generated-.*@__swiftmacro_9MacroUser0023macro_expandswift_elFCffMX.*_12customFileIDfMf_.swift", directory: ""\))}} |
169 | 171 | #addBlocker(
|
170 | 172 | #stringify(a - b)
|
171 | 173 | )
|
|
0 commit comments