@@ -27,43 +27,43 @@ class TastyPrinter[T <: Tasty with Singleton](val tasty: T) {
2727 def result (): String = sb.result()
2828
2929 def visitTree (x : Tree ): Buffer = x match {
30- case Ident (name) =>
30+ case Term . Ident (name) =>
3131 this += " Ident(" += name += " )"
32- case Select (qualifier, name, signature) =>
32+ case Term . Select (qualifier, name, signature) =>
3333 this += " Select(" += qualifier += " , " += name += " , " += signature += " )"
34- case This (qual) =>
34+ case Term . This (qual) =>
3535 this += " This(" += qual += " )"
36- case Super (qual, mix) =>
36+ case Term . Super (qual, mix) =>
3737 this += " TypeApply(" += qual += " , " += mix += " )"
38- case Apply (fun, args) =>
38+ case Term . Apply (fun, args) =>
3939 this += " Apply(" += fun += " , " ++= args += " )"
40- case TypeApply (fun, args) =>
40+ case Term . TypeApply (fun, args) =>
4141 this += " TypeApply(" += fun += " , " ++= args += " )"
42- case Literal (const) =>
42+ case Term . Literal (const) =>
4343 this += " Literal(" += const += " )"
44- case New (tpt) =>
44+ case Term . New (tpt) =>
4545 this += " New(" += tpt += " )"
46- case Typed (expr, tpt) =>
46+ case Term . Typed (expr, tpt) =>
4747 this += " Typed(" += expr += " , " += tpt += " )"
48- case NamedArg (name, arg) =>
48+ case Term . NamedArg (name, arg) =>
4949 this += " NamedArg(" += name += " , " += arg += " )"
50- case Assign (lhs, rhs) =>
50+ case Term . Assign (lhs, rhs) =>
5151 this += " Assign(" += lhs += " , " += rhs += " )"
52- case Block (stats, expr) =>
52+ case Term . Block (stats, expr) =>
5353 this += " Block(" ++= stats += " , " += expr += " )"
54- case If (cond, thenp, elsep) =>
54+ case Term . If (cond, thenp, elsep) =>
5555 this += " If(" += cond += " , " += thenp += " , " += elsep += " )"
56- case Lambda (meth, tpt) =>
56+ case Term . Lambda (meth, tpt) =>
5757 this += " Lambda(" += meth += " , " += tpt += " )"
58- case Match (selector, cases) =>
58+ case Term . Match (selector, cases) =>
5959 this += " Match(" += selector += " , " ++= cases += " )"
60- case Return (expr) =>
60+ case Term . Return (expr) =>
6161 this += " Return(" += expr += " )"
62- case Try (block, handlers, finalizer) =>
62+ case Term . Try (block, handlers, finalizer) =>
6363 this += " Try(" += block += " , " ++= handlers += " , " += finalizer += " )"
64- case Repeated (elems) =>
64+ case Term . Repeated (elems) =>
6565 this += " Repeated(" ++= elems += " )"
66- case Inlined (call, bindings, expansion) =>
66+ case Term . Inlined (call, bindings, expansion) =>
6767 this += " Inlined(" += call += " , " ++= bindings += " , " += expansion += " )"
6868 case ValDef (name, tpt, rhs) =>
6969 this += " ValDef(" += name += " , " += tpt += " , " += rhs += " )"
@@ -87,25 +87,25 @@ class TastyPrinter[T <: Tasty with Singleton](val tasty: T) {
8787 }
8888
8989 def visitTypeTree (x : TypeOrBoundsTree ): Buffer = x match {
90- case Synthetic () =>
90+ case TypeTree . Synthetic () =>
9191 this += " Synthetic()"
92- case TypeIdent (name) =>
92+ case TypeTree . TypeIdent (name) =>
9393 this += " TypeIdent(" += name += " )"
94- case TypeSelect (qualifier, name) =>
94+ case TypeTree . TypeSelect (qualifier, name) =>
9595 this += " TypeSelect(" += qualifier += " , " += name += " )"
96- case Singleton (ref) =>
96+ case TypeTree . Singleton (ref) =>
9797 this += " Singleton(" += ref += " )"
98- case And (left, right) =>
98+ case TypeTree . And (left, right) =>
9999 this += " And(" += left += " , " += right += " )"
100- case Or (left, right) =>
100+ case TypeTree . Or (left, right) =>
101101 this += " Or(" += left += " , " += right += " )"
102- case Refined (tpt, refinements) =>
102+ case TypeTree . Refined (tpt, refinements) =>
103103 this += " Refined(" += tpt += " , " ++= refinements += " )"
104- case Applied (tpt, args) =>
104+ case TypeTree . Applied (tpt, args) =>
105105 this += " Applied(" += tpt += " , " ++= args += " )"
106- case ByName (result) =>
106+ case TypeTree . ByName (result) =>
107107 this += " ByName(" += result += " )"
108- case Annotated (arg, annot) =>
108+ case TypeTree . Annotated (arg, annot) =>
109109 this += " Annotated(" += arg += " , " += annot += " )"
110110 case TypeBoundsTree (lo, hi) =>
111111 this += " TypeBoundsTree(" += lo += " , " += hi += " )"
@@ -117,15 +117,15 @@ class TastyPrinter[T <: Tasty with Singleton](val tasty: T) {
117117 }
118118
119119 def visitPattern (x : Pattern ): Buffer = x match {
120- case Value (v) =>
120+ case Pattern . Value (v) =>
121121 this += " Value(" += v += " )"
122- case Bind (name, body) =>
122+ case Pattern . Bind (name, body) =>
123123 this += " Bind(" += name += " , " += body += " )"
124- case Unapply (fun, implicits, patterns) =>
124+ case Pattern . Unapply (fun, implicits, patterns) =>
125125 this += " Unapply(" += fun += " , " ++= implicits += " , " ++= patterns += " )"
126- case Alternative (patterns) =>
126+ case Pattern . Alternative (patterns) =>
127127 this += " Alternative(" ++= patterns += " )"
128- case TypeTest (tpt) =>
128+ case Pattern . TypeTest (tpt) =>
129129 this += " TypeTest(" += tpt += " )"
130130 }
131131
@@ -144,9 +144,9 @@ class TastyPrinter[T <: Tasty with Singleton](val tasty: T) {
144144 }
145145
146146 def visitType (x : TypeOrBounds ): Buffer = x match {
147- case ConstantType (value) =>
147+ case Type . ConstantType (value) =>
148148 this += " ConstantType(" += value += " )"
149- case SymRef (sym, qual) =>
149+ case Type . SymRef (sym, qual) =>
150150 def visitName (sym : Definition ): Buffer = sym match {
151151 case ValDef (name, _, _) => this += name
152152 case DefDef (name, _, _, _, _) => this += name
@@ -158,33 +158,33 @@ class TastyPrinter[T <: Tasty with Singleton](val tasty: T) {
158158 this += " SymRef("
159159 visitName(sym)
160160 this += " , " += qual += " )"
161- case TermRef (name, qual) =>
161+ case Type . TermRef (name, qual) =>
162162 this += " TermRef(" += name += " , " += qual += " )"
163- case TypeRef (name, qual) =>
163+ case Type . TypeRef (name, qual) =>
164164 this += " TypeRef(" += name += " , " += qual += " )"
165- case Refinement (parent, name, info) =>
165+ case Type . Refinement (parent, name, info) =>
166166 this += " Refinement(" += parent += " , " += name += " , " += info += " )"
167- case AppliedType (tycon, args) =>
167+ case Type . AppliedType (tycon, args) =>
168168 this += " AppliedType(" += tycon += " , " ++= args += " )"
169- case AnnotatedType (underlying, annot) =>
169+ case Type . AnnotatedType (underlying, annot) =>
170170 this += " AnnotatedType(" += underlying += " , " += annot += " )"
171- case AndType (left, right) =>
171+ case Type . AndType (left, right) =>
172172 this += " AndType(" += left += " , " += right += " )"
173- case OrType (left, right) =>
173+ case Type . OrType (left, right) =>
174174 this += " OrType(" += left += " , " += right += " )"
175- case ByNameType (underlying) =>
175+ case Type . ByNameType (underlying) =>
176176 this += " ByNameType(" += underlying += " )"
177- case ParamRef (binder, idx) =>
177+ case Type . ParamRef (binder, idx) =>
178178 this += " ParamRef(" += binder+= " , " += idx += " )"
179- case ThisType (tp) =>
179+ case Type . ThisType (tp) =>
180180 this += " ThisType(" += tp += " )"
181- case RecursiveThis (binder) =>
181+ case Type . RecursiveThis (binder) =>
182182 this += " RecursiveThis(" += binder += " )"
183- case MethodType (argNames, argTypes, resType) =>
183+ case Type . MethodType (argNames, argTypes, resType) =>
184184 this += " MethodType(" ++= argNames += " , " ++= argTypes += " , " += resType += " )"
185- case PolyType (argNames, argBounds, resType) =>
185+ case Type . PolyType (argNames, argBounds, resType) =>
186186 this += " PolyType(" ++= argNames += " , " ++= argBounds += " , " += resType += " )"
187- case TypeLambda (argNames, argBounds, resType) =>
187+ case Type . TypeLambda (argNames, argBounds, resType) =>
188188 this += " TypeLambda(" ++= argNames += " , " ++= argBounds += " , " += resType += " )"
189189 case TypeBounds (lo, hi) =>
190190 this += " TypeBounds(" += lo += " , " += hi += " )"
@@ -193,10 +193,10 @@ class TastyPrinter[T <: Tasty with Singleton](val tasty: T) {
193193 }
194194
195195 def visitModifier (x : Modifier ): Buffer = x match {
196- case Flags (flags) => this += " Flags(" += flags.toString += " )"
197- case QualifiedPrivate (tp) => this += " QualifiedPrivate(" += tp += " )"
198- case QualifiedProtected (tp) => this += " QualifiedProtected(" += tp += " )"
199- case Annotation (tree) => this += " Annotation(" += tree += " )"
196+ case Modifier . Flags (flags) => this += " Flags(" += flags.toString += " )"
197+ case Modifier . QualifiedPrivate (tp) => this += " QualifiedPrivate(" += tp += " )"
198+ case Modifier . QualifiedProtected (tp) => this += " QualifiedProtected(" += tp += " )"
199+ case Modifier . Annotation (tree) => this += " Annotation(" += tree += " )"
200200 }
201201
202202 def visitId (x : Id ): Buffer = {
0 commit comments