File tree Expand file tree Collapse file tree 2 files changed +1
-23
lines changed Expand file tree Collapse file tree 2 files changed +1
-23
lines changed Original file line number Diff line number Diff line change @@ -2784,7 +2784,7 @@ class ConstraintSystem {
2784
2784
void
2785
2785
filterSolutions (SmallVectorImpl<Solution> &solutions,
2786
2786
bool minimize = false ) {
2787
- if (solutions.size () < 2 || isForCodeCompletion () )
2787
+ if (solutions.size () < 2 )
2788
2788
return ;
2789
2789
2790
2790
if (auto best = findBestSolution (solutions, minimize)) {
Original file line number Diff line number Diff line change 46
46
// RUN: %swift-ide-test -code-completion -source-filename %s -code-completion-token=MULTICLOSURE_FUNCBUILDER_ERROR | %FileCheck %s --check-prefix=POINT_MEMBER
47
47
// RUN: %swift-ide-test -code-completion -source-filename %s -code-completion-token=MULTICLOSURE_FUNCBUILDER_FIXME | %FileCheck %s --check-prefix=NORESULTS
48
48
// RUN: %swift-ide-test -code-completion -source-filename %s -code-completion-token=REGULAR_MULTICLOSURE_APPLIED | %FileCheck %s --check-prefix=POINT_MEMBER
49
- // RUN: %swift-ide-test -code-completion -source-filename %s -code-completion-token=BEST_SOLUTION_FILTER | %FileCheck %s --check-prefix=BEST_SOLUTION_FILTER
50
- // RUN: %swift-ide-test -code-completion -source-filename %s -code-completion-token=BEST_SOLUTION_FILTER2 | %FileCheck %s --check-prefix=BEST_SOLUTION_FILTER
51
49
52
50
53
51
struct A {
@@ -440,23 +438,3 @@ takesClosureOfPoint { p in
440
438
if p. #^REGULAR_MULTICLOSURE_APPLIED^# { }
441
439
}
442
440
}
443
-
444
- enum Enum123 {
445
- case enumElem
446
- }
447
- struct Struct123 : Equatable {
448
- var structMem = Enum123 . enumElem
449
- }
450
- func testNoBestSolutionFilter( ) {
451
- let a = Struct123 ( ) ;
452
- let b = [ Struct123] ( ) . first ( where: { $0 == a && 1 + 90 * 5 / 8 == 45 * - 10 } ) ? . structMem != . #^BEST_SOLUTION_FILTER^#
453
- let c = min ( 10.3 , 10 / 10.4 ) < 6 + 5 / ( 10 - 3 ) ? true : Optional ( a) ? . structMem != . #^BEST_SOLUTION_FILTER2 ^#
454
- }
455
-
456
- // BEST_SOLUTION_FILTER: Begin completions
457
- // BEST_SOLUTION_FILTER-DAG: Decl[EnumElement]/ExprSpecific/TypeRelation[Convertible]: enumElem[#Enum123#]{{; name=.+$}}
458
- // BEST_SOLUTION_FILTER-DAG: Decl[InstanceMethod]/CurrNominal/TypeRelation[Invalid]: hash({#(self): Enum123#})[#(into: inout Hasher) -> Void#]{{; name=.+$}}
459
- // BEST_SOLUTION_FILTER-DAG: Keyword[nil]/None/Erase[1]/TypeRelation[Identical]: nil[#Enum123?#]{{; name=.+$}}
460
- // BEST_SOLUTION_FILTER-DAG: Decl[EnumElement]/CurrNominal/IsSystem/TypeRelation[Identical]: none[#Optional<Enum123>#]{{; name=.+$}}
461
- // BEST_SOLUTION_FILTER-DAG: Decl[EnumElement]/CurrNominal/IsSystem/TypeRelation[Identical]: some({#Enum123#})[#Optional<Enum123>#]{{; name=.+$}}
462
- // BEST_SOLUTION_FILTER: End completions
You can’t perform that action at this time.
0 commit comments