Closed claesrosell closed 6 months ago
I really want to see a sample project (zip) that compiles and illustrates the problem being fixed.
If I enable data converters for the package of the model from the other issue, this method is generated in the XyzFactory:
MyDataType<?> createEMyDataType(String literal);
If we're going to do casting, I'd prefer not to use a raw type but rather an unchecked cast. probably something like this:
@SuppressWarnings("unchecked")
protected static final MyDataType<Float> MY_ATTRIBUTE_EDEFAULT = (MyDataType<Float>)MyModelFactory.eINSTANCE.createFromString(MyModelPackage.eINSTANCE.getEMyDataType(), "1");
But I'm running out of time to look at this today and I have very limited time tomorrow before I'm out until Thursday, and M2 for consumption by the Platform is due tomorrow...
This is superseded by:
GenFeature.getStaticDefaultValue() now checks if the type is generic and if so, adds a cast to the raw type of the feature instead of the EDataType's type.