diff options
author | Eugene Burmako <xeno.by@gmail.com> | 2012-07-30 21:14:42 +0200 |
---|---|---|
committer | Eugene Burmako <xeno.by@gmail.com> | 2012-08-02 15:50:01 +0200 |
commit | 013acf6eb0117ca12ab2a0d0e8560df40a7392a3 (patch) | |
tree | 2f69939025e5796381327bd16f602b5be9cfcba4 /test/files/run/reflection-equality.scala | |
parent | 367b82de04bdee24b0994e30c1464297eae16d74 (diff) | |
download | scala-013acf6eb0117ca12ab2a0d0e8560df40a7392a3.tar.gz scala-013acf6eb0117ca12ab2a0d0e8560df40a7392a3.tar.bz2 scala-013acf6eb0117ca12ab2a0d0e8560df40a7392a3.zip |
renames asType to toType and asXXXSymbol to asXXX
This renaming arguably makes the intent of `asType` more clear,
but more importantly it shaves 6 symbols off pervasive casts that
are required to anything meaningful with reflection API
(as in mirror.reflectMethod(tpe.member(newTermName("x")).asMethodSymbol)).
Diffstat (limited to 'test/files/run/reflection-equality.scala')
-rw-r--r-- | test/files/run/reflection-equality.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/files/run/reflection-equality.scala b/test/files/run/reflection-equality.scala index 35dc47a59f..8fc82721e7 100644 --- a/test/files/run/reflection-equality.scala +++ b/test/files/run/reflection-equality.scala @@ -11,7 +11,7 @@ object Test extends ReplTest { |def im: InstanceMirror = cm.reflect(new X) |val cs: ClassSymbol = im.symbol |val ts: Type = cs.typeSignature - |val ms: MethodSymbol = ts.declaration(newTermName("methodIntIntInt")).asMethodSymbol + |val ms: MethodSymbol = ts.declaration(newTermName("methodIntIntInt")).asMethod |val MethodType( _, t1 ) = ms.typeSignature |val t2 = typeOf[scala.Int] |t1 == t2 |