@@ -497,10 +497,6 @@ object Trees {
497497 extends TermTree [T ] {
498498 type ThisTree [- T >: Untyped ] = If [T ]
499499 }
500- class InlineIf [T >: Untyped ] private [ast] (cond : Tree [T ], thenp : Tree [T ], elsep : Tree [T ])
501- extends If (cond, thenp, elsep) {
502- override def toString = s " InlineIf( $cond, $thenp, $elsep) "
503- }
504500
505501 /** A closure with an environment and a reference to a method.
506502 * @param env The captured parameters of the closure
@@ -521,10 +517,6 @@ object Trees {
521517 extends TermTree [T ] {
522518 type ThisTree [- T >: Untyped ] = Match [T ]
523519 }
524- class InlineMatch [T >: Untyped ] private [ast] (selector : Tree [T ], cases : List [CaseDef [T ]])
525- extends Match (selector, cases) {
526- override def toString = s " InlineMatch( $selector, $cases) "
527- }
528520
529521 /** case pat if guard => body; only appears as child of a Match */
530522 case class CaseDef [- T >: Untyped ] private [ast] (pat : Tree [T ], guard : Tree [T ], body : Tree [T ])
@@ -910,10 +902,8 @@ object Trees {
910902 type Assign = Trees .Assign [T ]
911903 type Block = Trees .Block [T ]
912904 type If = Trees .If [T ]
913- type InlineIf = Trees .InlineIf [T ]
914905 type Closure = Trees .Closure [T ]
915906 type Match = Trees .Match [T ]
916- type InlineMatch = Trees .InlineMatch [T ]
917907 type CaseDef = Trees .CaseDef [T ]
918908 type Labeled = Trees .Labeled [T ]
919909 type Return = Trees .Return [T ]
@@ -1045,9 +1035,6 @@ object Trees {
10451035 case _ => finalize(tree, untpd.Block (stats, expr))
10461036 }
10471037 def If (tree : Tree )(cond : Tree , thenp : Tree , elsep : Tree )(implicit ctx : Context ): If = tree match {
1048- case tree : InlineIf =>
1049- if ((cond eq tree.cond) && (thenp eq tree.thenp) && (elsep eq tree.elsep)) tree
1050- else finalize(tree, untpd.InlineIf (cond, thenp, elsep))
10511038 case tree : If if (cond eq tree.cond) && (thenp eq tree.thenp) && (elsep eq tree.elsep) => tree
10521039 case _ => finalize(tree, untpd.If (cond, thenp, elsep))
10531040 }
@@ -1056,9 +1043,6 @@ object Trees {
10561043 case _ => finalize(tree, untpd.Closure (env, meth, tpt))
10571044 }
10581045 def Match (tree : Tree )(selector : Tree , cases : List [CaseDef ])(implicit ctx : Context ): Match = tree match {
1059- case tree : InlineMatch =>
1060- if ((selector eq tree.selector) && (cases eq tree.cases)) tree
1061- else finalize(tree, untpd.InlineMatch (selector, cases))
10621046 case tree : Match if (selector eq tree.selector) && (cases eq tree.cases) => tree
10631047 case _ => finalize(tree, untpd.Match (selector, cases))
10641048 }
0 commit comments