At 12:02 AM 12/3/2010, Kevin Schoedel wrote:
No. The reason you got a "floating point
exception" is that Unix
traditionally lumps integer arithmetic fault together with floating point
faults under one signal, SIGFPE.
I had a hard time imagining a C that used floating point ops to
handle integer divides. On the other hand, if someone wasn't
watching the type of their variables, they might not realize
that a right-hand operation would be calculated as floats,
even if it was being stored back into an int.
Also,
"TF"[!b]
At 8:35 pm -0800 2010/12/02, Chuck Guzis wrote:
>Does any C detect integer overflow (i.e. subtracting a large positive
>number from a negative and getting a positive number back)?
Overflow? What if that was what you wanted to happen? After all,
you wrote it that way.
- John