comp.lang.ada
 help / color / mirror / Atom feed
From: Ludovic Brenta <ludovic@ludovic-brenta.org>
Subject: Re: Type convertion
Date: Wed, 12 Mar 2008 21:45:28 +0100
Date: 2008-03-12T21:45:28+01:00	[thread overview]
Message-ID: <87r6efsmc7.fsf@ludovic-brenta.org> (raw)
In-Reply-To: m2skyv8ysr.fsf@mac.com

Simon Wright writes:
> Ludovic Brenta writes:
>
>> typedef enum { ab, cd, ef, gh, ij } type_t;
>
> Is sizeof(type_t) here defined to be the same as sizeof(int)? (it was,
> in a little experiment).

Yes.  My C is getting rustier by the day but I seem to remember that
the language standard does require enums to have the same size as int.

-- 
Ludovic Brenta.



  reply	other threads:[~2008-03-12 20:45 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-11 16:10 Type convertion news.broadpark.no
2008-03-11 16:59 ` Ed Falis
2008-03-11 20:45   ` Ludovic Brenta
2008-03-12 20:36     ` Simon Wright
2008-03-12 20:45       ` Ludovic Brenta [this message]
2008-03-13  8:33         ` Maciej Sobczak
2008-03-24  2:14           ` David Thompson
2008-03-11 17:39 ` Jeffrey R. Carter
2008-03-11 20:53   ` news.broadpark.no
2008-03-11 21:40     ` Ludovic Brenta
2008-03-11 17:49 ` Stuart
2008-03-11 20:56   ` news.broadpark.no
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox