Re: Is this portable?

Поиск
Список
Период
Сортировка
От Zdenek Kotala
Тема Re: Is this portable?
Дата
Msg-id 46115E0D.7020208@sun.com
обсуждение исходный текст
Ответ на Is this portable?  (Alvaro Herrera <alvherre@commandprompt.com>)
Ответы Re: Is this portable?  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Alvaro Herrera wrote:
> Can I declare a struct in a function's declaration section?  Something
> like this:
> 
> static void
> foobar(void)
> {
>     struct foo {
>         Oid        foo;
>         int        bar;
>     };
> 
>     struct foo baz;
> 
>     baz.foo = InvalidOid;
>     baz.bar = 42;
> 
> }
> 
> I tried here and GCC does not complain, with -std=c89 -pedantic.
> 

It works fine with Sun Studio 11.
    Zdenek


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: CheckpointStartLock starvation
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: So are we calling it: Feature Freeze?