Re: advantage of using typedefs
- From: Jordan Abel <random832@xxxxxxxxx>
- Date: 28 Jan 2006 23:50:00 GMT
On 2006-01-28, Keith Thompson <kst-u@xxxxxxx> wrote:
> Mark McIntyre <markmcintyre@xxxxxxxxxxx> writes:
>> On Sat, 28 Jan 2006 19:32:56 GMT, in comp.lang.c , Keith Thompson
>> <kst-u@xxxxxxx> wrote:
>>>Mark McIntyre <markmcintyre@xxxxxxxxxxx> writes:
>>>> On 28 Jan 2006 00:50:55 -0800, in comp.lang.c ,
>>>> "junky_fellow@xxxxxxxxxxx" <junky_fellow@xxxxxxxxxxx> wrote:
>>>>
>>>>>I believe unsigned long long should be highest possible integer type ?
>>>>>Or am I wrong ?
>>>>
>>>> You're right, but the size of long long varies from platform to
>>>> platform
>>>
>>>Yes, but if you want the biggest unsigned integer type, you have to
>>>accept that its size is going to vary.
>>
>> ... which was my point.
>
> Then I'm confused. junky_fellow's question was:
>
> But if this is the case (ie we need the biggest possible unsigned
> integer to hold offset ) then why not declare unsigned long long
> offset
>
> and you replied:
>
> Because then its size would vary from platform to platform, and on
> a c90 implementation it would be an error.
Regardless, there's a factual problem. The "offset" (assuming it is
posix off_t) is used in places where it must be negative, and thus
should not be unsigned anything. the original post said long, not
unsigned long.
.
- References:
- advantage of using typedefs
- From: junky_fellow@xxxxxxxxxxx
- Re: advantage of using typedefs
- From: Emmanuel Delahaye
- Re: advantage of using typedefs
- From: junky_fellow@xxxxxxxxxxx
- Re: advantage of using typedefs
- From: Mark McIntyre
- Re: advantage of using typedefs
- From: Keith Thompson
- Re: advantage of using typedefs
- From: Mark McIntyre
- Re: advantage of using typedefs
- From: Keith Thompson
- advantage of using typedefs
- Prev by Date: Re: advantage of using typedefs
- Next by Date: Re: NULL with representation other then all bits 0
- Previous by thread: Re: advantage of using typedefs
- Next by thread: Re: advantage of using typedefs
- Index(es):
Relevant Pages
|