2008/7/10 TSa <[EMAIL PROTECTED]>:
> So, does it make sense to define ++ and -- for nums as
> $x++ meaning $x += $x.step?

No.

> Or should these operators floor the value to an Int and step the result?

No.

For any numeric type of $x, $x++ should mean $x += 1.    3.14 becomes
4.14. -3.14 becomes -2.14 (which indicates that floor() is not
involved) . 5/8 becomes 13/8.  The step size is irrelevant.  If $x is
so large that adding 1 gets lost due to the precision, then OK, ++$x
== $x.

All of this is IMESHO, of course, but I feel rather strongly on this
issue. " ++ " means " += 1 ".

-- 
Mark J. Reed <[EMAIL PROTECTED]>

Reply via email to