Thanks.
David

On Wed, Feb 13, 2013 at 10:29 PM, Robert Bradshaw <rober...@gmail.com>wrote:

> This is due to the archaic --disable-function-redefinition flag.
>
> On Mon, Feb 4, 2013 at 4:28 PM, David Roe <roed.m...@gmail.com> wrote:
> > Hi everyone,
> > I ran into the following problem using Cython 0.17.4 (current version of
> > Sage).
> >
> > If you try to compile a file with the following function in it:
> >
> > def test_double_gen(L):
> >     a = all(x != 0 for x in L)
> >     b = all(x != 1 for x in L)
> >     return a and b
> >
> > you get errors from the Cython compiler about 'genexpr' being redefined.
> >
> > Error compiling Cython file:
> > ------------------------------------------------------------
> > ...
> >
> >
> > def test_double_gen(L):
> >     a = all(x != 0 for x in L)
> >     b = all(x != 1 for x in L)
> >              ^
> > ------------------------------------------------------------
> >
> > cython_test.pyx:5:14: 'genexpr' already declared
> >
> > Error compiling Cython file:
> > ------------------------------------------------------------
> > ...
> >
> >
> > def test_double_gen(L):
> >     a = all(x != 0 for x in L)
> >              ^
> > ------------------------------------------------------------
> >
> > cython_test.pyx:4:14: Previous declaration is here
> >
> > Error compiling Cython file:
> > ------------------------------------------------------------
> > ...
> >
> >
> > def test_double_gen(L):
> >     a = all(x != 0 for x in L)
> >     b = all(x != 1 for x in L)
> >              ^
> > ------------------------------------------------------------
> >
> > cython_test.pyx:5:14: 'genexpr' redeclared
> >
> > Are you currently only able to use one inline generator pre function?
> > David
> >
> >
> > _______________________________________________
> > cython-devel mailing list
> > cython-devel@python.org
> > http://mail.python.org/mailman/listinfo/cython-devel
> >
> _______________________________________________
> cython-devel mailing list
> cython-devel@python.org
> http://mail.python.org/mailman/listinfo/cython-devel
>
_______________________________________________
cython-devel mailing list
cython-devel@python.org
http://mail.python.org/mailman/listinfo/cython-devel

Reply via email to