You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: test/Sema/diag_ambiguous_overloads.swift
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -148,8 +148,8 @@ do {
148
148
}
149
149
}
150
150
do{
151
-
func f1(_ u:Int)->String{} // expected-note {{found this candidate}} expected-note {{candidate expects value of type 'Int' for parameter #1 (got 'Double')}}
152
-
func f1(_ u:String)->Double{} // expected-note {{found this candidate}} expected-note {{candidate expects value of type 'String' for parameter #1 (got 'Double')}}
151
+
func f1(_ u:Int)->String{} // expected-note 2 {{candidate expects value of type 'Int' for parameter #1 (got 'Double')}}
152
+
func f1(_ u:String)->Double{} // expected-note 2 {{candidate expects value of type 'String' for parameter #1 (got 'Double')}}
153
153
func f2(_ u:Int){}
154
154
155
155
f2(f1(1asDouble)) // expected-error {{no exact matches in call to local function 'f1'}}
// expected-error@-1 {{no exact matches in call to instance method 'joined'}}
752
-
// expected-note@-2 {{found candidate with type '(String) -> String'}}
753
752
// There is one more note here - candidate requires that 'Int' conform to 'Sequence' (requirement specified as 'Self.Element' : 'Sequence') pointing to Sequence extension
0 commit comments