@@ -3,16 +3,18 @@ open class ParentClass {
3
3
open func overridableMethodA( param: Int ) { }
4
4
open func overridableMethodB( param: Int ) { }
5
5
open func overridableMethodC( param: Int ) { }
6
+ open func overridableMethodD( param: Int ) { }
6
7
}
7
8
#endif
8
9
9
10
#if MODA_LOC
10
11
open class ParentClass {
11
12
#sourceLocation(file: "doesnotexist.swift", line: 10)
12
13
open func overridableMethodA( param: Int ) { }
13
- #sourceLocation(file: "REPLACEDWITHSED", line: 20)
14
14
open func overridableMethodB( param: Int ) { }
15
+ #sourceLocation(file: "REPLACEDWITHSED", line: 20)
15
16
open func overridableMethodC( param: Int ) { }
17
+ open func overridableMethodD( param: Int ) { }
16
18
#sourceLocation()
17
19
}
18
20
#endif
@@ -24,6 +26,7 @@ open class SubClass: ParentClass {
24
26
open override func overridableMethodA( param: String ) { }
25
27
open override func overridableMethodB( param: String ) { }
26
28
open override func overridableMethodC( param: String ) { }
29
+ open override func overridableMethodD( param: String ) { }
27
30
}
28
31
#endif
29
32
@@ -41,6 +44,7 @@ open class SubClass: ParentClass {
41
44
// CHECK-EXISTS: moda.swift:3:13: note
42
45
// CHECK-EXISTS: moda.swift:4:13: note
43
46
// CHECK-EXISTS: moda.swift:5:13: note
47
+ // CHECK-EXISTS: moda.swift:6:13: note
44
48
45
49
// Removed the underlying file, so should use the generated source instead
46
50
// RUN: mv %t/moda.swift %t/moda.swift-moved
@@ -65,7 +69,8 @@ open class SubClass: ParentClass {
65
69
66
70
// RUN: cp %t/moda.swift %t/alternative.swift
67
71
// RUN: not %target-swift-frontend -typecheck -I %t/mods -D MODB %s 2>&1 | %FileCheck -check-prefix=CHECK-DIRECTIVE %s
68
- // CHECK-DIRECTIVE: doesnotexist.swift:10:13: note
72
+ // CHECK-DIRECTIVE: {{^}}doesnotexist.swift:10:13: note
73
+ // CHECK-DIRECTIVE: {{^}}doesnotexist.swift:11:13: note
69
74
// CHECK-DIRECTIVE: alternative.swift:20:13: note
70
75
// CHECK-DIRECTIVE: alternative.swift:21:13: note
71
76
0 commit comments