Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

With generics, the metatype of a type variable is an interface type. If you just had T, it’s grammatically incomplete because you don’t specify the metatype. I guess you could just assume the any type if it’s incomplete, but that’s an unnecessary inconsistency in the grammar.


I don't know. Making constraints optional is the way it works in all the other languages I use.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: