[pypy-issue] Issue #1898: isinstance with unicode fails to translate (pypy/pypy)

halgari issues-reply at bitbucket.org
Tue Oct 21 05:04:29 CEST 2014

New issue 1898: isinstance with unicode fails to translate


My interpreter blows up during translation with the following error: 

[translation:info]    File "/home/travis/build/pixie-lang/externals/pypy/rpython/rtyper/rbuiltin.py", line 701, in rtype_builtin_isinstance
[translation:info]     assert isinstance(hop.args_r[0], rclass.InstanceRepr)

I took a look at the code in rbuiltin.py and noticed that the function is special cased for str and list, but not unicode. So as I test I added unicode to the tuple of special cases, and the code translates correctly. So I assume this is a bug?

You can give this a try by downloading http://github.com/pixie-lang/pixie , running ./checkout-externals, and then ./make-with-jit

More information about the pypy-issue mailing list