www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/12/07/00:36:57

Message-Id: <4C6D083001E72A00@iris.ernet.in>
Date: 06 Dec 96 20:43 IST
From: tehmul%NIITPUN AT iris DOT ernet DOT in
Sender: tehmul%niitpun AT iris DOT ernet DOT in
To: djgpp AT delorie DOT com
Subject: Padding Question
Mime-Version: 1.0

                              

rohit AT hotmail wrote:

> Hi !!
Ditto.

> Is it possible to stop gcc from padding structures ?
Yes.  (I'm sure someone will tell you to RTFM :)  But anyway, here goes:

     struct junk
     { //structure details
     } __attribute__((packed)); 

That ought to do it.  But read the FAQ, there's a real wealth of info there.

>Thnx. 
You're welcome.

Ciao,
TG


- Raw text -


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