kotlinpoet
kotlinpoet copied to clipboard
Subclasses of `TypeName` return `TypeName` from `copy`
If you for example call copy
on a ClassName
, you get TypeName
returned.
The copy
with tags
parameter is overridden in the subclasses and returns the respective subclass.
But the copy
without tags
parameter always returns TypeName
.
It would be nice if TypeName
could get a type parameter that the subclass sets to itself and then both copy
functions return the actual subclass.