Cython has moved to github.

cython-devel

view tests/run/temps_corner1.pyx @ 1289:82084a7b654e

Add corner case temp (de)allocation test.

This is as simple as I could get it.
author Robert Bradshaw <robertwb@math.washington.edu>
date Thu Oct 30 00:56:21 2008 -0700 (3 years ago)
parents
children 0310198e281e
line source
1 __doc__ = """
2 >>> B().coeffs_bitsize()
3 [2]
4 """
6 cdef class A:
7 def numerator(self):
8 return self
10 cdef int bitsize(A a):
11 return 1
13 coeffs = [A()]
15 class B:
16 def coeffs_bitsize(self):
17 r = [bitsize(c.numerator())+1 for c in coeffs]
18 return r