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

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
      subscribe-nomail command to [EMAIL PROTECTED] so that your
      message can get through to the mailing list cleanly

Reply via email to