Instead of taking mytype, can you take (implicit cmf: ClassManifest[T]) and then use .erasure to get the class out below.