
03-15-2008, 04:57 PM
|
|
Programming Expert
|
|
Join Date: Mar 2008
Posts: 371
Credits: 0
Rep Power: 7
|
|
Re: swapping
Quote:
Originally Posted by Walle
Is it?
What behavior is undefined?
|
When signed arithmetic over/underflows, the behavior is undefined.
Quote:
Originally Posted by Walle
What would you say is a smarter way to do it?
|
The obvious way, using a temporary.
|