File tree Expand file tree Collapse file tree 3 files changed +13
-0
lines changed Expand file tree Collapse file tree 3 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -598,6 +598,13 @@ class JSONFixitWriter : public DiagnosticConsumer {
598
598
if (Info.ID == diag::objc_witness_selector_mismatch.ID ||
599
599
Info.ID == diag::witness_non_objc.ID )
600
600
return false ;
601
+ // This interacts badly with the migrator. For such code:
602
+ // func test(p: Int, _: String) {}
603
+ // test(0, "")
604
+ // the compiler bizarrely suggests to change order of arguments in the call
605
+ // site.
606
+ if (Info.ID == diag::argument_out_of_order_unnamed_unnamed.ID )
607
+ return false ;
601
608
// The following interact badly with the swift migrator by removing @IB*
602
609
// attributes when there is some unrelated type issue.
603
610
if (Info.ID == diag::invalid_iboutlet.ID ||
Original file line number Diff line number Diff line change @@ -254,3 +254,6 @@ func testProtocolCompositionSyntax() {
254
254
var _: protocol < Prot1 >
255
255
var _: protocol < Prot1 , Prot2 >
256
256
}
257
+
258
+ func disable_unnamed_param_reorder( p: Int , _: String ) { }
259
+ disable_unnamed_param_reorder ( 0 , " " ) // no change.
Original file line number Diff line number Diff line change @@ -257,3 +257,6 @@ func testProtocolCompositionSyntax() {
257
257
var _: Prot1
258
258
var _: Prot1 & Prot2
259
259
}
260
+
261
+ func disable_unnamed_param_reorder(p: Int, _: String) {}
262
+ disable_unnamed_param_reorder(0, "") // no change.
You can’t perform that action at this time.
0 commit comments