[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: apr_off_t is of an ambiguous size.

From: Russell Yanofsky <rey4_at_columbia.edu>
Date: 2004-01-19 20:49:26 CET

Greg Hudson wrote:
> Russell Yanofsky wrote:
>> Well, I did ask whether it was ok to assume 2's complement
>
> Even if you could assume two's complement, you can't assume that the
> environment won't raise a signal on signed integer overflow. (Not
> that I've ever heard of an environment which does.)

Hmm. An environment that triggers overflows on bitwise operations. That
can't be a pretty sight, but I don't doubt that the C standard allows it.

>> I'm curious about something else. Does the standard allows just
>> these three representations, or does it allow any representation?
>> If it allows just those three, then in theory you could write a
>> big ass conditional expression that works everywhere.
>
> Just those three. I'm not sure if you can determine which you have
> without risking an overflow, though.

Interesting. Thanks for answering my questions. I'd RTFS if I had a copy...

- Russ

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Jan 19 21:00:34 2004

This is an archived mail posted to the Subversion Dev mailing list.