blob: 072c12adb087882843e204b7c8a04726ec308959 (
plain) (
tree)
|
|
import scala.reflect.runtime.universe._
import scala.reflect.{ClassTag, classTag}
object Test extends App {
def typeTagIsnotClassTag[T: TypeTag] = {
println(classTag[T])
}
typeTagIsnotClassTag[Int]
typeTagIsnotClassTag[String]
typeTagIsnotClassTag[Array[Int]]
}
|