You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-03 00:45:53 +08:00
3.x ""raise AssertionError" vs "assert"
Not sure this is totally correct yet.
This commit is contained in:
@@ -12,11 +12,18 @@ assert isinstance(1, int)
|
||||
# 2.6
|
||||
# assert2 ::= assert_expr jmp_true LOAD_ASSERT expr RAISE_VARARGS_2 come_from_pop
|
||||
|
||||
for method_name in self:
|
||||
if method_name in self:
|
||||
for method_name in ['a']:
|
||||
if method_name in ('b',):
|
||||
method = 'a'
|
||||
else:
|
||||
assert 0, "instance installed"
|
||||
|
||||
methods = 'b'
|
||||
#
|
||||
|
||||
# _Bug in 3.x is not recognizing the assert
|
||||
# producing:
|
||||
# if not not do_setlocal:
|
||||
# raise AssertError
|
||||
|
||||
def getpreferredencoding(do_setlocale=True):
|
||||
assert not do_setlocale
|
||||
|
Reference in New Issue
Block a user