[pypy-issue] [issue1689] Unhelpful AssertionError on comparing strings with unicode

Ronan Lamy tracker at bugs.pypy.org
Tue Feb 11 02:06:20 CET 2014


Ronan Lamy <ronan.lamy at gmail.com> added the comment:

That kind of user error should be caught earlier, in the annotation stage, where
we already have the machinery in place to give sensible feedback to the user.
More precisely, we should define the annotation of op.eq(<string>, <unicode>) to
raise an AnnotationError.

Also, this issue is an instance of a more general problem: we should define
clearly RPython's behaviour when comparing objects of incompatible types.

----------
nosy: +rlamy
status: unread -> chatting

________________________________________
PyPy bug tracker <tracker at bugs.pypy.org>
<https://bugs.pypy.org/issue1689>
________________________________________


More information about the pypy-issue mailing list