Details
-
Type:
Wish
-
Status:
Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 1.8.4
-
Fix Version/s: 1.8.5, 2.0-beta-2
-
Component/s: None
-
Labels:None
-
Number of attachments :
Description
Recent changes in DelegateASTTransformation have introduced a dependence on ClassNode.getTypeClass(). As mentioned in other Jiras, the tools don't work well when getTypeClass() is used as we treat ClassNode as a proper type abstraction, we don't always have a real class file behind it (so getTypeClass() will usually return null).
At line 220, instead of:
return ClassHelper.makeWithoutCaching(type.getTypeClass(), false);
can we do something like:
return type.getComponentType().getPlainNodeReference().makeArray();
Fixed. I also added a javadoc for getTypeClass() for developers to be aware that using this method is unsafe.