Subject: Re: detect arithmetic overflow
To: <>
From: David Laight <>
List: current-users
Date: 08/06/2003 10:18:19
> It's even easier than that. For signed addition, just check if the result
> is negative. If so, then you have overflow. For unsigned addition, you'll
> have to test it as you described, though.

errmm  -1 + -1 = -2 but hasn't overflowed


David Laight: