Support generic types when emitting constructors

It's not possible to create parameterized classes with a constructor because beginConstructor uses the parameterized type as the constructor name instead of the raw type.