Amaury Forgeot d'Arc <amaur...@gmail.com> added the comment:

IMO a better patch would be to use the %R format specification:
  PyErr_Format(
      PyExc_TypeError, "expected some sort of mod, but got %R", obj);
And no need to use PyObject_Repr and the temporary variable!

----------
nosy: +amaury.forgeotdarc

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue10391>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to