Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Re: cvs commit: parrot/t/dynclass pyfunc.t pyclass.t

6 views
Skip to first unread message

Sam Ruby

unread,
Dec 2, 2004, 5:15:12 PM12/2/04
to Michael Walter, perl6-i...@perl.org
Michael Walter wrote:

> Uh, C89 is an ANSI/ISO C.

I'm not enough of a language lawyer to know when various features came
into to the language, but

gcc -std=c89 test.c

does *NOT* warn about declaration ordering issues. At least not with
gcc version 3.3.4 (Debian 1:3.3.4-6sarge1)

- Sam Ruby

Leopold Toetsch

unread,
Dec 2, 2004, 11:24:56 AM12/2/04
to Sam Ruby, perl6-i...@perl.org
Sam Ruby <ru...@cvs.perl.org> wrote:
> + void init () {
> + SUPER();
> + PMC *func_args = pmc_new(INTERP, dynclass_PyList);

Please be careful to avoid definitions after code. This doesn't compile
with C89 compilers like gcc 2.95.3

leo

Klaas-Jan Stol

unread,
Dec 3, 2004, 4:23:28 AM12/3/04
to Sam Ruby, Michael Walter, perl6-i...@perl.org
Sam Ruby wrote:

If I remember correctly, MS Visual Studio *will* emit errors for this (I
used VS 6.0, a long time ago).

Klaas-Jan


Michael Walter

unread,
Dec 2, 2004, 4:16:24 PM12/2/04
to Sam Ruby, l...@toetsch.at, perl6-i...@perl.org
Uh, C89 is an ANSI/ISO C.

> Sorry about that.
>
> Stupid question: why don't we compile with an option that flags such
> things? Example:
>
> $ gcc -Wtraditional test.c
> test.c: In function `main':
> test.c:3: warning: traditional C rejects ISO C style function definitions
>
> - Sam Ruby
>

Sam Ruby

unread,
Dec 2, 2004, 3:55:21 PM12/2/04
to l...@toetsch.at, perl6-i...@perl.org
Leopold Toetsch wrote:

Sorry about that.

Sam Ruby

unread,
Dec 3, 2004, 8:11:07 AM12/3/04
to Klaas-Jan Stol, perl6-i...@perl.org
Klaas-Jan Stol wrote:

Just to be clear - I have nothing against the policy that Parrot will be
able to compiled on these compilers. I just want to shift more of the
the burden from the victims to the perpetrator (me!).

- Sam Ruby

0 new messages