[pypy-svn] r47412 - in pypy/dist/pypy/translator/c: . test
simonb at codespeak.net
simonb at codespeak.net
Fri Oct 12 20:05:10 CEST 2007
Author: simonb
Date: Fri Oct 12 20:05:09 2007
New Revision: 47412
Modified:
pypy/dist/pypy/translator/c/support.py
pypy/dist/pypy/translator/c/test/test_typed.py
Log:
simonb, Amaury: fix comparison.
In gen_assignments(), variable names are
compared by reference, but source and destination names are are
constructed in different ways.
Modified: pypy/dist/pypy/translator/c/support.py
==============================================================================
--- pypy/dist/pypy/translator/c/support.py (original)
+++ pypy/dist/pypy/translator/c/support.py Fri Oct 12 20:05:09 2007
@@ -205,7 +205,7 @@
startingpoint = dst
tmpdecl = cdecl(typename, 'tmp')
code = ['{ %s = %s;' % (tmpdecl, dst)]
- while src is not startingpoint:
+ while src != startingpoint:
code.append('%s = %s;' % (dst, src))
dst = src
src, typename = dest2src.pop(dst)
Modified: pypy/dist/pypy/translator/c/test/test_typed.py
==============================================================================
--- pypy/dist/pypy/translator/c/test/test_typed.py (original)
+++ pypy/dist/pypy/translator/c/test/test_typed.py Fri Oct 12 20:05:09 2007
@@ -772,7 +772,6 @@
assert res == expected
def test_swap(self):
- py.test.skip("Failing test. ")
def func_swap():
a = []
b = range(10)
More information about the Pypy-commit
mailing list