delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/05/04/05:18:25

Date: Thu, 4 May 2000 14:12:26 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Alexandre Devaure <Alexandre DOT Devaure AT leroy-autom DOT com>
cc: djgpp AT delorie DOT com
Subject: Re: structures size
In-Reply-To: <005b01bfb593$eb5b1c60$3eefa8c0@leroyautom.com>
Message-ID: <Pine.SUN.3.91.1000504141054.18008C@is>
MIME-Version: 1.0
Reply-To: djgpp AT 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

On Thu, 4 May 2000, Alexandre Devaure wrote:

> struct l {
>         uchar c;
>         uint o;
>         uint s;
> };
> struct st {
>         struct l l;
>         ulong d;
>         uchar i;
>         uchar t;
>         ulong n;
> };
> 
> main()
> {
>         printf("%d\n",sizeof(struct st));
> }
> 
> the command line is gcc -fpack-struct file.c

What did you expect this program to print?

- Raw text -


  webmaster     delorie software   privacy  
  Copyright 2019   by DJ Delorie     Updated Jul 2019