super(goal);
}
public IGoal[] init() {
ExpressionTypeGoal typedGoal = (ExpressionTypeGoal) goal;
CastExpression castExpression = (CastExpression) typedGoal
.getExpression();
int operator = castExpression.getCastType();
switch (operator) {
case CastExpression.TYPE_INT:
case CastExpression.TYPE_REAL:
result = new SimpleType(SimpleType.TYPE_NUMBER);
break;
case CastExpression.TYPE_STRING:
result = new SimpleType(SimpleType.TYPE_STRING);
break;
case CastExpression.TYPE_ARRAY:
result = new SimpleType(SimpleType.TYPE_ARRAY);
break;
case CastExpression.TYPE_OBJECT:
return new IGoal[] { new ExpressionTypeGoal(typedGoal.getContext(),
castExpression.getExpr()) };
case CastExpression.TYPE_BOOL:
result = new SimpleType(SimpleType.TYPE_BOOLEAN);
break;
case CastExpression.TYPE_UNSET:
result = new SimpleType(SimpleType.TYPE_NULL);