diff options
Diffstat (limited to 'test/files/run/reflection-enclosed-nested-basic.scala')
-rw-r--r-- | test/files/run/reflection-enclosed-nested-basic.scala | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/test/files/run/reflection-enclosed-nested-basic.scala b/test/files/run/reflection-enclosed-nested-basic.scala index 180ac4ebee..4ff333d10f 100644 --- a/test/files/run/reflection-enclosed-nested-basic.scala +++ b/test/files/run/reflection-enclosed-nested-basic.scala @@ -14,19 +14,19 @@ object B { object Test extends App { val b = cm.moduleSymbol(classTag[B.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.reflectClass(sym).reflectConstructor(ctor) val instance = ctorMirror() println(instance) @@ -37,7 +37,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.reflectModule(sym) val instance = moduleMirror.instance |