Message110635
> Somewhere along the way native_table is used instead of lilendian_table,
> so np_bool is called.
Hmm. This doesn't alleviate my confusion. :)
The relevant part of test_struct looks like:
for prefix in tuple("<>!=")+('',):
# other tests
try:
struct.pack(prefix + '?', ExplodingBool())
except IOError:
pass
else:
self.fail("Expected IOError: struct.pack(%r, "
"ExplodingBool())" % (prefix + '?'))
So the '<?' test should happen directly before the '>?' test. But the '<?' test was apparently passing, while the '>?' one was failing. I don't see how native_table is relevant here, but am probably missing something.
On the other hand, with the pre-patch code, we end up with a method that sets a Python error but then returns a return value that indicates no error happened, and all sorts of unpredictable things can happen at that point... |
|
Date |
User |
Action |
Args |
2010-07-18 11:38:08 | mark.dickinson | set | recipients:
+ mark.dickinson, skrah |
2010-07-18 11:38:08 | mark.dickinson | set | messageid: <1279453088.15.0.855173595488.issue9277@psf.upfronthosting.co.za> |
2010-07-18 11:38:06 | mark.dickinson | link | issue9277 messages |
2010-07-18 11:38:06 | mark.dickinson | create | |
|