File tree Expand file tree Collapse file tree 4 files changed +4
-4
lines changed
compiler/src/dotty/tools/dotc/tastyreflect
tests/run-custom-args/tasty-inspector Expand file tree Collapse file tree 4 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ class ReflectionCompilerInterface(val rootContext: core.Contexts.Context) extend
65
65
def Context_requiredClass (self : Context )(path : String ): Symbol = self.requiredClass(path)
66
66
def Context_requiredModule (self : Context )(path : String ): Symbol = self.requiredModule(path)
67
67
def Context_requiredMethod (self : Context )(path : String ): Symbol = self.requiredMethod(path)
68
- def Context_getJavaClassname (self : Context ): Option [String ] =
68
+ def Context_javaCompilationUnitClassname (self : Context ): Option [String ] =
69
69
self.compilationUnit match {
70
70
case j : fromtasty.JavaCompilationUnit => Some (j.className)
71
71
case _ => None
Original file line number Diff line number Diff line change @@ -474,7 +474,7 @@ class Reflection(private[scala] val internal: CompilerInterface) { self =>
474
474
def requiredMethod (path : String ): Symbol = internal.Context_requiredMethod (self)(path)
475
475
476
476
/** Get Java class name if we've accidentally tried to reflect on a Java class. None returned if TASTy class. */
477
- def getJavaClassname (): Option [String ] = internal.Context_getJavaClassname (self)
477
+ def javaCompilationUnitClassname (): Option [String ] = internal.Context_javaCompilationUnitClassname (self)
478
478
479
479
}
480
480
Original file line number Diff line number Diff line change @@ -163,7 +163,7 @@ trait CompilerInterface {
163
163
def Context_requiredMethod (self : Context )(path : String ): Symbol
164
164
165
165
/** Get Java class name if we've accidentally tried to reflect on a Java class. None returned if TASTy class. */
166
- def Context_getJavaClassname (self : Context ): Option [String ]
166
+ def Context_javaCompilationUnitClassname (self : Context ): Option [String ]
167
167
168
168
169
169
// /////////////
Original file line number Diff line number Diff line change @@ -21,4 +21,4 @@ class TestInspector() extends TastyInspector
21
21
22
22
protected def processCompilationUnit (reflect : Reflection )(root : reflect.Tree ): Unit =
23
23
import reflect .{given ,_ }
24
- gotJava = reflect.rootContext.getJavaClassname ()
24
+ gotJava = reflect.rootContext.javaCompilationUnitClassname ()
You can’t perform that action at this time.
0 commit comments