diff options
Diffstat (limited to 'test/files/run/reflection-enclosed-inner-nested-basic.scala')
-rw-r--r-- | test/files/run/reflection-enclosed-inner-nested-basic.scala | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/test/files/run/reflection-enclosed-inner-nested-basic.scala b/test/files/run/reflection-enclosed-inner-nested-basic.scala index 6c2fc6df7a..1973f47397 100644 --- a/test/files/run/reflection-enclosed-inner-nested-basic.scala +++ b/test/files/run/reflection-enclosed-inner-nested-basic.scala @@ -17,19 +17,19 @@ object Test extends App { val outer1 = new B() val b = cm.moduleSymbol(classTag[outer1.BB.type].runtimeClass) println(b) - println(b.typeSignature.declarations.toList) + println(b.info.decls.toList) def testMethodInvocation(instance: Any) = { val instanceMirror = cm.reflect(instance) - val method = instanceMirror.symbol.typeSignature.declaration(TermName("foo")).asMethod + val method = instanceMirror.symbol.info.decl(TermName("foo")).asMethod val methodMirror = instanceMirror.reflectMethod(method) println(methodMirror()) } def testNestedClass(name: String) = { - val sym = b.typeSignature.declaration(TypeName(name)).asClass + val sym = b.info.decl(TypeName(name)).asClass println(sym) - val ctor = sym.typeSignature.declaration(nme.CONSTRUCTOR).asMethod + val ctor = sym.info.decl(termNames.CONSTRUCTOR).asMethod val ctorMirror = cm.reflect(outer1.BB).reflectClass(sym).reflectConstructor(ctor) val instance = ctorMirror() println(instance) @@ -40,7 +40,7 @@ object Test extends App { testNestedClass("B2") def testNestedModule(name: String) = { - val sym = b.typeSignature.declaration(TermName(name)).asModule + val sym = b.info.decl(TermName(name)).asModule println(sym) val moduleMirror = cm.reflect(outer1.BB).reflectModule(sym) val instance = moduleMirror.instance |