[Pyrex] python 2.2 support?

didier deshommes dfdeshom at gmail.com
Thu Aug 3 21:45:06 UTC 2006


Allo all,
I am trying to compile a Pyrex program using python2.2 on a Mac (OSX
10.2), and I'm getting these errors:
"NameError: global name 'False' is not defined".

These appear in Pyrex/Compiler/Code.py and Main.py. As I understand
it, Python 2.2 has no True, False, only 1 and 0. Has support for
Python 2.2 dropped from Pyrex? I was under the impression that Pyrex
had support Python2.2 and higher...

After placing
True =1
False = 0

on top of the offending files, my pyrex program fails to compile. The
same error happens for primes.pyx:

primes.c:176: parse error before "initprimes"
primes.c:176: warning: type defaults to `int' in declaration of `initprimes'
primes.c:176: warning: data definition has no type or storage class
primes.c:177: parse error before "initprimes"
primes.c:177: warning: return type defaults to `int'

Anyone know what's going on?

Cheers,
didier



More information about the Pyrex mailing list