File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
src/compiler/scala/tools/nsc/interpreter Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -212,7 +212,11 @@ trait TypeStrings {
212
212
}
213
213
214
214
private def tparamString [T : ru.TypeTag ] : String = {
215
- def typeArguments : List [ru.Type ] = ru.typeOf[T ] match { case ru.TypeRef (_, _, args) => args; case _ => Nil }
215
+ def typeArguments : List [ru.Type ] = {
216
+ import ru .TypeRefTag // otherwise the pattern match will be unchecked
217
+ // because TypeRef is an abstract type
218
+ ru.typeOf[T ] match { case ru.TypeRef (_, _, args) => args; case _ => Nil }
219
+ }
216
220
// [Eugene to Paul] need to use not the `rootMirror`, but a mirror with the REPL's classloader
217
221
// how do I get to it? acquiring context classloader seems unreliable because of multithreading
218
222
def typeVariables : List [java.lang.Class [_]] = typeArguments map (targ => ru.rootMirror.runtimeClass(targ))
You can’t perform that action at this time.
0 commit comments