Message5113

Author zyasoft
Recipients fwierzbicki, hpk, zyasoft
Date 2009-09-07.17:58:46
SpamBayes Score 1.6930901e-14
Marked as misclassified No
Message-id <1252346327.07.0.196145735873.issue1461@psf.upfronthosting.co.za>
In-reply-to
Content
The relevant problem is in org.python.compiler.CodeCompiler#visitAssert:

        code.getstatic("org/python/core/Py", "AssertionError",
"Lorg/python/core/PyObject;");

We can't use this optimization to the standard builtin AssertionError,
instead it should be using getattr. Notably in CPython, this is possible
to do:

>>> import __builtin__
>>> del __builtin__.AssertionError
>>> assert 0
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
NameError: global name 'AssertionError' is not defined
History
Date User Action Args
2009-09-07 17:58:47zyasoftsetmessageid: <1252346327.07.0.196145735873.issue1461@psf.upfronthosting.co.za>
2009-09-07 17:58:47zyasoftsetrecipients: + zyasoft, fwierzbicki, hpk
2009-09-07 17:58:47zyasoftlinkissue1461 messages
2009-09-07 17:58:46zyasoftcreate