delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/10/21/12:51:08

From: "E. Glebbeek" <eglebbk AT phys DOT uva DOT nl>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: structure size rounded to int size?
Date: Thu, 21 Oct 1999 15:52:32 +0200
Organization: Dept. of Math., Comp. Sc., Phys., Astro., University of Amsterdam
Lines: 34
Distribution: world
Message-ID: <380F1A9F.34AA3808@phys.uva.nl>
References: <380F12E1 DOT 74D9DE4 AT umh DOT ac DOT be>
NNTP-Posting-Host: ow88.wins.uva.nl
Mime-Version: 1.0
X-Trace: nbox.wins.uva.nl 940513954 12690 146.50.7.95 (21 Oct 1999 13:52:34 GMT)
X-Complaints-To: news AT wins DOT uva DOT nl
NNTP-Posting-Date: 21 Oct 1999 13:52:34 GMT
X-Mailer: Mozilla 4.61 [en] (X11; I; SunOS 5.6 sun4m)
X-Accept-Language: en
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Fabrice LETE wrote:

> If I have:
>
>         typedef struct FOO {
>            short a; long b;
>         };
>
> sizeof(FOO) give me 8...
>
> What can I do to avoid the problem (I guess it's a switch to use with
> the compiler...)?

I don't think so...

>
>
> (note: I use Rhide, I suppose that it's an option to switch on
> somewhere, no?)
>
> Thanks for any advice!
>
> Fabrice Lété

This problem is addressed in section 22.10 of the DJGPP faq.

--
Evert Glebbeek, Physics Student
Faculteit WINS, Universiteit van Amsterdam
e-mail: eglebbk AT phys DOT uva DOT nl, ICQ 48210348
http://gene.wins.uva.nl/~eglebbk/



- Raw text -


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