Add support for case matching on parameterised types (Everyone loves type erasure)