Result<X> second,
IValueFactory vf,
TypeFactory tf,
IEvaluatorContext ctx) {
INumber iFrom = from.getValue();
INumber iTo = to.getValue();
// I still think it is ugly to do it here...
if (!second.getType().isSubtypeOf(tf.numberType())) {
throw new UnexpectedType(tf.numberType(), second.getType(), ctx.getCurrentAST());
}
INumber iSecond = (INumber) second.getValue();
INumber diff = iSecond.subtract(iFrom);
INumber zero = diff.subtract(diff); // zero in the type that we're dealing with.
// Use declared types here
Type resultType = second.getType().lub(from.getType().lub(to.getType()));
IListWriter w = vf.listWriter();