summaryrefslogtreecommitdiff
path: root/test/files/run/reflection-valueclasses-magic.scala
diff options
context:
space:
mode:
authorEugene Burmako <xeno.by@gmail.com>2012-10-03 23:24:03 +0200
committerEugene Burmako <xeno.by@gmail.com>2012-10-03 23:55:53 +0200
commit9930b559fe657d517abeb3e4e4ffb3a2a6e00ee0 (patch)
tree820e2fcd9957dd03c3e5d047b01f9daa4926562f /test/files/run/reflection-valueclasses-magic.scala
parentcd847070254a2c6055e543c65ec82ea8429ee757 (diff)
downloadscala-9930b559fe657d517abeb3e4e4ffb3a2a6e00ee0.tar.gz
scala-9930b559fe657d517abeb3e4e4ffb3a2a6e00ee0.tar.bz2
scala-9930b559fe657d517abeb3e4e4ffb3a2a6e00ee0.zip
turns on documentation of scala.reflect.runtime
We definitely need to document scala.reflect.runtime.universe, therefore adding scala.reflect.runtime to skipPackages was a mistake. But then we need to make a bunch of internal classes private to reflect or to scala. Not very pretty, but it works.
Diffstat (limited to 'test/files/run/reflection-valueclasses-magic.scala')
-rw-r--r--test/files/run/reflection-valueclasses-magic.scala8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/files/run/reflection-valueclasses-magic.scala b/test/files/run/reflection-valueclasses-magic.scala
index f9feb2d504..577939d2db 100644
--- a/test/files/run/reflection-valueclasses-magic.scala
+++ b/test/files/run/reflection-valueclasses-magic.scala
@@ -3,6 +3,12 @@ import scala.reflect.runtime.universe.definitions._
import scala.reflect.runtime.{currentMirror => cm}
import scala.reflect.ClassTag
+package scala {
+ object ExceptionUtils {
+ def unwrapThrowable(ex: Throwable): Throwable = scala.reflect.runtime.ReflectionUtils.unwrapThrowable(ex)
+ }
+}
+
object Test extends App {
def key(sym: Symbol) = {
sym match {
@@ -35,7 +41,7 @@ object Test extends App {
println(s"[${result.getClass}] =======> $result")
} catch {
case ex: Throwable =>
- val realex = scala.reflect.runtime.ReflectionUtils.unwrapThrowable(ex)
+ val realex = scala.ExceptionUtils.unwrapThrowable(ex)
println(realex.getClass + ": " + realex.getMessage)
}
val meth = tpe.declaration(newTermName(method).encodedName.toTermName)