🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: fr.comp.lang.c
Article #15440

Re: alignements struct/tableaux

#15440
From: Pierre Habouzit
Date: Mon, 19 Sep 2005 20:23
38 lines
2235 bytes
> C>type struct.C
> typedef int blob_t[5];
> 
> struct message {
>      struct {
>          const blob_t *original;
>          blob_t *scratch;
>      };
> } *hdr;
> 
> 
> int main() {
> 
>         hdr->scratch;
>         return 0;
> }
> 
> C>bin\gcc -v -ansi struct.c
> Reading specs from bin/../lib/gcc/mingw32/3.4.2/specs
> [couic]
> GNU C version 3.4.2 (mingw-special) (mingw32)
>         compiled by GNU C version 3.4.2 (mingw-special).
> [couic]
> 
> struct.c:7: warning: declaration does not declare anything
> struct.c: In function `main':
> struct.c:13: error: structure has no member named `scratch'

ah tiens, c'est donc une extension GCC ...
hmmmmm

bon, /me note qu'il a du code pas portable � corriger.
crotte.
-- 
�O�  Pierre Habouzit
��O                                                madcoder@debian.org
OOO                                                http://www.madism.org
Technical Details
Message-ID: <432f1dee$0$5904$626a14ce@news.free.fr>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!proxad.net!proxad.net!infeed-2.proxad.net!news18-e.free.fr!not-for-mail
References: <432c52d5$0$9425$626a14ce@news.free.fr> <mn.8cb87d59c7031bee.15512@YOURBRAnoos.fr> <432c688a$0$14382$626a14ce@news.free.fr> <432c6c63$0$17061$8fcfb975@news.wanadoo.fr> <432c77ed$0$12670$626a14ce@news.free.fr> <432d0eca$0$5402$8fcfb975@news.wanadoo.fr> <432d35cb$0$9448$626a14ce@news.free.fr> <dgmc3m$63j$1@shakotay.alphanet.ch>

Show Full Headers
Complete Article Headers
X-Google-Thread: f9822,2ab126dba8e5e645
X-Google-Attributes: gidf9822,public
X-Google-Language: ENGLISH,ASCII
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!proxad.net!proxad.net!infeed-2.proxad.net!news18-e.free.fr!not-for-mail
Message-ID: <432f1dee$0$5904$626a14ce@news.free.fr>
From: Pierre Habouzit <madcoder@debian.org>
Subject: Re: alignements struct/tableaux
Newsgroups: fr.comp.lang.c
Date: Mon, 19 Sep 2005 22:23:13 +0200
References: <432c52d5$0$9425$626a14ce@news.free.fr> <mn.8cb87d59c7031bee.15512@YOURBRAnoos.fr> <432c688a$0$14382$626a14ce@news.free.fr> <432c6c63$0$17061$8fcfb975@news.wanadoo.fr> <432c77ed$0$12670$626a14ce@news.free.fr> <432d0eca$0$5402$8fcfb975@news.wanadoo.fr> <432d35cb$0$9448$626a14ce@news.free.fr> <dgmc3m$63j$1@shakotay.alphanet.ch>
User-Agent: KNode/0.9.2
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-15
Content-Transfer-Encoding: 8Bit
X-Face: $(^e[V4D-[`f2EmMGz@fgWK!e.B~2g.{08lKPU(nc1J~z\4B>*JEVq:E]7G-\6$Ycr4<;Z!|VY6Grt]+RsS$IMV)f>2)M="tY:ZPcU;&%it2D81X^kNya0=L]"vZmLP+UmKhgq+u*\.dJ8G!N&=EvlD
Lines: 38
Organization: Guest of ProXad - France
NNTP-Posting-Date: 19 Sep 2005 22:22:07 MEST
NNTP-Posting-Host: 82.225.205.10
X-Trace: 1127161327 news18-e.free.fr 5904 82.225.205.10:54609
X-Complaints-To: abuse@proxad.net