X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f Date: Tue, 24 Feb 2004 10:39:28 -0500 Message-Id: <200402241539.i1OFdSon024698@envy.delorie.com> From: DJ Delorie To: djgpp AT delorie DOT com In-reply-to: (message from Hans-Bernhard Broeker on 24 Feb 2004 13:12:22 GMT) Subject: Re: Fibonacci number References: <4038E8CA DOT 6491815E AT virginia DOT edu> <4039DD96 DOT 3F36F3B7 AT yahoo DOT com> <200402231458 DOT i1NEwKwm020904 AT envy DOT delorie DOT com> <403A301C DOT E8F5FE65 AT yahoo DOT com> <200402231751 DOT i1NHp5lv022894 AT envy DOT delorie DOT com> Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > Since negation is a well-defined operation on unsigned longs, there's > no error involved. This makes no sense. *All* arithmetic operations are well defined for all integer types, but still, POSIX requires a range error. IMHO this means we're meant to check the range of the number *before* folding it to the target type.