@@ -95,7 +95,7 @@ trait QuoteContext { self: runtime.QuoteUnpickler & runtime.QuoteMatching =>
95
95
* | +- Closure
96
96
* | +- If
97
97
* | +- Match
98
- * | +- GivenMatch
98
+ * | +- SummonFrom
99
99
* | +- Try
100
100
* | +- Return
101
101
* | +- Repeated
@@ -578,7 +578,6 @@ trait QuoteContext { self: runtime.QuoteUnpickler & runtime.QuoteMatching =>
578
578
*/
579
579
def unique (qualifier : Term , name : String ): Select
580
580
581
- // TODO rename, this returns an Apply and not a Select
582
581
/** Call an overloaded method with the given type and term parameters */
583
582
def overloaded (qualifier : Term , name : String , targs : List [TypeRepr ], args : List [Term ]): Apply
584
583
@@ -1031,34 +1030,34 @@ trait QuoteContext { self: runtime.QuoteUnpickler & runtime.QuoteMatching =>
1031
1030
end extension
1032
1031
end MatchMethods
1033
1032
1034
- /** Tree representing a pattern match `given match { ... }` in the source code */ // TODO: drop
1035
- type GivenMatch <: Term
1033
+ /** Tree representing a summoning match `summonFrom { ... }` in the source code */
1034
+ type SummonFrom <: Term
1036
1035
1037
- given TypeTest [Tree , GivenMatch ] = GivenMatchTypeTest
1038
- protected val GivenMatchTypeTest : TypeTest [Tree , GivenMatch ]
1036
+ given TypeTest [Tree , SummonFrom ] = SummonFromTypeTest
1037
+ protected val SummonFromTypeTest : TypeTest [Tree , SummonFrom ]
1039
1038
1040
1039
/** Scala implicit `match` term */
1041
- val GivenMatch : GivenMatchModule
1040
+ val SummonFrom : SummonFromModule
1042
1041
1043
- trait GivenMatchModule { this : GivenMatch .type =>
1042
+ trait SummonFromModule { this : SummonFrom .type =>
1044
1043
1045
1044
/** Creates a pattern match `given match { <cases: List[CaseDef]> }` */
1046
- def apply (cases : List [CaseDef ]): GivenMatch
1045
+ def apply (cases : List [CaseDef ]): SummonFrom
1047
1046
1048
- def copy (original : Tree )(cases : List [CaseDef ]): GivenMatch
1047
+ def copy (original : Tree )(cases : List [CaseDef ]): SummonFrom
1049
1048
1050
1049
/** Matches a pattern match `given match { <cases: List[CaseDef]> }` */
1051
- def unapply (x : GivenMatch ): Option [List [CaseDef ]]
1050
+ def unapply (x : SummonFrom ): Option [List [CaseDef ]]
1052
1051
}
1053
1052
1054
- given GivenMatchMethods as GivenMatchMethods = GivenMatchMethodsImpl
1055
- protected val GivenMatchMethodsImpl : GivenMatchMethods
1053
+ given SummonFromMethods as SummonFromMethods = SummonFromMethodsImpl
1054
+ protected val SummonFromMethodsImpl : SummonFromMethods
1056
1055
1057
- trait GivenMatchMethods :
1058
- extension (self : GivenMatch ):
1056
+ trait SummonFromMethods :
1057
+ extension (self : SummonFrom ):
1059
1058
def cases : List [CaseDef ]
1060
1059
end extension
1061
- end GivenMatchMethods
1060
+ end SummonFromMethods
1062
1061
1063
1062
/** Tree representing a try catch `try x catch { ... } finally { ... }` in the source code */
1064
1063
type Try <: Term
0 commit comments