what you are asking for is the MyType pattern which is not supported in Scala, see scala mailing list archives (look for Martin’s posts)