Cython has moved to github.

cython-devel

view tests/run/future_division.pyx @ 1622:4f0327bdebc9

test for temp allocation bug in call
author Robert Bradshaw <robertwb@math.washington.edu>
date Sat Jan 17 01:25:34 2009 -0800 (3 years ago)
parents
children 0310198e281e
line source
1 from __future__ import division
3 __doc__ = """
4 >>> from future_division import doit
5 >>> doit(1,2)
6 (0.5, 0)
7 >>> doit(4,3)
8 (1.3333333333333333, 1)
9 >>> doit(4,3.0)
10 (1.3333333333333333, 1.0)
11 >>> doit(4,2)
12 (2.0, 2)
13 """
15 def doit(x,y):
16 return x/y, x//y