File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed
compiler/src/dotty/tools/dotc/tastyreflect Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -10,13 +10,13 @@ object ReflectionImpl {
1010 apply(rootContext, SourcePosition (rootContext.source, Spans .NoSpan ))
1111
1212 def apply (rootContext : Contexts .Context , rootPosition : SourcePosition ): scala.tasty.Reflection =
13- new ReflectionImpl (new KernelImpl (rootContext, rootPosition))
13+ new scala.tasty. Reflection (new KernelImpl (rootContext, rootPosition))
1414
1515 def showTree (tree : tpd.Tree )(implicit ctx : Contexts .Context ): String = {
16- val refl = new ReflectionImpl (new KernelImpl (ctx, tree.sourcePos))
17- new refl.SourceCodePrinter ().showTree(tree)
16+ val refl = new scala.tasty.Reflection (new KernelImpl (ctx, tree.sourcePos))
17+ val reflCtx = ctx.asInstanceOf [refl.Context ]
18+ val reflTree = tree.asInstanceOf [refl.Tree ]
19+ new refl.SourceCodePrinter ().showTree(reflTree)(reflCtx)
1820 }
1921
20- private class ReflectionImpl (val kernel : KernelImpl ) extends scala.tasty.Reflection
21-
2222}
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ package scala.tasty
22
33import scala .tasty .reflect ._
44
5- abstract class Reflection
5+ class Reflection ( val kernel : Kernel )
66 extends Core
77 with ConstantOps
88 with ContextOps
You can’t perform that action at this time.
0 commit comments