[Pyrex] array cdefs

Matthieu Brucher matthieu.brucher at gmail.com
Mon Dec 3 23:04:43 CET 2007


In fact, it is not C++ at all, it's C99 (variable lenth arrays, only exist
for C99 compilers, not C89 ones like Visual Studio for instance).

Matthieu

2007/12/3, Greg Ewing <greg.ewing at canterbury.ac.nz>:
>
> moreilcon at gmail.com wrote:
> > /* C code, works well */
> > void
> > foo(int size)
> > {
> >     int array[size];
> > }
>
> Strictly speaking this is a C++ thing and isn't
> standard C:
>
> % gcc -c -ansi -pedantic foo.c
> foo.c: In function `foo':
> foo.c:2: warning: ISO C90 forbids variable-size array `array'
>
> Pyrex only generates standard C code, so it doesn't
> support this.
>
> --
> Greg
>
> _______________________________________________
> Pyrex mailing list
> Pyrex at lists.copyleft.no
> http://lists.copyleft.no/mailman/listinfo/pyrex
>



-- 
French PhD student
Website : http://miles.developpez.com/
Blogs : http://matt.eifelle.com and http://blog.developpez.com/?blog=92
LinkedIn : http://www.linkedin.com/in/matthieubrucher
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.copyleft.no/pipermail/pyrex/attachments/20071203/b6cacc37/attachment.html 


More information about the Pyrex mailing list