acceptsType method
Will return true if type
can be cast to this type.
Note: This is similar to Java isInstance
and isAssignableFrom
.
Implementation
@override
bool acceptsType(ASTType type) {
if (type == this ||
type == ASTTypeDouble.instance ||
type == ASTTypeInt.instance) return true;
return false;
}