PATH: //lib64/python3.9/lib2to3/fixes
FILE_BARU
CREATE
FOLDER_BARU
MKDIR
UPLOAD_FILE
GO
[ .. KEMBALI ]
📄 __init__.py
↓
X
📁 __pycache__/
X
📄 fix_apply.py
↓
X
📄 fix_asserts.py
↓
X
📄 fix_basestring.py
↓
X
📄 fix_buffer.py
↓
X
📄 fix_dict.py
↓
X
📄 fix_except.py
↓
X
📄 fix_exec.py
↓
X
📄 fix_execfile.py
↓
X
📄 fix_exitfunc.py
↓
X
📄 fix_filter.py
↓
X
📄 fix_funcattrs.py
↓
X
📄 fix_future.py
↓
X
📄 fix_getcwdu.py
↓
X
📄 fix_has_key.py
↓
X
📄 fix_idioms.py
↓
X
📄 fix_import.py
↓
X
📄 fix_imports.py
↓
X
📄 fix_imports2.py
↓
X
📄 fix_input.py
↓
X
📄 fix_intern.py
↓
X
📄 fix_isinstance.py
↓
X
📄 fix_itertools.py
↓
X
📄 fix_itertools_imports.py
↓
X
📄 fix_long.py
↓
X
📄 fix_map.py
↓
X
📄 fix_metaclass.py
↓
X
📄 fix_methodattrs.py
↓
X
📄 fix_ne.py
↓
X
📄 fix_next.py
↓
X
📄 fix_nonzero.py
↓
X
📄 fix_numliterals.py
↓
X
📄 fix_operator.py
↓
X
📄 fix_paren.py
↓
X
📄 fix_print.py
↓
X
📄 fix_raise.py
↓
X
📄 fix_raw_input.py
↓
X
📄 fix_reduce.py
↓
X
📄 fix_reload.py
↓
X
📄 fix_renames.py
↓
X
📄 fix_repr.py
↓
X
📄 fix_set_literal.py
↓
X
📄 fix_standarderror.py
↓
X
📄 fix_sys_exc.py
↓
X
📄 fix_throw.py
↓
X
📄 fix_tuple_params.py
↓
X
📄 fix_types.py
↓
X
📄 fix_unicode.py
↓
X
📄 fix_urllib.py
↓
X
📄 fix_ws_comma.py
↓
X
📄 fix_xrange.py
↓
X
📄 fix_xreadlines.py
↓
X
📄 fix_zip.py
↓
X
SAVING...
BERHASIL DIUBAH!
EDITING: fix_sys_exc.py
"""Fixer for sys.exc_{type, value, traceback} sys.exc_type -> sys.exc_info()[0] sys.exc_value -> sys.exc_info()[1] sys.exc_traceback -> sys.exc_info()[2] """ # By Jeff Balogh and Benjamin Peterson # Local imports from .. import fixer_base from ..fixer_util import Attr, Call, Name, Number, Subscript, Node, syms class FixSysExc(fixer_base.BaseFix): # This order matches the ordering of sys.exc_info(). exc_info = ["exc_type", "exc_value", "exc_traceback"] BM_compatible = True PATTERN = """ power< 'sys' trailer< dot='.' attribute=(%s) > > """ % '|'.join("'%s'" % e for e in exc_info) def transform(self, node, results): sys_attr = results["attribute"][0] index = Number(self.exc_info.index(sys_attr.value)) call = Call(Name("exc_info"), prefix=sys_attr.prefix) attr = Attr(Name("sys"), call) attr[1].children[0].prefix = results["dot"].prefix attr.append(Subscript(index)) return Node(syms.power, attr, prefix=node.prefix)
SIMPAN PERUBAHAN