diff options
| author | shadchin <[email protected]> | 2022-04-18 12:39:32 +0300 |
|---|---|---|
| committer | shadchin <[email protected]> | 2022-04-18 12:39:32 +0300 |
| commit | d4be68e361f4258cf0848fc70018dfe37a2acc24 (patch) | |
| tree | 153e294cd97ac8b5d7a989612704a0c1f58e8ad4 /contrib/tools/python3/src/Python | |
| parent | 260c02f5ccf242d9d9b8a873afaf6588c00237d6 (diff) | |
IGNIETFERRO-1816 Update Python 3 from 3.9.12 to 3.10.4
ref:9f96be6d02ee8044fdd6f124b799b270c20ce641
Diffstat (limited to 'contrib/tools/python3/src/Python')
60 files changed, 16658 insertions, 19257 deletions
diff --git a/contrib/tools/python3/src/Python/Python-ast.c b/contrib/tools/python3/src/Python/Python-ast.c index 8b1c594a878..2f84cad7749 100644 --- a/contrib/tools/python3/src/Python/Python-ast.c +++ b/contrib/tools/python3/src/Python/Python-ast.c @@ -1,258 +1,31 @@ -/* File automatically generated by Parser/asdl_c.py. */ - -#include <stddef.h> +// File automatically generated by Parser/asdl_c.py. #include "Python.h" -#include "Python-ast.h" -#include "structmember.h" // PyMemberDef - -typedef struct { - int initialized; - PyObject *AST_type; - PyObject *Add_singleton; - PyObject *Add_type; - PyObject *And_singleton; - PyObject *And_type; - PyObject *AnnAssign_type; - PyObject *Assert_type; - PyObject *Assign_type; - PyObject *AsyncFor_type; - PyObject *AsyncFunctionDef_type; - PyObject *AsyncWith_type; - PyObject *Attribute_type; - PyObject *AugAssign_type; - PyObject *Await_type; - PyObject *BinOp_type; - PyObject *BitAnd_singleton; - PyObject *BitAnd_type; - PyObject *BitOr_singleton; - PyObject *BitOr_type; - PyObject *BitXor_singleton; - PyObject *BitXor_type; - PyObject *BoolOp_type; - PyObject *Break_type; - PyObject *Call_type; - PyObject *ClassDef_type; - PyObject *Compare_type; - PyObject *Constant_type; - PyObject *Continue_type; - PyObject *Del_singleton; - PyObject *Del_type; - PyObject *Delete_type; - PyObject *DictComp_type; - PyObject *Dict_type; - PyObject *Div_singleton; - PyObject *Div_type; - PyObject *Eq_singleton; - PyObject *Eq_type; - PyObject *ExceptHandler_type; - PyObject *Expr_type; - PyObject *Expression_type; - PyObject *FloorDiv_singleton; - PyObject *FloorDiv_type; - PyObject *For_type; - PyObject *FormattedValue_type; - PyObject *FunctionDef_type; - PyObject *FunctionType_type; - PyObject *GeneratorExp_type; - PyObject *Global_type; - PyObject *GtE_singleton; - PyObject *GtE_type; - PyObject *Gt_singleton; - PyObject *Gt_type; - PyObject *IfExp_type; - PyObject *If_type; - PyObject *ImportFrom_type; - PyObject *Import_type; - PyObject *In_singleton; - PyObject *In_type; - PyObject *Interactive_type; - PyObject *Invert_singleton; - PyObject *Invert_type; - PyObject *IsNot_singleton; - PyObject *IsNot_type; - PyObject *Is_singleton; - PyObject *Is_type; - PyObject *JoinedStr_type; - PyObject *LShift_singleton; - PyObject *LShift_type; - PyObject *Lambda_type; - PyObject *ListComp_type; - PyObject *List_type; - PyObject *Load_singleton; - PyObject *Load_type; - PyObject *LtE_singleton; - PyObject *LtE_type; - PyObject *Lt_singleton; - PyObject *Lt_type; - PyObject *MatMult_singleton; - PyObject *MatMult_type; - PyObject *Mod_singleton; - PyObject *Mod_type; - PyObject *Module_type; - PyObject *Mult_singleton; - PyObject *Mult_type; - PyObject *Name_type; - PyObject *NamedExpr_type; - PyObject *Nonlocal_type; - PyObject *NotEq_singleton; - PyObject *NotEq_type; - PyObject *NotIn_singleton; - PyObject *NotIn_type; - PyObject *Not_singleton; - PyObject *Not_type; - PyObject *Or_singleton; - PyObject *Or_type; - PyObject *Pass_type; - PyObject *Pow_singleton; - PyObject *Pow_type; - PyObject *RShift_singleton; - PyObject *RShift_type; - PyObject *Raise_type; - PyObject *Return_type; - PyObject *SetComp_type; - PyObject *Set_type; - PyObject *Slice_type; - PyObject *Starred_type; - PyObject *Store_singleton; - PyObject *Store_type; - PyObject *Sub_singleton; - PyObject *Sub_type; - PyObject *Subscript_type; - PyObject *Try_type; - PyObject *Tuple_type; - PyObject *TypeIgnore_type; - PyObject *UAdd_singleton; - PyObject *UAdd_type; - PyObject *USub_singleton; - PyObject *USub_type; - PyObject *UnaryOp_type; - PyObject *While_type; - PyObject *With_type; - PyObject *YieldFrom_type; - PyObject *Yield_type; - PyObject *__dict__; - PyObject *__doc__; - PyObject *__module__; - PyObject *_attributes; - PyObject *_fields; - PyObject *alias_type; - PyObject *annotation; - PyObject *arg; - PyObject *arg_type; - PyObject *args; - PyObject *argtypes; - PyObject *arguments_type; - PyObject *asname; - PyObject *ast; - PyObject *attr; - PyObject *bases; - PyObject *body; - PyObject *boolop_type; - PyObject *cause; - PyObject *cmpop_type; - PyObject *col_offset; - PyObject *comparators; - PyObject *comprehension_type; - PyObject *context_expr; - PyObject *conversion; - PyObject *ctx; - PyObject *decorator_list; - PyObject *defaults; - PyObject *elt; - PyObject *elts; - PyObject *end_col_offset; - PyObject *end_lineno; - PyObject *exc; - PyObject *excepthandler_type; - PyObject *expr_context_type; - PyObject *expr_type; - PyObject *finalbody; - PyObject *format_spec; - PyObject *func; - PyObject *generators; - PyObject *handlers; - PyObject *id; - PyObject *ifs; - PyObject *is_async; - PyObject *items; - PyObject *iter; - PyObject *key; - PyObject *keys; - PyObject *keyword_type; - PyObject *keywords; - PyObject *kind; - PyObject *kw_defaults; - PyObject *kwarg; - PyObject *kwonlyargs; - PyObject *left; - PyObject *level; - PyObject *lineno; - PyObject *lower; - PyObject *mod_type; - PyObject *module; - PyObject *msg; - PyObject *name; - PyObject *names; - PyObject *op; - PyObject *operand; - PyObject *operator_type; - PyObject *ops; - PyObject *optional_vars; - PyObject *orelse; - PyObject *posonlyargs; - PyObject *returns; - PyObject *right; - PyObject *simple; - PyObject *slice; - PyObject *step; - PyObject *stmt_type; - PyObject *tag; - PyObject *target; - PyObject *targets; - PyObject *test; - PyObject *type; - PyObject *type_comment; - PyObject *type_ignore_type; - PyObject *type_ignores; - PyObject *unaryop_type; - PyObject *upper; - PyObject *value; - PyObject *values; - PyObject *vararg; - PyObject *withitem_type; -} astmodulestate; - +#include "pycore_ast.h" +#include "pycore_ast_state.h" // struct ast_state +#include "pycore_interp.h" // _PyInterpreterState.ast +#include "pycore_pystate.h" // _PyInterpreterState_GET() +#include "structmember.h" +#include <stddef.h> // Forward declaration -static int init_types(astmodulestate *state); +static int init_types(struct ast_state *state); -// bpo-41194, bpo-41261, bpo-41631: The _ast module uses a global state. -static astmodulestate global_ast_state = {0}; - -static astmodulestate* -get_global_ast_state(void) +static struct ast_state* +get_ast_state(void) { - astmodulestate* state = &global_ast_state; + PyInterpreterState *interp = _PyInterpreterState_GET(); + struct ast_state *state = &interp->ast; if (!init_types(state)) { return NULL; } return state; } -static astmodulestate* -get_ast_state(PyObject* Py_UNUSED(module)) +void _PyAST_Fini(PyInterpreterState *interp) { - astmodulestate* state = get_global_ast_state(); - // get_ast_state() must only be called after _ast module is imported, - // and astmodule_exec() calls init_types() - assert(state != NULL); - return state; -} + struct ast_state *state = &interp->ast; -void _PyAST_Fini() -{ - astmodulestate* state = &global_ast_state; Py_CLEAR(state->AST_type); Py_CLEAR(state->Add_singleton); Py_CLEAR(state->Add_type); @@ -332,6 +105,15 @@ void _PyAST_Fini() Py_CLEAR(state->Lt_type); Py_CLEAR(state->MatMult_singleton); Py_CLEAR(state->MatMult_type); + Py_CLEAR(state->MatchAs_type); + Py_CLEAR(state->MatchClass_type); + Py_CLEAR(state->MatchMapping_type); + Py_CLEAR(state->MatchOr_type); + Py_CLEAR(state->MatchSequence_type); + Py_CLEAR(state->MatchSingleton_type); + Py_CLEAR(state->MatchStar_type); + Py_CLEAR(state->MatchValue_type); + Py_CLEAR(state->Match_type); Py_CLEAR(state->Mod_singleton); Py_CLEAR(state->Mod_type); Py_CLEAR(state->Module_type); @@ -378,6 +160,7 @@ void _PyAST_Fini() Py_CLEAR(state->Yield_type); Py_CLEAR(state->__dict__); Py_CLEAR(state->__doc__); + Py_CLEAR(state->__match_args__); Py_CLEAR(state->__module__); Py_CLEAR(state->_attributes); Py_CLEAR(state->_fields); @@ -394,7 +177,9 @@ void _PyAST_Fini() Py_CLEAR(state->bases); Py_CLEAR(state->body); Py_CLEAR(state->boolop_type); + Py_CLEAR(state->cases); Py_CLEAR(state->cause); + Py_CLEAR(state->cls); Py_CLEAR(state->cmpop_type); Py_CLEAR(state->col_offset); Py_CLEAR(state->comparators); @@ -416,6 +201,7 @@ void _PyAST_Fini() Py_CLEAR(state->format_spec); Py_CLEAR(state->func); Py_CLEAR(state->generators); + Py_CLEAR(state->guard); Py_CLEAR(state->handlers); Py_CLEAR(state->id); Py_CLEAR(state->ifs); @@ -429,11 +215,14 @@ void _PyAST_Fini() Py_CLEAR(state->kind); Py_CLEAR(state->kw_defaults); Py_CLEAR(state->kwarg); + Py_CLEAR(state->kwd_attrs); + Py_CLEAR(state->kwd_patterns); Py_CLEAR(state->kwonlyargs); Py_CLEAR(state->left); Py_CLEAR(state->level); Py_CLEAR(state->lineno); Py_CLEAR(state->lower); + Py_CLEAR(state->match_case_type); Py_CLEAR(state->mod_type); Py_CLEAR(state->module); Py_CLEAR(state->msg); @@ -445,13 +234,18 @@ void _PyAST_Fini() Py_CLEAR(state->ops); Py_CLEAR(state->optional_vars); Py_CLEAR(state->orelse); + Py_CLEAR(state->pattern); + Py_CLEAR(state->pattern_type); + Py_CLEAR(state->patterns); Py_CLEAR(state->posonlyargs); + Py_CLEAR(state->rest); Py_CLEAR(state->returns); Py_CLEAR(state->right); Py_CLEAR(state->simple); Py_CLEAR(state->slice); Py_CLEAR(state->step); Py_CLEAR(state->stmt_type); + Py_CLEAR(state->subject); Py_CLEAR(state->tag); Py_CLEAR(state->target); Py_CLEAR(state->targets); @@ -467,13 +261,18 @@ void _PyAST_Fini() Py_CLEAR(state->vararg); Py_CLEAR(state->withitem_type); +#if !defined(NDEBUG) + state->initialized = -1; +#else state->initialized = 0; +#endif } -static int init_identifiers(astmodulestate *state) +static int init_identifiers(struct ast_state *state) { if ((state->__dict__ = PyUnicode_InternFromString("__dict__")) == NULL) return 0; if ((state->__doc__ = PyUnicode_InternFromString("__doc__")) == NULL) return 0; + if ((state->__match_args__ = PyUnicode_InternFromString("__match_args__")) == NULL) return 0; if ((state->__module__ = PyUnicode_InternFromString("__module__")) == NULL) return 0; if ((state->_attributes = PyUnicode_InternFromString("_attributes")) == NULL) return 0; if ((state->_fields = PyUnicode_InternFromString("_fields")) == NULL) return 0; @@ -486,7 +285,9 @@ static int init_identifiers(astmodulestate *state) if ((state->attr = PyUnicode_InternFromString("attr")) == NULL) return 0; if ((state->bases = PyUnicode_InternFromString("bases")) == NULL) return 0; if ((state->body = PyUnicode_InternFromString("body")) == NULL) return 0; + if ((state->cases = PyUnicode_InternFromString("cases")) == NULL) return 0; if ((state->cause = PyUnicode_InternFromString("cause")) == NULL) return 0; + if ((state->cls = PyUnicode_InternFromString("cls")) == NULL) return 0; if ((state->col_offset = PyUnicode_InternFromString("col_offset")) == NULL) return 0; if ((state->comparators = PyUnicode_InternFromString("comparators")) == NULL) return 0; if ((state->context_expr = PyUnicode_InternFromString("context_expr")) == NULL) return 0; @@ -503,6 +304,7 @@ static int init_identifiers(astmodulestate *state) if ((state->format_spec = PyUnicode_InternFromString("format_spec")) == NULL) return 0; if ((state->func = PyUnicode_InternFromString("func")) == NULL) return 0; if ((state->generators = PyUnicode_InternFromString("generators")) == NULL) return 0; + if ((state->guard = PyUnicode_InternFromString("guard")) == NULL) return 0; if ((state->handlers = PyUnicode_InternFromString("handlers")) == NULL) return 0; if ((state->id = PyUnicode_InternFromString("id")) == NULL) return 0; if ((state->ifs = PyUnicode_InternFromString("ifs")) == NULL) return 0; @@ -515,6 +317,8 @@ static int init_identifiers(astmodulestate *state) if ((state->kind = PyUnicode_InternFromString("kind")) == NULL) return 0; if ((state->kw_defaults = PyUnicode_InternFromString("kw_defaults")) == NULL) return 0; if ((state->kwarg = PyUnicode_InternFromString("kwarg")) == NULL) return 0; + if ((state->kwd_attrs = PyUnicode_InternFromString("kwd_attrs")) == NULL) return 0; + if ((state->kwd_patterns = PyUnicode_InternFromString("kwd_patterns")) == NULL) return 0; if ((state->kwonlyargs = PyUnicode_InternFromString("kwonlyargs")) == NULL) return 0; if ((state->left = PyUnicode_InternFromString("left")) == NULL) return 0; if ((state->level = PyUnicode_InternFromString("level")) == NULL) return 0; @@ -529,12 +333,16 @@ static int init_identifiers(astmodulestate *state) if ((state->ops = PyUnicode_InternFromString("ops")) == NULL) return 0; if ((state->optional_vars = PyUnicode_InternFromString("optional_vars")) == NULL) return 0; if ((state->orelse = PyUnicode_InternFromString("orelse")) == NULL) return 0; + if ((state->pattern = PyUnicode_InternFromString("pattern")) == NULL) return 0; + if ((state->patterns = PyUnicode_InternFromString("patterns")) == NULL) return 0; if ((state->posonlyargs = PyUnicode_InternFromString("posonlyargs")) == NULL) return 0; + if ((state->rest = PyUnicode_InternFromString("rest")) == NULL) return 0; if ((state->returns = PyUnicode_InternFromString("returns")) == NULL) return 0; if ((state->right = PyUnicode_InternFromString("right")) == NULL) return 0; if ((state->simple = PyUnicode_InternFromString("simple")) == NULL) return 0; if ((state->slice = PyUnicode_InternFromString("slice")) == NULL) return 0; if ((state->step = PyUnicode_InternFromString("step")) == NULL) return 0; + if ((state->subject = PyUnicode_InternFromString("subject")) == NULL) return 0; if ((state->tag = PyUnicode_InternFromString("tag")) == NULL) return 0; if ((state->target = PyUnicode_InternFromString("target")) == NULL) return 0; if ((state->targets = PyUnicode_InternFromString("targets")) == NULL) return 0; @@ -549,7 +357,21 @@ static int init_identifiers(astmodulestate *state) return 1; }; -static PyObject* ast2obj_mod(astmodulestate *state, void*); +GENERATE_ASDL_SEQ_CONSTRUCTOR(mod, mod_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(stmt, stmt_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(expr, expr_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(comprehension, comprehension_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(excepthandler, excepthandler_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(arguments, arguments_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(arg, arg_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(keyword, keyword_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(alias, alias_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(withitem, withitem_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(match_case, match_case_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(pattern, pattern_ty) +GENERATE_ASDL_SEQ_CONSTRUCTOR(type_ignore, type_ignore_ty) + +static PyObject* ast2obj_mod(struct ast_state *state, void*); static const char * const Module_fields[]={ "body", "type_ignores", @@ -570,7 +392,7 @@ static const char * const stmt_attributes[] = { "end_lineno", "end_col_offset", }; -static PyObject* ast2obj_stmt(astmodulestate *state, void*); +static PyObject* ast2obj_stmt(struct ast_state *state, void*); static const char * const FunctionDef_fields[]={ "name", "args", @@ -650,6 +472,10 @@ static const char * const AsyncWith_fields[]={ "body", "type_comment", }; +static const char * const Match_fields[]={ + "subject", + "cases", +}; static const char * const Raise_fields[]={ "exc", "cause", @@ -687,7 +513,7 @@ static const char * const expr_attributes[] = { "end_lineno", "end_col_offset", }; -static PyObject* ast2obj_expr(astmodulestate *state, void*); +static PyObject* ast2obj_expr(struct ast_state *state, void*); static const char * const BoolOp_fields[]={ "op", "values", @@ -800,12 +626,12 @@ static const char * const Slice_fields[]={ "upper", "step", }; -static PyObject* ast2obj_expr_context(astmodulestate *state, expr_context_ty); -static PyObject* ast2obj_boolop(astmodulestate *state, boolop_ty); -static PyObject* ast2obj_operator(astmodulestate *state, operator_ty); -static PyObject* ast2obj_unaryop(astmodulestate *state, unaryop_ty); -static PyObject* ast2obj_cmpop(astmodulestate *state, cmpop_ty); -static PyObject* ast2obj_comprehension(astmodulestate *state, void*); +static PyObject* ast2obj_expr_context(struct ast_state *state, expr_context_ty); +static PyObject* ast2obj_boolop(struct ast_state *state, boolop_ty); +static PyObject* ast2obj_operator(struct ast_state *state, operator_ty); +static PyObject* ast2obj_unaryop(struct ast_state *state, unaryop_ty); +static PyObject* ast2obj_cmpop(struct ast_state *state, cmpop_ty); +static PyObject* ast2obj_comprehension(struct ast_state *state, void*); static const char * const comprehension_fields[]={ "target", "iter", @@ -818,13 +644,13 @@ static const char * const excepthandler_attributes[] = { "end_lineno", "end_col_offset", }; -static PyObject* ast2obj_excepthandler(astmodulestate *state, void*); +static PyObject* ast2obj_excepthandler(struct ast_state *state, void*); static const char * const ExceptHandler_fields[]={ "type", "name", "body", }; -static PyObject* ast2obj_arguments(astmodulestate *state, void*); +static PyObject* ast2obj_arguments(struct ast_state *state, void*); static const char * const arguments_fields[]={ "posonlyargs", "args", @@ -834,7 +660,7 @@ static const char * const arguments_fields[]={ "kwarg", "defaults", }; -static PyObject* ast2obj_arg(astmodulestate *state, void*); +static PyObject* ast2obj_arg(struct ast_state *state, void*); static const char * const arg_attributes[] = { "lineno", "col_offset", @@ -846,7 +672,7 @@ static const char * const arg_fields[]={ "annotation", "type_comment", }; -static PyObject* ast2obj_keyword(astmodulestate *state, void*); +static PyObject* ast2obj_keyword(struct ast_state *state, void*); static const char * const keyword_attributes[] = { "lineno", "col_offset", @@ -857,17 +683,66 @@ static const char * const keyword_fields[]={ "arg", "value", }; -static PyObject* ast2obj_alias(astmodulestate *state, void*); +static PyObject* ast2obj_alias(struct ast_state *state, void*); +static const char * const alias_attributes[] = { + "lineno", + "col_offset", + "end_lineno", + "end_col_offset", +}; static const char * const alias_fields[]={ "name", "asname", }; -static PyObject* ast2obj_withitem(astmodulestate *state, void*); +static PyObject* ast2obj_withitem(struct ast_state *state, void*); static const char * const withitem_fields[]={ "context_expr", "optional_vars", }; -static PyObject* ast2obj_type_ignore(astmodulestate *state, void*); +static PyObject* ast2obj_match_case(struct ast_state *state, void*); +static const char * const match_case_fields[]={ + "pattern", + "guard", + "body", +}; +static const char * const pattern_attributes[] = { + "lineno", + "col_offset", + "end_lineno", + "end_col_offset", +}; +static PyObject* ast2obj_pattern(struct ast_state *state, void*); +static const char * const MatchValue_fields[]={ + "value", +}; +static const char * const MatchSingleton_fields[]={ + "value", +}; +static const char * const MatchSequence_fields[]={ + "patterns", +}; +static const char * const MatchMapping_fields[]={ + "keys", + "patterns", + "rest", +}; +static const char * const MatchClass_fields[]={ + "cls", + "patterns", + "kwd_attrs", + "kwd_patterns", +}; +static const char * const MatchStar_fields[]={ + "name", +}; +static const char * const MatchAs_fields[]={ + "pattern", + "name", +}; +static const char * const MatchOr_fields[]={ + "patterns", +}; +static PyObject* ast2obj_type_ignore(struct ast_state *state, void*); static const char * const TypeIgnore_fields[]={ "lineno", "tag", @@ -911,7 +786,7 @@ ast_clear(AST_object *self) static int ast_type_init(PyObject *self, PyObject *args, PyObject *kw) { - astmodulestate *state = get_global_ast_state(); + struct ast_state *state = get_ast_state(); if (state == NULL) { return -1; } @@ -987,7 +862,7 @@ ast_type_init(PyObject *self, PyObject *args, PyObject *kw) static PyObject * ast_type_reduce(PyObject *self, PyObject *unused) { - astmodulestate *state = get_global_ast_state(); + struct ast_state *state = get_ast_state(); if (state == NULL) { return NULL; } @@ -1042,7 +917,7 @@ static PyType_Spec AST_type_spec = { }; static PyObject * -make_type(astmodulestate *state, const char *type, PyObject* base, +make_type(struct ast_state *state, const char *type, PyObject* base, const char* const* fields, int num_fields, const char *doc) { PyObject *fnames, *result; @@ -1057,9 +932,10 @@ make_type(astmodulestate *state, const char *type, PyObject* base, } PyTuple_SET_ITEM(fnames, i, field); } - result = PyObject_CallFunction((PyObject*)&PyType_Type, "s(O){OOOOOs}", + result = PyObject_CallFunction((PyObject*)&PyType_Type, "s(O){OOOOOOOs}", type, base, state->_fields, fnames, + state->__match_args__, fnames, state->__module__, state->ast, state->__doc__, doc); @@ -1068,7 +944,7 @@ make_type(astmodulestate *state, const char *type, PyObject* base, } static int -add_attributes(astmodulestate *state, PyObject *type, const char * const *attrs, int num_fields) +add_attributes(struct ast_state *state, PyObject *type, const char * const *attrs, int num_fields) { int i, result; PyObject *s, *l = PyTuple_New(num_fields); @@ -1089,7 +965,7 @@ add_attributes(astmodulestate *state, PyObject *type, const char * const *attrs, /* Conversion AST -> Python */ -static PyObject* ast2obj_list(astmodulestate *state, asdl_seq *seq, PyObject* (*func)(astmodulestate *state, void*)) +static PyObject* ast2obj_list(struct ast_state *state, asdl_seq *seq, PyObject* (*func)(struct ast_state *state, void*)) { Py_ssize_t i, n = asdl_seq_LEN(seq); PyObject *result = PyList_New(n); @@ -1097,7 +973,7 @@ static PyObject* ast2obj_list(astmodulestate *state, asdl_seq *seq, PyObject* (* if (!result) return NULL; for (i = 0; i < n; i++) { - value = func(state, asdl_seq_GET(seq, i)); + value = func(state, asdl_seq_GET_UNTYPED(seq, i)); if (!value) { Py_DECREF(result); return NULL; @@ -1107,7 +983,7 @@ static PyObject* ast2obj_list(astmodulestate *state, asdl_seq *seq, PyObject* (* return result; } -static PyObject* ast2obj_object(astmodulestate *Py_UNUSED(state), void *o) +static PyObject* ast2obj_object(struct ast_state *Py_UNUSED(state), void *o) { if (!o) o = Py_None; @@ -1118,19 +994,19 @@ static PyObject* ast2obj_object(astmodulestate *Py_UNUSED(state), void *o) #define ast2obj_identifier ast2obj_object #define ast2obj_string ast2obj_object -static PyObject* ast2obj_int(astmodulestate *Py_UNUSED(state), long b) +static PyObject* ast2obj_int(struct ast_state *Py_UNUSED(state), long b) { return PyLong_FromLong(b); } /* Conversion Python -> AST */ -static int obj2ast_object(astmodulestate *Py_UNUSED(state), PyObject* obj, PyObject** out, PyArena* arena) +static int obj2ast_object(struct ast_state *Py_UNUSED(state), PyObject* obj, PyObject** out, PyArena* arena) { if (obj == Py_None) obj = NULL; if (obj) { - if (PyArena_AddPyObject(arena, obj) < 0) { + if (_PyArena_AddPyObject(arena, obj) < 0) { *out = NULL; return -1; } @@ -1140,9 +1016,9 @@ static int obj2ast_object(astmodulestate *Py_UNUSED(state), PyObject* obj, PyObj return 0; } -static int obj2ast_constant(astmodulestate *Py_UNUSED(state), PyObject* obj, PyObject** out, PyArena* arena) +static int obj2ast_constant(struct ast_state *Py_UNUSED(state), PyObject* obj, PyObject** out, PyArena* arena) { - if (PyArena_AddPyObject(arena, obj) < 0) { + if (_PyArena_AddPyObject(arena, obj) < 0) { *out = NULL; return -1; } @@ -1151,7 +1027,7 @@ static int obj2ast_constant(astmodulestate *Py_UNUSED(state), PyObject* obj, PyO return 0; } -static int obj2ast_identifier(astmodulestate *state, PyObject* obj, PyObject** out, PyArena* arena) +static int obj2ast_identifier(struct ast_state *state, PyObject* obj, PyObject** out, PyArena* arena) { if (!PyUnicode_CheckExact(obj) && obj != Py_None) { PyErr_SetString(PyExc_TypeError, "AST identifier must be of type str"); @@ -1160,7 +1036,7 @@ static int obj2ast_identifier(astmodulestate *state, PyObject* obj, PyObject** o return obj2ast_object(state, obj, out, arena); } -static int obj2ast_string(astmodulestate *state, PyObject* obj, PyObject** out, PyArena* arena) +static int obj2ast_string(struct ast_state *state, PyObject* obj, PyObject** out, PyArena* arena) { if (!PyUnicode_CheckExact(obj) && !PyBytes_CheckExact(obj)) { PyErr_SetString(PyExc_TypeError, "AST string must be of type str"); @@ -1169,7 +1045,7 @@ static int obj2ast_string(astmodulestate *state, PyObject* obj, PyObject** out, return obj2ast_object(state, obj, out, arena); } -static int obj2ast_int(astmodulestate* Py_UNUSED(state), PyObject* obj, int* out, PyArena* arena) +static int obj2ast_int(struct ast_state* Py_UNUSED(state), PyObject* obj, int* out, PyArena* arena) { int i; if (!PyLong_Check(obj)) { @@ -1184,12 +1060,13 @@ static int obj2ast_int(astmodulestate* Py_UNUSED(state), PyObject* obj, int* out return 0; } -static int add_ast_fields(astmodulestate *state) +static int add_ast_fields(struct ast_state *state) { PyObject *empty_tuple; empty_tuple = PyTuple_New(0); if (!empty_tuple || PyObject_SetAttrString(state->AST_type, "_fields", empty_tuple) < 0 || + PyObject_SetAttrString(state->AST_type, "__match_args__", empty_tuple) < 0 || PyObject_SetAttrString(state->AST_type, "_attributes", empty_tuple) < 0) { Py_XDECREF(empty_tuple); return -1; @@ -1199,13 +1076,27 @@ static int add_ast_fields(astmodulestate *state) } -static int init_types(astmodulestate *state) + +static int +init_types(struct ast_state *state) { - if (state->initialized) return 1; - if (init_identifiers(state) < 0) return 0; + // init_types() must not be called after _PyAST_Fini() + // has been called + assert(state->initialized >= 0); + + if (state->initialized) { + return 1; + } + if (init_identifiers(state) < 0) { + return 0; + } state->AST_type = PyType_FromSpec(&AST_type_spec); - if (!state->AST_type) return 0; - if (add_ast_fields(state) < 0) return 0; + if (!state->AST_type) { + return 0; + } + if (add_ast_fields(state) < 0) { + return 0; + } state->mod_type = make_type(state, "mod", state->AST_type, NULL, 0, "mod = Module(stmt* body, type_ignore* type_ignores)\n" " | Interactive(stmt* body)\n" @@ -1245,6 +1136,7 @@ static int init_types(astmodulestate *state) " | If(expr test, stmt* body, stmt* orelse)\n" " | With(withitem* items, stmt* body, string? type_comment)\n" " | AsyncWith(withitem* items, stmt* body, string? type_comment)\n" + " | Match(expr subject, match_case* cases)\n" " | Raise(expr? exc, expr? cause)\n" " | Try(stmt* body, excepthandler* handlers, stmt* orelse, stmt* finalbody)\n" " | Assert(expr test, expr? msg)\n" @@ -1347,6 +1239,10 @@ static int init_types(astmodulestate *state) if (PyObject_SetAttr(state->AsyncWith_type, state->type_comment, Py_None) == -1) return 0; + state->Match_type = make_type(state, "Match", state->stmt_type, + Match_fields, 2, + "Match(expr subject, match_case* cases)"); + if (!state->Match_type) return 0; state->Raise_type = make_type(state, "Raise", state->stmt_type, Raise_fields, 2, "Raise(expr? exc, expr? cause)"); @@ -1416,7 +1312,7 @@ static int init_types(astmodulestate *state) " | YieldFrom(expr value)\n" " | Compare(expr left, cmpop* ops, expr* comparators)\n" " | Call(expr func, expr* args, keyword* keywords)\n" - " | FormattedValue(expr value, int? conversion, expr? format_spec)\n" + " | FormattedValue(expr value, int conversion, expr? format_spec)\n" " | JoinedStr(expr* values)\n" " | Constant(constant value, string? kind)\n" " | Attribute(expr value, identifier attr, expr_context ctx)\n" @@ -1506,11 +1402,8 @@ static int init_types(astmodulestate *state) state->FormattedValue_type = make_type(state, "FormattedValue", state->expr_type, FormattedValue_fields, 3, - "FormattedValue(expr value, int? conversion, expr? format_spec)"); + "FormattedValue(expr value, int conversion, expr? format_spec)"); if (!state->FormattedValue_type) return 0; - if (PyObject_SetAttr(state->FormattedValue_type, state->conversion, - Py_None) == -1) - return 0; if (PyObject_SetAttr(state->FormattedValue_type, state->format_spec, Py_None) == -1) return 0; @@ -1853,9 +1746,15 @@ static int init_types(astmodulestate *state) alias_fields, 2, "alias(identifier name, identifier? asname)"); if (!state->alias_type) return 0; - if (!add_attributes(state, state->alias_type, NULL, 0)) return 0; + if (!add_attributes(state, state->alias_type, alias_attributes, 4)) return + 0; if (PyObject_SetAttr(state->alias_type, state->asname, Py_None) == -1) return 0; + if (PyObject_SetAttr(state->alias_type, state->end_lineno, Py_None) == -1) + return 0; + if (PyObject_SetAttr(state->alias_type, state->end_col_offset, Py_None) == + -1) + return 0; state->withitem_type = make_type(state, "withitem", state->AST_type, withitem_fields, 2, "withitem(expr context_expr, expr? optional_vars)"); @@ -1864,6 +1763,70 @@ static int init_types(astmodulestate *state) if (PyObject_SetAttr(state->withitem_type, state->optional_vars, Py_None) == -1) return 0; + state->match_case_type = make_type(state, "match_case", state->AST_type, + match_case_fields, 3, + "match_case(pattern pattern, expr? guard, stmt* body)"); + if (!state->match_case_type) return 0; + if (!add_attributes(state, state->match_case_type, NULL, 0)) return 0; + if (PyObject_SetAttr(state->match_case_type, state->guard, Py_None) == -1) + return 0; + state->pattern_type = make_type(state, "pattern", state->AST_type, NULL, 0, + "pattern = MatchValue(expr value)\n" + " | MatchSingleton(constant value)\n" + " | MatchSequence(pattern* patterns)\n" + " | MatchMapping(expr* keys, pattern* patterns, identifier? rest)\n" + " | MatchClass(expr cls, pattern* patterns, identifier* kwd_attrs, pattern* kwd_patterns)\n" + " | MatchStar(identifier? name)\n" + " | MatchAs(pattern? pattern, identifier? name)\n" + " | MatchOr(pattern* patterns)"); + if (!state->pattern_type) return 0; + if (!add_attributes(state, state->pattern_type, pattern_attributes, 4)) + return 0; + state->MatchValue_type = make_type(state, "MatchValue", + state->pattern_type, MatchValue_fields, + 1, + "MatchValue(expr value)"); + if (!state->MatchValue_type) return 0; + state->MatchSingleton_type = make_type(state, "MatchSingleton", + state->pattern_type, + MatchSingleton_fields, 1, + "MatchSingleton(constant value)"); + if (!state->MatchSingleton_type) return 0; + state->MatchSequence_type = make_type(state, "MatchSequence", + state->pattern_type, + MatchSequence_fields, 1, + "MatchSequence(pattern* patterns)"); + if (!state->MatchSequence_type) return 0; + state->MatchMapping_type = make_type(state, "MatchMapping", + state->pattern_type, + MatchMapping_fields, 3, + "MatchMapping(expr* keys, pattern* patterns, identifier? rest)"); + if (!state->MatchMapping_type) return 0; + if (PyObject_SetAttr(state->MatchMapping_type, state->rest, Py_None) == -1) + return 0; + state->MatchClass_type = make_type(state, "MatchClass", + state->pattern_type, MatchClass_fields, + 4, + "MatchClass(expr cls, pattern* patterns, identifier* kwd_attrs, pattern* kwd_patterns)"); + if (!state->MatchClass_type) return 0; + state->MatchStar_type = make_type(state, "MatchStar", state->pattern_type, + MatchStar_fields, 1, + "MatchStar(identifier? name)"); + if (!state->MatchStar_type) return 0; + if (PyObject_SetAttr(state->MatchStar_type, state->name, Py_None) == -1) + return 0; + state->MatchAs_type = make_type(state, "MatchAs", state->pattern_type, + MatchAs_fields, 2, + "MatchAs(pattern? pattern, identifier? name)"); + if (!state->MatchAs_type) return 0; + if (PyObject_SetAttr(state->MatchAs_type, state->pattern, Py_None) == -1) + return 0; + if (PyObject_SetAttr(state->MatchAs_type, state->name, Py_None) == -1) + return 0; + state->MatchOr_type = make_type(state, "MatchOr", state->pattern_type, + MatchOr_fields, 1, + "MatchOr(pattern* patterns)"); + if (!state->MatchOr_type) return 0; state->type_ignore_type = make_type(state, "type_ignore", state->AST_type, NULL, 0, "type_ignore = TypeIgnore(int lineno, string tag)"); @@ -1874,48 +1837,54 @@ static int init_types(astmodulestate *state) TypeIgnore_fields, 2, "TypeIgnore(int lineno, string tag)"); if (!state->TypeIgnore_type) return 0; + state->initialized = 1; return 1; } -static int obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, +static int obj2ast_mod(struct ast_state *state, PyObject* obj, mod_ty* out, PyArena* arena); -static int obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, +static int obj2ast_stmt(struct ast_state *state, PyObject* obj, stmt_ty* out, PyArena* arena); -static int obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, +static int obj2ast_expr(struct ast_state *state, PyObject* obj, expr_ty* out, PyArena* arena); -static int obj2ast_expr_context(astmodulestate *state, PyObject* obj, +static int obj2ast_expr_context(struct ast_state *state, PyObject* obj, expr_context_ty* out, PyArena* arena); -static int obj2ast_boolop(astmodulestate *state, PyObject* obj, boolop_ty* out, - PyArena* arena); -static int obj2ast_operator(astmodulestate *state, PyObject* obj, operator_ty* - out, PyArena* arena); -static int obj2ast_unaryop(astmodulestate *state, PyObject* obj, unaryop_ty* +static int obj2ast_boolop(struct ast_state *state, PyObject* obj, boolop_ty* + out, PyArena* arena); +static int obj2ast_operator(struct ast_state *state, PyObject* obj, + operator_ty* out, PyArena* arena); +static int obj2ast_unaryop(struct ast_state *state, PyObject* obj, unaryop_ty* out, PyArena* arena); -static int obj2ast_cmpop(astmodulestate *state, PyObject* obj, cmpop_ty* out, +static int obj2ast_cmpop(struct ast_state *state, PyObject* obj, cmpop_ty* out, PyArena* arena); -static int obj2ast_comprehension(astmodulestate *state, PyObject* obj, +static int obj2ast_comprehension(struct ast_state *state, PyObject* obj, comprehension_ty* out, PyArena* arena); -static int obj2ast_excepthandler(astmodulestate *state, PyObject* obj, +static int obj2ast_excepthandler(struct ast_state *state, PyObject* obj, excepthandler_ty* out, PyArena* arena); -static int obj2ast_arguments(astmodulestate *state, PyObject* obj, +static int obj2ast_arguments(struct ast_state *state, PyObject* obj, arguments_ty* out, PyArena* arena); -static int obj2ast_arg(astmodulestate *state, PyObject* obj, arg_ty* out, +static int obj2ast_arg(struct ast_state *state, PyObject* obj, arg_ty* out, PyArena* arena); -static int obj2ast_keyword(astmodulestate *state, PyObject* obj, keyword_ty* +static int obj2ast_keyword(struct ast_state *state, PyObject* obj, keyword_ty* out, PyArena* arena); -static int obj2ast_alias(astmodulestate *state, PyObject* obj, alias_ty* out, +static int obj2ast_alias(struct ast_state *state, PyObject* obj, alias_ty* out, PyArena* arena); -static int obj2ast_withitem(astmodulestate *state, PyObject* obj, withitem_ty* - out, PyArena* arena); -static int obj2ast_type_ignore(astmodulestate *state, PyObject* obj, +static int obj2ast_withitem(struct ast_state *state, PyObject* obj, + withitem_ty* out, PyArena* arena); +static int obj2ast_match_case(struct ast_state *state, PyObject* obj, + match_case_ty* out, PyArena* arena); +static int obj2ast_pattern(struct ast_state *state, PyObject* obj, pattern_ty* + out, PyArena* arena); +static int obj2ast_type_ignore(struct ast_state *state, PyObject* obj, type_ignore_ty* out, PyArena* arena); mod_ty -Module(asdl_seq * body, asdl_seq * type_ignores, PyArena *arena) +_PyAST_Module(asdl_stmt_seq * body, asdl_type_ignore_seq * type_ignores, + PyArena *arena) { mod_ty p; - p = (mod_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (mod_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Module_kind; @@ -1925,10 +1894,10 @@ Module(asdl_seq * body, asdl_seq * type_ignores, PyArena *arena) } mod_ty -Interactive(asdl_seq * body, PyArena *arena) +_PyAST_Interactive(asdl_stmt_seq * body, PyArena *arena) { mod_ty p; - p = (mod_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (mod_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Interactive_kind; @@ -1937,7 +1906,7 @@ Interactive(asdl_seq * body, PyArena *arena) } mod_ty -Expression(expr_ty body, PyArena *arena) +_PyAST_Expression(expr_ty body, PyArena *arena) { mod_ty p; if (!body) { @@ -1945,7 +1914,7 @@ Expression(expr_ty body, PyArena *arena) "field 'body' is required for Expression"); return NULL; } - p = (mod_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (mod_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Expression_kind; @@ -1954,7 +1923,7 @@ Expression(expr_ty body, PyArena *arena) } mod_ty -FunctionType(asdl_seq * argtypes, expr_ty returns, PyArena *arena) +_PyAST_FunctionType(asdl_expr_seq * argtypes, expr_ty returns, PyArena *arena) { mod_ty p; if (!returns) { @@ -1962,7 +1931,7 @@ FunctionType(asdl_seq * argtypes, expr_ty returns, PyArena *arena) "field 'returns' is required for FunctionType"); return NULL; } - p = (mod_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (mod_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = FunctionType_kind; @@ -1972,9 +1941,10 @@ FunctionType(asdl_seq * argtypes, expr_ty returns, PyArena *arena) } stmt_ty -FunctionDef(identifier name, arguments_ty args, asdl_seq * body, asdl_seq * - decorator_list, expr_ty returns, string type_comment, int lineno, - int col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_FunctionDef(identifier name, arguments_ty args, asdl_stmt_seq * body, + asdl_expr_seq * decorator_list, expr_ty returns, string + type_comment, int lineno, int col_offset, int end_lineno, + int end_col_offset, PyArena *arena) { stmt_ty p; if (!name) { @@ -1987,7 +1957,7 @@ FunctionDef(identifier name, arguments_ty args, asdl_seq * body, asdl_seq * "field 'args' is required for FunctionDef"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = FunctionDef_kind; @@ -2005,10 +1975,10 @@ FunctionDef(identifier name, arguments_ty args, asdl_seq * body, asdl_seq * } stmt_ty -AsyncFunctionDef(identifier name, arguments_ty args, asdl_seq * body, asdl_seq - * decorator_list, expr_ty returns, string type_comment, int - lineno, int col_offset, int end_lineno, int end_col_offset, - PyArena *arena) +_PyAST_AsyncFunctionDef(identifier name, arguments_ty args, asdl_stmt_seq * + body, asdl_expr_seq * decorator_list, expr_ty returns, + string type_comment, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; if (!name) { @@ -2021,7 +1991,7 @@ AsyncFunctionDef(identifier name, arguments_ty args, asdl_seq * body, asdl_seq "field 'args' is required for AsyncFunctionDef"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = AsyncFunctionDef_kind; @@ -2039,9 +2009,10 @@ AsyncFunctionDef(identifier name, arguments_ty args, asdl_seq * body, asdl_seq } stmt_ty -ClassDef(identifier name, asdl_seq * bases, asdl_seq * keywords, asdl_seq * - body, asdl_seq * decorator_list, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_ClassDef(identifier name, asdl_expr_seq * bases, asdl_keyword_seq * + keywords, asdl_stmt_seq * body, asdl_expr_seq * decorator_list, + int lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { stmt_ty p; if (!name) { @@ -2049,7 +2020,7 @@ ClassDef(identifier name, asdl_seq * bases, asdl_seq * keywords, asdl_seq * "field 'name' is required for ClassDef"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = ClassDef_kind; @@ -2066,11 +2037,11 @@ ClassDef(identifier name, asdl_seq * bases, asdl_seq * keywords, asdl_seq * } stmt_ty -Return(expr_ty value, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_Return(expr_ty value, int lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Return_kind; @@ -2083,11 +2054,11 @@ Return(expr_ty value, int lineno, int col_offset, int end_lineno, int } stmt_ty -Delete(asdl_seq * targets, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_Delete(asdl_expr_seq * targets, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Delete_kind; @@ -2100,8 +2071,9 @@ Delete(asdl_seq * targets, int lineno, int col_offset, int end_lineno, int } stmt_ty -Assign(asdl_seq * targets, expr_ty value, string type_comment, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Assign(asdl_expr_seq * targets, expr_ty value, string type_comment, int + lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { stmt_ty p; if (!value) { @@ -2109,7 +2081,7 @@ Assign(asdl_seq * targets, expr_ty value, string type_comment, int lineno, int "field 'value' is required for Assign"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Assign_kind; @@ -2124,8 +2096,8 @@ Assign(asdl_seq * targets, expr_ty value, string type_comment, int lineno, int } stmt_ty -AugAssign(expr_ty target, operator_ty op, expr_ty value, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_AugAssign(expr_ty target, operator_ty op, expr_ty value, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; if (!target) { @@ -2143,7 +2115,7 @@ AugAssign(expr_ty target, operator_ty op, expr_ty value, int lineno, int "field 'value' is required for AugAssign"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = AugAssign_kind; @@ -2158,9 +2130,9 @@ AugAssign(expr_ty target, operator_ty op, expr_ty value, int lineno, int } stmt_ty -AnnAssign(expr_ty target, expr_ty annotation, expr_ty value, int simple, int - lineno, int col_offset, int end_lineno, int end_col_offset, PyArena - *arena) +_PyAST_AnnAssign(expr_ty target, expr_ty annotation, expr_ty value, int simple, + int lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { stmt_ty p; if (!target) { @@ -2173,7 +2145,7 @@ AnnAssign(expr_ty target, expr_ty annotation, expr_ty value, int simple, int "field 'annotation' is required for AnnAssign"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = AnnAssign_kind; @@ -2189,9 +2161,9 @@ AnnAssign(expr_ty target, expr_ty annotation, expr_ty value, int simple, int } stmt_ty -For(expr_ty target, expr_ty iter, asdl_seq * body, asdl_seq * orelse, string - type_comment, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_For(expr_ty target, expr_ty iter, asdl_stmt_seq * body, asdl_stmt_seq * + orelse, string type_comment, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; if (!target) { @@ -2204,7 +2176,7 @@ For(expr_ty target, expr_ty iter, asdl_seq * body, asdl_seq * orelse, string "field 'iter' is required for For"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = For_kind; @@ -2221,9 +2193,9 @@ For(expr_ty target, expr_ty iter, asdl_seq * body, asdl_seq * orelse, string } stmt_ty -AsyncFor(expr_ty target, expr_ty iter, asdl_seq * body, asdl_seq * orelse, - string type_comment, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_AsyncFor(expr_ty target, expr_ty iter, asdl_stmt_seq * body, + asdl_stmt_seq * orelse, string type_comment, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; if (!target) { @@ -2236,7 +2208,7 @@ AsyncFor(expr_ty target, expr_ty iter, asdl_seq * body, asdl_seq * orelse, "field 'iter' is required for AsyncFor"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = AsyncFor_kind; @@ -2253,8 +2225,9 @@ AsyncFor(expr_ty target, expr_ty iter, asdl_seq * body, asdl_seq * orelse, } stmt_ty -While(expr_ty test, asdl_seq * body, asdl_seq * orelse, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_While(expr_ty test, asdl_stmt_seq * body, asdl_stmt_seq * orelse, int + lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { stmt_ty p; if (!test) { @@ -2262,7 +2235,7 @@ While(expr_ty test, asdl_seq * body, asdl_seq * orelse, int lineno, int "field 'test' is required for While"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = While_kind; @@ -2277,8 +2250,9 @@ While(expr_ty test, asdl_seq * body, asdl_seq * orelse, int lineno, int } stmt_ty -If(expr_ty test, asdl_seq * body, asdl_seq * orelse, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_If(expr_ty test, asdl_stmt_seq * body, asdl_stmt_seq * orelse, int + lineno, int col_offset, int end_lineno, int end_col_offset, PyArena + *arena) { stmt_ty p; if (!test) { @@ -2286,7 +2260,7 @@ If(expr_ty test, asdl_seq * body, asdl_seq * orelse, int lineno, int "field 'test' is required for If"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = If_kind; @@ -2301,11 +2275,12 @@ If(expr_ty test, asdl_seq * body, asdl_seq * orelse, int lineno, int } stmt_ty -With(asdl_seq * items, asdl_seq * body, string type_comment, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_With(asdl_withitem_seq * items, asdl_stmt_seq * body, string + type_comment, int lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = With_kind; @@ -2320,11 +2295,12 @@ With(asdl_seq * items, asdl_seq * body, string type_comment, int lineno, int } stmt_ty -AsyncWith(asdl_seq * items, asdl_seq * body, string type_comment, int lineno, - int col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_AsyncWith(asdl_withitem_seq * items, asdl_stmt_seq * body, string + type_comment, int lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = AsyncWith_kind; @@ -2339,11 +2315,34 @@ AsyncWith(asdl_seq * items, asdl_seq * body, string type_comment, int lineno, } stmt_ty -Raise(expr_ty exc, expr_ty cause, int lineno, int col_offset, int end_lineno, - int end_col_offset, PyArena *arena) +_PyAST_Match(expr_ty subject, asdl_match_case_seq * cases, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) +{ + stmt_ty p; + if (!subject) { + PyErr_SetString(PyExc_ValueError, + "field 'subject' is required for Match"); + return NULL; + } + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->kind = Match_kind; + p->v.Match.subject = subject; + p->v.Match.cases = cases; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; + return p; +} + +stmt_ty +_PyAST_Raise(expr_ty exc, expr_ty cause, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Raise_kind; @@ -2357,12 +2356,12 @@ Raise(expr_ty exc, expr_ty cause, int lineno, int col_offset, int end_lineno, } stmt_ty -Try(asdl_seq * body, asdl_seq * handlers, asdl_seq * orelse, asdl_seq * - finalbody, int lineno, int col_offset, int end_lineno, int end_col_offset, - PyArena *arena) +_PyAST_Try(asdl_stmt_seq * body, asdl_excepthandler_seq * handlers, + asdl_stmt_seq * orelse, asdl_stmt_seq * finalbody, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Try_kind; @@ -2378,8 +2377,8 @@ Try(asdl_seq * body, asdl_seq * handlers, asdl_seq * orelse, asdl_seq * } stmt_ty -Assert(expr_ty test, expr_ty msg, int lineno, int col_offset, int end_lineno, - int end_col_offset, PyArena *arena) +_PyAST_Assert(expr_ty test, expr_ty msg, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; if (!test) { @@ -2387,7 +2386,7 @@ Assert(expr_ty test, expr_ty msg, int lineno, int col_offset, int end_lineno, "field 'test' is required for Assert"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Assert_kind; @@ -2401,11 +2400,11 @@ Assert(expr_ty test, expr_ty msg, int lineno, int col_offset, int end_lineno, } stmt_ty -Import(asdl_seq * names, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_Import(asdl_alias_seq * names, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Import_kind; @@ -2418,11 +2417,12 @@ Import(asdl_seq * names, int lineno, int col_offset, int end_lineno, int } stmt_ty -ImportFrom(identifier module, asdl_seq * names, int level, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_ImportFrom(identifier module, asdl_alias_seq * names, int level, int + lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = ImportFrom_kind; @@ -2437,11 +2437,11 @@ ImportFrom(identifier module, asdl_seq * names, int level, int lineno, int } stmt_ty -Global(asdl_seq * names, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_Global(asdl_identifier_seq * names, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Global_kind; @@ -2454,11 +2454,11 @@ Global(asdl_seq * names, int lineno, int col_offset, int end_lineno, int } stmt_ty -Nonlocal(asdl_seq * names, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_Nonlocal(asdl_identifier_seq * names, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Nonlocal_kind; @@ -2471,8 +2471,8 @@ Nonlocal(asdl_seq * names, int lineno, int col_offset, int end_lineno, int } stmt_ty -Expr(expr_ty value, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_Expr(expr_ty value, int lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { stmt_ty p; if (!value) { @@ -2480,7 +2480,7 @@ Expr(expr_ty value, int lineno, int col_offset, int end_lineno, int "field 'value' is required for Expr"); return NULL; } - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Expr_kind; @@ -2493,11 +2493,11 @@ Expr(expr_ty value, int lineno, int col_offset, int end_lineno, int } stmt_ty -Pass(int lineno, int col_offset, int end_lineno, int end_col_offset, PyArena - *arena) +_PyAST_Pass(int lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Pass_kind; @@ -2509,11 +2509,11 @@ Pass(int lineno, int col_offset, int end_lineno, int end_col_offset, PyArena } stmt_ty -Break(int lineno, int col_offset, int end_lineno, int end_col_offset, PyArena - *arena) +_PyAST_Break(int lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Break_kind; @@ -2525,11 +2525,11 @@ Break(int lineno, int col_offset, int end_lineno, int end_col_offset, PyArena } stmt_ty -Continue(int lineno, int col_offset, int end_lineno, int end_col_offset, - PyArena *arena) +_PyAST_Continue(int lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { stmt_ty p; - p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (stmt_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Continue_kind; @@ -2541,8 +2541,8 @@ Continue(int lineno, int col_offset, int end_lineno, int end_col_offset, } expr_ty -BoolOp(boolop_ty op, asdl_seq * values, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_BoolOp(boolop_ty op, asdl_expr_seq * values, int lineno, int col_offset, + int end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!op) { @@ -2550,7 +2550,7 @@ BoolOp(boolop_ty op, asdl_seq * values, int lineno, int col_offset, int "field 'op' is required for BoolOp"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = BoolOp_kind; @@ -2564,8 +2564,8 @@ BoolOp(boolop_ty op, asdl_seq * values, int lineno, int col_offset, int } expr_ty -NamedExpr(expr_ty target, expr_ty value, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_NamedExpr(expr_ty target, expr_ty value, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!target) { @@ -2578,7 +2578,7 @@ NamedExpr(expr_ty target, expr_ty value, int lineno, int col_offset, int "field 'value' is required for NamedExpr"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = NamedExpr_kind; @@ -2592,8 +2592,8 @@ NamedExpr(expr_ty target, expr_ty value, int lineno, int col_offset, int } expr_ty -BinOp(expr_ty left, operator_ty op, expr_ty right, int lineno, int col_offset, - int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_BinOp(expr_ty left, operator_ty op, expr_ty right, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!left) { @@ -2611,7 +2611,7 @@ BinOp(expr_ty left, operator_ty op, expr_ty right, int lineno, int col_offset, "field 'right' is required for BinOp"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = BinOp_kind; @@ -2626,8 +2626,8 @@ BinOp(expr_ty left, operator_ty op, expr_ty right, int lineno, int col_offset, } expr_ty -UnaryOp(unaryop_ty op, expr_ty operand, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_UnaryOp(unaryop_ty op, expr_ty operand, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!op) { @@ -2640,7 +2640,7 @@ UnaryOp(unaryop_ty op, expr_ty operand, int lineno, int col_offset, int "field 'operand' is required for UnaryOp"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = UnaryOp_kind; @@ -2654,8 +2654,8 @@ UnaryOp(unaryop_ty op, expr_ty operand, int lineno, int col_offset, int } expr_ty -Lambda(arguments_ty args, expr_ty body, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Lambda(arguments_ty args, expr_ty body, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!args) { @@ -2668,7 +2668,7 @@ Lambda(arguments_ty args, expr_ty body, int lineno, int col_offset, int "field 'body' is required for Lambda"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Lambda_kind; @@ -2682,8 +2682,8 @@ Lambda(arguments_ty args, expr_ty body, int lineno, int col_offset, int } expr_ty -IfExp(expr_ty test, expr_ty body, expr_ty orelse, int lineno, int col_offset, - int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_IfExp(expr_ty test, expr_ty body, expr_ty orelse, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!test) { @@ -2701,7 +2701,7 @@ IfExp(expr_ty test, expr_ty body, expr_ty orelse, int lineno, int col_offset, "field 'orelse' is required for IfExp"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = IfExp_kind; @@ -2716,11 +2716,11 @@ IfExp(expr_ty test, expr_ty body, expr_ty orelse, int lineno, int col_offset, } expr_ty -Dict(asdl_seq * keys, asdl_seq * values, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Dict(asdl_expr_seq * keys, asdl_expr_seq * values, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Dict_kind; @@ -2734,11 +2734,11 @@ Dict(asdl_seq * keys, asdl_seq * values, int lineno, int col_offset, int } expr_ty -Set(asdl_seq * elts, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_Set(asdl_expr_seq * elts, int lineno, int col_offset, int end_lineno, + int end_col_offset, PyArena *arena) { expr_ty p; - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Set_kind; @@ -2751,8 +2751,9 @@ Set(asdl_seq * elts, int lineno, int col_offset, int end_lineno, int } expr_ty -ListComp(expr_ty elt, asdl_seq * generators, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_ListComp(expr_ty elt, asdl_comprehension_seq * generators, int lineno, + int col_offset, int end_lineno, int end_col_offset, PyArena + *arena) { expr_ty p; if (!elt) { @@ -2760,7 +2761,7 @@ ListComp(expr_ty elt, asdl_seq * generators, int lineno, int col_offset, int "field 'elt' is required for ListComp"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = ListComp_kind; @@ -2774,8 +2775,9 @@ ListComp(expr_ty elt, asdl_seq * generators, int lineno, int col_offset, int } expr_ty -SetComp(expr_ty elt, asdl_seq * generators, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_SetComp(expr_ty elt, asdl_comprehension_seq * generators, int lineno, + int col_offset, int end_lineno, int end_col_offset, PyArena + *arena) { expr_ty p; if (!elt) { @@ -2783,7 +2785,7 @@ SetComp(expr_ty elt, asdl_seq * generators, int lineno, int col_offset, int "field 'elt' is required for SetComp"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = SetComp_kind; @@ -2797,8 +2799,9 @@ SetComp(expr_ty elt, asdl_seq * generators, int lineno, int col_offset, int } expr_ty -DictComp(expr_ty key, expr_ty value, asdl_seq * generators, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_DictComp(expr_ty key, expr_ty value, asdl_comprehension_seq * + generators, int lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { expr_ty p; if (!key) { @@ -2811,7 +2814,7 @@ DictComp(expr_ty key, expr_ty value, asdl_seq * generators, int lineno, int "field 'value' is required for DictComp"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = DictComp_kind; @@ -2826,8 +2829,9 @@ DictComp(expr_ty key, expr_ty value, asdl_seq * generators, int lineno, int } expr_ty -GeneratorExp(expr_ty elt, asdl_seq * generators, int lineno, int col_offset, - int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_GeneratorExp(expr_ty elt, asdl_comprehension_seq * generators, int + lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { expr_ty p; if (!elt) { @@ -2835,7 +2839,7 @@ GeneratorExp(expr_ty elt, asdl_seq * generators, int lineno, int col_offset, "field 'elt' is required for GeneratorExp"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = GeneratorExp_kind; @@ -2849,8 +2853,8 @@ GeneratorExp(expr_ty elt, asdl_seq * generators, int lineno, int col_offset, } expr_ty -Await(expr_ty value, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_Await(expr_ty value, int lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { expr_ty p; if (!value) { @@ -2858,7 +2862,7 @@ Await(expr_ty value, int lineno, int col_offset, int end_lineno, int "field 'value' is required for Await"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Await_kind; @@ -2871,11 +2875,11 @@ Await(expr_ty value, int lineno, int col_offset, int end_lineno, int } expr_ty -Yield(expr_ty value, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_Yield(expr_ty value, int lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { expr_ty p; - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Yield_kind; @@ -2888,8 +2892,8 @@ Yield(expr_ty value, int lineno, int col_offset, int end_lineno, int } expr_ty -YieldFrom(expr_ty value, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_YieldFrom(expr_ty value, int lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { expr_ty p; if (!value) { @@ -2897,7 +2901,7 @@ YieldFrom(expr_ty value, int lineno, int col_offset, int end_lineno, int "field 'value' is required for YieldFrom"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = YieldFrom_kind; @@ -2910,8 +2914,9 @@ YieldFrom(expr_ty value, int lineno, int col_offset, int end_lineno, int } expr_ty -Compare(expr_ty left, asdl_int_seq * ops, asdl_seq * comparators, int lineno, - int col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Compare(expr_ty left, asdl_int_seq * ops, asdl_expr_seq * comparators, + int lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { expr_ty p; if (!left) { @@ -2919,7 +2924,7 @@ Compare(expr_ty left, asdl_int_seq * ops, asdl_seq * comparators, int lineno, "field 'left' is required for Compare"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Compare_kind; @@ -2934,8 +2939,9 @@ Compare(expr_ty left, asdl_int_seq * ops, asdl_seq * comparators, int lineno, } expr_ty -Call(expr_ty func, asdl_seq * args, asdl_seq * keywords, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Call(expr_ty func, asdl_expr_seq * args, asdl_keyword_seq * keywords, + int lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { expr_ty p; if (!func) { @@ -2943,7 +2949,7 @@ Call(expr_ty func, asdl_seq * args, asdl_seq * keywords, int lineno, int "field 'func' is required for Call"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Call_kind; @@ -2958,9 +2964,9 @@ Call(expr_ty func, asdl_seq * args, asdl_seq * keywords, int lineno, int } expr_ty -FormattedValue(expr_ty value, int conversion, expr_ty format_spec, int lineno, - int col_offset, int end_lineno, int end_col_offset, PyArena - *arena) +_PyAST_FormattedValue(expr_ty value, int conversion, expr_ty format_spec, int + lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { expr_ty p; if (!value) { @@ -2968,7 +2974,7 @@ FormattedValue(expr_ty value, int conversion, expr_ty format_spec, int lineno, "field 'value' is required for FormattedValue"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = FormattedValue_kind; @@ -2983,11 +2989,11 @@ FormattedValue(expr_ty value, int conversion, expr_ty format_spec, int lineno, } expr_ty -JoinedStr(asdl_seq * values, int lineno, int col_offset, int end_lineno, int - end_col_offset, PyArena *arena) +_PyAST_JoinedStr(asdl_expr_seq * values, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = JoinedStr_kind; @@ -3000,8 +3006,8 @@ JoinedStr(asdl_seq * values, int lineno, int col_offset, int end_lineno, int } expr_ty -Constant(constant value, string kind, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Constant(constant value, string kind, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!value) { @@ -3009,7 +3015,7 @@ Constant(constant value, string kind, int lineno, int col_offset, int "field 'value' is required for Constant"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Constant_kind; @@ -3023,8 +3029,9 @@ Constant(constant value, string kind, int lineno, int col_offset, int } expr_ty -Attribute(expr_ty value, identifier attr, expr_context_ty ctx, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Attribute(expr_ty value, identifier attr, expr_context_ty ctx, int + lineno, int col_offset, int end_lineno, int end_col_offset, + PyArena *arena) { expr_ty p; if (!value) { @@ -3042,7 +3049,7 @@ Attribute(expr_ty value, identifier attr, expr_context_ty ctx, int lineno, int "field 'ctx' is required for Attribute"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Attribute_kind; @@ -3057,8 +3064,9 @@ Attribute(expr_ty value, identifier attr, expr_context_ty ctx, int lineno, int } expr_ty -Subscript(expr_ty value, expr_ty slice, expr_context_ty ctx, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Subscript(expr_ty value, expr_ty slice, expr_context_ty ctx, int lineno, + int col_offset, int end_lineno, int end_col_offset, PyArena + *arena) { expr_ty p; if (!value) { @@ -3076,7 +3084,7 @@ Subscript(expr_ty value, expr_ty slice, expr_context_ty ctx, int lineno, int "field 'ctx' is required for Subscript"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Subscript_kind; @@ -3091,8 +3099,8 @@ Subscript(expr_ty value, expr_ty slice, expr_context_ty ctx, int lineno, int } expr_ty -Starred(expr_ty value, expr_context_ty ctx, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Starred(expr_ty value, expr_context_ty ctx, int lineno, int col_offset, + int end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!value) { @@ -3105,7 +3113,7 @@ Starred(expr_ty value, expr_context_ty ctx, int lineno, int col_offset, int "field 'ctx' is required for Starred"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Starred_kind; @@ -3119,8 +3127,8 @@ Starred(expr_ty value, expr_context_ty ctx, int lineno, int col_offset, int } expr_ty -Name(identifier id, expr_context_ty ctx, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Name(identifier id, expr_context_ty ctx, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!id) { @@ -3133,7 +3141,7 @@ Name(identifier id, expr_context_ty ctx, int lineno, int col_offset, int "field 'ctx' is required for Name"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Name_kind; @@ -3147,8 +3155,8 @@ Name(identifier id, expr_context_ty ctx, int lineno, int col_offset, int } expr_ty -List(asdl_seq * elts, expr_context_ty ctx, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_List(asdl_expr_seq * elts, expr_context_ty ctx, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!ctx) { @@ -3156,7 +3164,7 @@ List(asdl_seq * elts, expr_context_ty ctx, int lineno, int col_offset, int "field 'ctx' is required for List"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = List_kind; @@ -3170,8 +3178,8 @@ List(asdl_seq * elts, expr_context_ty ctx, int lineno, int col_offset, int } expr_ty -Tuple(asdl_seq * elts, expr_context_ty ctx, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Tuple(asdl_expr_seq * elts, expr_context_ty ctx, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; if (!ctx) { @@ -3179,7 +3187,7 @@ Tuple(asdl_seq * elts, expr_context_ty ctx, int lineno, int col_offset, int "field 'ctx' is required for Tuple"); return NULL; } - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Tuple_kind; @@ -3193,11 +3201,11 @@ Tuple(asdl_seq * elts, expr_context_ty ctx, int lineno, int col_offset, int } expr_ty -Slice(expr_ty lower, expr_ty upper, expr_ty step, int lineno, int col_offset, - int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_Slice(expr_ty lower, expr_ty upper, expr_ty step, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena *arena) { expr_ty p; - p = (expr_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (expr_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Slice_kind; @@ -3212,8 +3220,8 @@ Slice(expr_ty lower, expr_ty upper, expr_ty step, int lineno, int col_offset, } comprehension_ty -comprehension(expr_ty target, expr_ty iter, asdl_seq * ifs, int is_async, - PyArena *arena) +_PyAST_comprehension(expr_ty target, expr_ty iter, asdl_expr_seq * ifs, int + is_async, PyArena *arena) { comprehension_ty p; if (!target) { @@ -3226,7 +3234,7 @@ comprehension(expr_ty target, expr_ty iter, asdl_seq * ifs, int is_async, "field 'iter' is required for comprehension"); return NULL; } - p = (comprehension_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (comprehension_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->target = target; @@ -3237,11 +3245,12 @@ comprehension(expr_ty target, expr_ty iter, asdl_seq * ifs, int is_async, } excepthandler_ty -ExceptHandler(expr_ty type, identifier name, asdl_seq * body, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_ExceptHandler(expr_ty type, identifier name, asdl_stmt_seq * body, int + lineno, int col_offset, int end_lineno, int + end_col_offset, PyArena *arena) { excepthandler_ty p; - p = (excepthandler_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (excepthandler_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = ExceptHandler_kind; @@ -3256,12 +3265,13 @@ ExceptHandler(expr_ty type, identifier name, asdl_seq * body, int lineno, int } arguments_ty -arguments(asdl_seq * posonlyargs, asdl_seq * args, arg_ty vararg, asdl_seq * - kwonlyargs, asdl_seq * kw_defaults, arg_ty kwarg, asdl_seq * - defaults, PyArena *arena) +_PyAST_arguments(asdl_arg_seq * posonlyargs, asdl_arg_seq * args, arg_ty + vararg, asdl_arg_seq * kwonlyargs, asdl_expr_seq * + kw_defaults, arg_ty kwarg, asdl_expr_seq * defaults, PyArena + *arena) { arguments_ty p; - p = (arguments_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (arguments_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->posonlyargs = posonlyargs; @@ -3275,8 +3285,8 @@ arguments(asdl_seq * posonlyargs, asdl_seq * args, arg_ty vararg, asdl_seq * } arg_ty -arg(identifier arg, expr_ty annotation, string type_comment, int lineno, int - col_offset, int end_lineno, int end_col_offset, PyArena *arena) +_PyAST_arg(identifier arg, expr_ty annotation, string type_comment, int lineno, + int col_offset, int end_lineno, int end_col_offset, PyArena *arena) { arg_ty p; if (!arg) { @@ -3284,7 +3294,7 @@ arg(identifier arg, expr_ty annotation, string type_comment, int lineno, int "field 'arg' is required for arg"); return NULL; } - p = (arg_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (arg_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->arg = arg; @@ -3298,8 +3308,8 @@ arg(identifier arg, expr_ty annotation, string type_comment, int lineno, int } keyword_ty -keyword(identifier arg, expr_ty value, int lineno, int col_offset, int - end_lineno, int end_col_offset, PyArena *arena) +_PyAST_keyword(identifier arg, expr_ty value, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) { keyword_ty p; if (!value) { @@ -3307,7 +3317,7 @@ keyword(identifier arg, expr_ty value, int lineno, int col_offset, int "field 'value' is required for keyword"); return NULL; } - p = (keyword_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (keyword_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->arg = arg; @@ -3320,7 +3330,8 @@ keyword(identifier arg, expr_ty value, int lineno, int col_offset, int } alias_ty -alias(identifier name, identifier asname, PyArena *arena) +_PyAST_alias(identifier name, identifier asname, int lineno, int col_offset, + int end_lineno, int end_col_offset, PyArena *arena) { alias_ty p; if (!name) { @@ -3328,16 +3339,20 @@ alias(identifier name, identifier asname, PyArena *arena) "field 'name' is required for alias"); return NULL; } - p = (alias_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (alias_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->name = name; p->asname = asname; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; return p; } withitem_ty -withitem(expr_ty context_expr, expr_ty optional_vars, PyArena *arena) +_PyAST_withitem(expr_ty context_expr, expr_ty optional_vars, PyArena *arena) { withitem_ty p; if (!context_expr) { @@ -3345,7 +3360,7 @@ withitem(expr_ty context_expr, expr_ty optional_vars, PyArena *arena) "field 'context_expr' is required for withitem"); return NULL; } - p = (withitem_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (withitem_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->context_expr = context_expr; @@ -3353,8 +3368,187 @@ withitem(expr_ty context_expr, expr_ty optional_vars, PyArena *arena) return p; } +match_case_ty +_PyAST_match_case(pattern_ty pattern, expr_ty guard, asdl_stmt_seq * body, + PyArena *arena) +{ + match_case_ty p; + if (!pattern) { + PyErr_SetString(PyExc_ValueError, + "field 'pattern' is required for match_case"); + return NULL; + } + p = (match_case_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->pattern = pattern; + p->guard = guard; + p->body = body; + return p; +} + +pattern_ty +_PyAST_MatchValue(expr_ty value, int lineno, int col_offset, int end_lineno, + int end_col_offset, PyArena *arena) +{ + pattern_ty p; + if (!value) { + PyErr_SetString(PyExc_ValueError, + "field 'value' is required for MatchValue"); + return NULL; + } + p = (pattern_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->kind = MatchValue_kind; + p->v.MatchValue.value = value; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; + return p; +} + +pattern_ty +_PyAST_MatchSingleton(constant value, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) +{ + pattern_ty p; + if (!value) { + PyErr_SetString(PyExc_ValueError, + "field 'value' is required for MatchSingleton"); + return NULL; + } + p = (pattern_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->kind = MatchSingleton_kind; + p->v.MatchSingleton.value = value; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; + return p; +} + +pattern_ty +_PyAST_MatchSequence(asdl_pattern_seq * patterns, int lineno, int col_offset, + int end_lineno, int end_col_offset, PyArena *arena) +{ + pattern_ty p; + p = (pattern_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->kind = MatchSequence_kind; + p->v.MatchSequence.patterns = patterns; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; + return p; +} + +pattern_ty +_PyAST_MatchMapping(asdl_expr_seq * keys, asdl_pattern_seq * patterns, + identifier rest, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) +{ + pattern_ty p; + p = (pattern_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->kind = MatchMapping_kind; + p->v.MatchMapping.keys = keys; + p->v.MatchMapping.patterns = patterns; + p->v.MatchMapping.rest = rest; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; + return p; +} + +pattern_ty +_PyAST_MatchClass(expr_ty cls, asdl_pattern_seq * patterns, asdl_identifier_seq + * kwd_attrs, asdl_pattern_seq * kwd_patterns, int lineno, int + col_offset, int end_lineno, int end_col_offset, PyArena + *arena) +{ + pattern_ty p; + if (!cls) { + PyErr_SetString(PyExc_ValueError, + "field 'cls' is required for MatchClass"); + return NULL; + } + p = (pattern_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->kind = MatchClass_kind; + p->v.MatchClass.cls = cls; + p->v.MatchClass.patterns = patterns; + p->v.MatchClass.kwd_attrs = kwd_attrs; + p->v.MatchClass.kwd_patterns = kwd_patterns; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; + return p; +} + +pattern_ty +_PyAST_MatchStar(identifier name, int lineno, int col_offset, int end_lineno, + int end_col_offset, PyArena *arena) +{ + pattern_ty p; + p = (pattern_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->kind = MatchStar_kind; + p->v.MatchStar.name = name; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; + return p; +} + +pattern_ty +_PyAST_MatchAs(pattern_ty pattern, identifier name, int lineno, int col_offset, + int end_lineno, int end_col_offset, PyArena *arena) +{ + pattern_ty p; + p = (pattern_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->kind = MatchAs_kind; + p->v.MatchAs.pattern = pattern; + p->v.MatchAs.name = name; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; + return p; +} + +pattern_ty +_PyAST_MatchOr(asdl_pattern_seq * patterns, int lineno, int col_offset, int + end_lineno, int end_col_offset, PyArena *arena) +{ + pattern_ty p; + p = (pattern_ty)_PyArena_Malloc(arena, sizeof(*p)); + if (!p) + return NULL; + p->kind = MatchOr_kind; + p->v.MatchOr.patterns = patterns; + p->lineno = lineno; + p->col_offset = col_offset; + p->end_lineno = end_lineno; + p->end_col_offset = end_col_offset; + return p; +} + type_ignore_ty -TypeIgnore(int lineno, string tag, PyArena *arena) +_PyAST_TypeIgnore(int lineno, string tag, PyArena *arena) { type_ignore_ty p; if (!tag) { @@ -3362,7 +3556,7 @@ TypeIgnore(int lineno, string tag, PyArena *arena) "field 'tag' is required for TypeIgnore"); return NULL; } - p = (type_ignore_ty)PyArena_Malloc(arena, sizeof(*p)); + p = (type_ignore_ty)_PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = TypeIgnore_kind; @@ -3373,7 +3567,7 @@ TypeIgnore(int lineno, string tag, PyArena *arena) PyObject* -ast2obj_mod(astmodulestate *state, void* _o) +ast2obj_mod(struct ast_state *state, void* _o) { mod_ty o = (mod_ty)_o; PyObject *result = NULL, *value = NULL; @@ -3386,12 +3580,12 @@ ast2obj_mod(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Module_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Module.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.Module.body, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.Module.type_ignores, + value = ast2obj_list(state, (asdl_seq*)o->v.Module.type_ignores, ast2obj_type_ignore); if (!value) goto failed; if (PyObject_SetAttr(result, state->type_ignores, value) == -1) @@ -3402,7 +3596,8 @@ ast2obj_mod(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Interactive_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Interactive.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.Interactive.body, + ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; @@ -3422,7 +3617,8 @@ ast2obj_mod(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->FunctionType_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.FunctionType.argtypes, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.FunctionType.argtypes, + ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->argtypes, value) == -1) goto failed; @@ -3442,7 +3638,7 @@ failed: } PyObject* -ast2obj_stmt(astmodulestate *state, void* _o) +ast2obj_stmt(struct ast_state *state, void* _o) { stmt_ty o = (stmt_ty)_o; PyObject *result = NULL, *value = NULL; @@ -3465,12 +3661,13 @@ ast2obj_stmt(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->args, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.FunctionDef.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.FunctionDef.body, + ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.FunctionDef.decorator_list, + value = ast2obj_list(state, (asdl_seq*)o->v.FunctionDef.decorator_list, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->decorator_list, value) == -1) @@ -3501,12 +3698,14 @@ ast2obj_stmt(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->args, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.AsyncFunctionDef.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.AsyncFunctionDef.body, + ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.AsyncFunctionDef.decorator_list, + value = ast2obj_list(state, + (asdl_seq*)o->v.AsyncFunctionDef.decorator_list, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->decorator_list, value) == -1) @@ -3532,22 +3731,26 @@ ast2obj_stmt(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->name, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.ClassDef.bases, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.ClassDef.bases, + ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->bases, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.ClassDef.keywords, ast2obj_keyword); + value = ast2obj_list(state, (asdl_seq*)o->v.ClassDef.keywords, + ast2obj_keyword); if (!value) goto failed; if (PyObject_SetAttr(result, state->keywords, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.ClassDef.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.ClassDef.body, + ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.ClassDef.decorator_list, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.ClassDef.decorator_list, + ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->decorator_list, value) == -1) goto failed; @@ -3567,7 +3770,8 @@ ast2obj_stmt(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Delete_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Delete.targets, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.Delete.targets, + ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->targets, value) == -1) goto failed; @@ -3577,7 +3781,8 @@ ast2obj_stmt(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Assign_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Assign.targets, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.Assign.targets, + ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->targets, value) == -1) goto failed; @@ -3652,12 +3857,12 @@ ast2obj_stmt(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->iter, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.For.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.For.body, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.For.orelse, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.For.orelse, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->orelse, value) == -1) goto failed; @@ -3682,12 +3887,14 @@ ast2obj_stmt(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->iter, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.AsyncFor.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.AsyncFor.body, + ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.AsyncFor.orelse, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.AsyncFor.orelse, + ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->orelse, value) == -1) goto failed; @@ -3707,12 +3914,12 @@ ast2obj_stmt(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->test, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.While.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.While.body, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.While.orelse, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.While.orelse, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->orelse, value) == -1) goto failed; @@ -3727,12 +3934,12 @@ ast2obj_stmt(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->test, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.If.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.If.body, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.If.orelse, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.If.orelse, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->orelse, value) == -1) goto failed; @@ -3742,12 +3949,13 @@ ast2obj_stmt(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->With_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.With.items, ast2obj_withitem); + value = ast2obj_list(state, (asdl_seq*)o->v.With.items, + ast2obj_withitem); if (!value) goto failed; if (PyObject_SetAttr(result, state->items, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.With.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.With.body, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; @@ -3762,12 +3970,14 @@ ast2obj_stmt(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->AsyncWith_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.AsyncWith.items, ast2obj_withitem); + value = ast2obj_list(state, (asdl_seq*)o->v.AsyncWith.items, + ast2obj_withitem); if (!value) goto failed; if (PyObject_SetAttr(result, state->items, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.AsyncWith.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.AsyncWith.body, + ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; @@ -3778,6 +3988,22 @@ ast2obj_stmt(astmodulestate *state, void* _o) goto failed; Py_DECREF(value); break; + case Match_kind: + tp = (PyTypeObject *)state->Match_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) goto failed; + value = ast2obj_expr(state, o->v.Match.subject); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->subject, value) == -1) + goto failed; + Py_DECREF(value); + value = ast2obj_list(state, (asdl_seq*)o->v.Match.cases, + ast2obj_match_case); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->cases, value) == -1) + goto failed; + Py_DECREF(value); + break; case Raise_kind: tp = (PyTypeObject *)state->Raise_type; result = PyType_GenericNew(tp, NULL, NULL); @@ -3797,22 +4023,24 @@ ast2obj_stmt(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Try_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Try.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.Try.body, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.Try.handlers, ast2obj_excepthandler); + value = ast2obj_list(state, (asdl_seq*)o->v.Try.handlers, + ast2obj_excepthandler); if (!value) goto failed; if (PyObject_SetAttr(result, state->handlers, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.Try.orelse, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.Try.orelse, ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->orelse, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.Try.finalbody, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.Try.finalbody, + ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->finalbody, value) == -1) goto failed; @@ -3837,7 +4065,8 @@ ast2obj_stmt(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Import_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Import.names, ast2obj_alias); + value = ast2obj_list(state, (asdl_seq*)o->v.Import.names, + ast2obj_alias); if (!value) goto failed; if (PyObject_SetAttr(result, state->names, value) == -1) goto failed; @@ -3852,7 +4081,8 @@ ast2obj_stmt(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->module, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.ImportFrom.names, ast2obj_alias); + value = ast2obj_list(state, (asdl_seq*)o->v.ImportFrom.names, + ast2obj_alias); if (!value) goto failed; if (PyObject_SetAttr(result, state->names, value) == -1) goto failed; @@ -3867,7 +4097,8 @@ ast2obj_stmt(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Global_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Global.names, ast2obj_identifier); + value = ast2obj_list(state, (asdl_seq*)o->v.Global.names, + ast2obj_identifier); if (!value) goto failed; if (PyObject_SetAttr(result, state->names, value) == -1) goto failed; @@ -3877,7 +4108,8 @@ ast2obj_stmt(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Nonlocal_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Nonlocal.names, ast2obj_identifier); + value = ast2obj_list(state, (asdl_seq*)o->v.Nonlocal.names, + ast2obj_identifier); if (!value) goto failed; if (PyObject_SetAttr(result, state->names, value) == -1) goto failed; @@ -3937,7 +4169,7 @@ failed: } PyObject* -ast2obj_expr(astmodulestate *state, void* _o) +ast2obj_expr(struct ast_state *state, void* _o) { expr_ty o = (expr_ty)_o; PyObject *result = NULL, *value = NULL; @@ -3955,7 +4187,8 @@ ast2obj_expr(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->op, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.BoolOp.values, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.BoolOp.values, + ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->values, value) == -1) goto failed; @@ -4050,12 +4283,12 @@ ast2obj_expr(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Dict_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Dict.keys, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.Dict.keys, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->keys, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.Dict.values, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.Dict.values, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->values, value) == -1) goto failed; @@ -4065,7 +4298,7 @@ ast2obj_expr(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Set_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Set.elts, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.Set.elts, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->elts, value) == -1) goto failed; @@ -4080,7 +4313,7 @@ ast2obj_expr(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->elt, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.ListComp.generators, + value = ast2obj_list(state, (asdl_seq*)o->v.ListComp.generators, ast2obj_comprehension); if (!value) goto failed; if (PyObject_SetAttr(result, state->generators, value) == -1) @@ -4096,7 +4329,7 @@ ast2obj_expr(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->elt, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.SetComp.generators, + value = ast2obj_list(state, (asdl_seq*)o->v.SetComp.generators, ast2obj_comprehension); if (!value) goto failed; if (PyObject_SetAttr(result, state->generators, value) == -1) @@ -4117,7 +4350,7 @@ ast2obj_expr(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->value, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.DictComp.generators, + value = ast2obj_list(state, (asdl_seq*)o->v.DictComp.generators, ast2obj_comprehension); if (!value) goto failed; if (PyObject_SetAttr(result, state->generators, value) == -1) @@ -4133,7 +4366,7 @@ ast2obj_expr(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->elt, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.GeneratorExp.generators, + value = ast2obj_list(state, (asdl_seq*)o->v.GeneratorExp.generators, ast2obj_comprehension); if (!value) goto failed; if (PyObject_SetAttr(result, state->generators, value) == -1) @@ -4190,7 +4423,8 @@ ast2obj_expr(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->ops, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.Compare.comparators, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.Compare.comparators, + ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->comparators, value) == -1) goto failed; @@ -4205,12 +4439,13 @@ ast2obj_expr(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->func, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.Call.args, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.Call.args, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->args, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.Call.keywords, ast2obj_keyword); + value = ast2obj_list(state, (asdl_seq*)o->v.Call.keywords, + ast2obj_keyword); if (!value) goto failed; if (PyObject_SetAttr(result, state->keywords, value) == -1) goto failed; @@ -4240,7 +4475,8 @@ ast2obj_expr(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->JoinedStr_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.JoinedStr.values, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.JoinedStr.values, + ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->values, value) == -1) goto failed; @@ -4335,7 +4571,7 @@ ast2obj_expr(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->List_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.List.elts, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.List.elts, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->elts, value) == -1) goto failed; @@ -4350,7 +4586,7 @@ ast2obj_expr(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->Tuple_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) goto failed; - value = ast2obj_list(state, o->v.Tuple.elts, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->v.Tuple.elts, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->elts, value) == -1) goto failed; @@ -4409,7 +4645,7 @@ failed: return NULL; } -PyObject* ast2obj_expr_context(astmodulestate *state, expr_context_ty o) +PyObject* ast2obj_expr_context(struct ast_state *state, expr_context_ty o) { switch(o) { case Load: @@ -4424,7 +4660,7 @@ PyObject* ast2obj_expr_context(astmodulestate *state, expr_context_ty o) } Py_UNREACHABLE(); } -PyObject* ast2obj_boolop(astmodulestate *state, boolop_ty o) +PyObject* ast2obj_boolop(struct ast_state *state, boolop_ty o) { switch(o) { case And: @@ -4436,7 +4672,7 @@ PyObject* ast2obj_boolop(astmodulestate *state, boolop_ty o) } Py_UNREACHABLE(); } -PyObject* ast2obj_operator(astmodulestate *state, operator_ty o) +PyObject* ast2obj_operator(struct ast_state *state, operator_ty o) { switch(o) { case Add: @@ -4481,7 +4717,7 @@ PyObject* ast2obj_operator(astmodulestate *state, operator_ty o) } Py_UNREACHABLE(); } -PyObject* ast2obj_unaryop(astmodulestate *state, unaryop_ty o) +PyObject* ast2obj_unaryop(struct ast_state *state, unaryop_ty o) { switch(o) { case Invert: @@ -4499,7 +4735,7 @@ PyObject* ast2obj_unaryop(astmodulestate *state, unaryop_ty o) } Py_UNREACHABLE(); } -PyObject* ast2obj_cmpop(astmodulestate *state, cmpop_ty o) +PyObject* ast2obj_cmpop(struct ast_state *state, cmpop_ty o) { switch(o) { case Eq: @@ -4536,7 +4772,7 @@ PyObject* ast2obj_cmpop(astmodulestate *state, cmpop_ty o) Py_UNREACHABLE(); } PyObject* -ast2obj_comprehension(astmodulestate *state, void* _o) +ast2obj_comprehension(struct ast_state *state, void* _o) { comprehension_ty o = (comprehension_ty)_o; PyObject *result = NULL, *value = NULL; @@ -4557,7 +4793,7 @@ ast2obj_comprehension(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->iter, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->ifs, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->ifs, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->ifs, value) == -1) goto failed; @@ -4575,7 +4811,7 @@ failed: } PyObject* -ast2obj_excepthandler(astmodulestate *state, void* _o) +ast2obj_excepthandler(struct ast_state *state, void* _o) { excepthandler_ty o = (excepthandler_ty)_o; PyObject *result = NULL, *value = NULL; @@ -4598,7 +4834,8 @@ ast2obj_excepthandler(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->name, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->v.ExceptHandler.body, ast2obj_stmt); + value = ast2obj_list(state, (asdl_seq*)o->v.ExceptHandler.body, + ast2obj_stmt); if (!value) goto failed; if (PyObject_SetAttr(result, state->body, value) == -1) goto failed; @@ -4633,7 +4870,7 @@ failed: } PyObject* -ast2obj_arguments(astmodulestate *state, void* _o) +ast2obj_arguments(struct ast_state *state, void* _o) { arguments_ty o = (arguments_ty)_o; PyObject *result = NULL, *value = NULL; @@ -4644,12 +4881,12 @@ ast2obj_arguments(astmodulestate *state, void* _o) tp = (PyTypeObject *)state->arguments_type; result = PyType_GenericNew(tp, NULL, NULL); if (!result) return NULL; - value = ast2obj_list(state, o->posonlyargs, ast2obj_arg); + value = ast2obj_list(state, (asdl_seq*)o->posonlyargs, ast2obj_arg); if (!value) goto failed; if (PyObject_SetAttr(result, state->posonlyargs, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->args, ast2obj_arg); + value = ast2obj_list(state, (asdl_seq*)o->args, ast2obj_arg); if (!value) goto failed; if (PyObject_SetAttr(result, state->args, value) == -1) goto failed; @@ -4659,12 +4896,12 @@ ast2obj_arguments(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->vararg, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->kwonlyargs, ast2obj_arg); + value = ast2obj_list(state, (asdl_seq*)o->kwonlyargs, ast2obj_arg); if (!value) goto failed; if (PyObject_SetAttr(result, state->kwonlyargs, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->kw_defaults, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->kw_defaults, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->kw_defaults, value) == -1) goto failed; @@ -4674,7 +4911,7 @@ ast2obj_arguments(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->kwarg, value) == -1) goto failed; Py_DECREF(value); - value = ast2obj_list(state, o->defaults, ast2obj_expr); + value = ast2obj_list(state, (asdl_seq*)o->defaults, ast2obj_expr); if (!value) goto failed; if (PyObject_SetAttr(result, state->defaults, value) == -1) goto failed; @@ -4687,7 +4924,7 @@ failed: } PyObject* -ast2obj_arg(astmodulestate *state, void* _o) +ast2obj_arg(struct ast_state *state, void* _o) { arg_ty o = (arg_ty)_o; PyObject *result = NULL, *value = NULL; @@ -4741,7 +4978,7 @@ failed: } PyObject* -ast2obj_keyword(astmodulestate *state, void* _o) +ast2obj_keyword(struct ast_state *state, void* _o) { keyword_ty o = (keyword_ty)_o; PyObject *result = NULL, *value = NULL; @@ -4790,7 +5027,7 @@ failed: } PyObject* -ast2obj_alias(astmodulestate *state, void* _o) +ast2obj_alias(struct ast_state *state, void* _o) { alias_ty o = (alias_ty)_o; PyObject *result = NULL, *value = NULL; @@ -4811,6 +5048,26 @@ ast2obj_alias(astmodulestate *state, void* _o) if (PyObject_SetAttr(result, state->asname, value) == -1) goto failed; Py_DECREF(value); + value = ast2obj_int(state, o->lineno); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->lineno, value) < 0) + goto failed; + Py_DECREF(value); + value = ast2obj_int(state, o->col_offset); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->col_offset, value) < 0) + goto failed; + Py_DECREF(value); + value = ast2obj_int(state, o->end_lineno); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->end_lineno, value) < 0) + goto failed; + Py_DECREF(value); + value = ast2obj_int(state, o->end_col_offset); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->end_col_offset, value) < 0) + goto failed; + Py_DECREF(value); return result; failed: Py_XDECREF(value); @@ -4819,7 +5076,7 @@ failed: } PyObject* -ast2obj_withitem(astmodulestate *state, void* _o) +ast2obj_withitem(struct ast_state *state, void* _o) { withitem_ty o = (withitem_ty)_o; PyObject *result = NULL, *value = NULL; @@ -4848,7 +5105,196 @@ failed: } PyObject* -ast2obj_type_ignore(astmodulestate *state, void* _o) +ast2obj_match_case(struct ast_state *state, void* _o) +{ + match_case_ty o = (match_case_ty)_o; + PyObject *result = NULL, *value = NULL; + PyTypeObject *tp; + if (!o) { + Py_RETURN_NONE; + } + tp = (PyTypeObject *)state->match_case_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) return NULL; + value = ast2obj_pattern(state, o->pattern); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->pattern, value) == -1) + goto failed; + Py_DECREF(value); + value = ast2obj_expr(state, o->guard); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->guard, value) == -1) + goto failed; + Py_DECREF(value); + value = ast2obj_list(state, (asdl_seq*)o->body, ast2obj_stmt); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->body, value) == -1) + goto failed; + Py_DECREF(value); + return result; +failed: + Py_XDECREF(value); + Py_XDECREF(result); + return NULL; +} + +PyObject* +ast2obj_pattern(struct ast_state *state, void* _o) +{ + pattern_ty o = (pattern_ty)_o; + PyObject *result = NULL, *value = NULL; + PyTypeObject *tp; + if (!o) { + Py_RETURN_NONE; + } + switch (o->kind) { + case MatchValue_kind: + tp = (PyTypeObject *)state->MatchValue_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) goto failed; + value = ast2obj_expr(state, o->v.MatchValue.value); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->value, value) == -1) + goto failed; + Py_DECREF(value); + break; + case MatchSingleton_kind: + tp = (PyTypeObject *)state->MatchSingleton_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) goto failed; + value = ast2obj_constant(state, o->v.MatchSingleton.value); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->value, value) == -1) + goto failed; + Py_DECREF(value); + break; + case MatchSequence_kind: + tp = (PyTypeObject *)state->MatchSequence_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) goto failed; + value = ast2obj_list(state, (asdl_seq*)o->v.MatchSequence.patterns, + ast2obj_pattern); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->patterns, value) == -1) + goto failed; + Py_DECREF(value); + break; + case MatchMapping_kind: + tp = (PyTypeObject *)state->MatchMapping_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) goto failed; + value = ast2obj_list(state, (asdl_seq*)o->v.MatchMapping.keys, + ast2obj_expr); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->keys, value) == -1) + goto failed; + Py_DECREF(value); + value = ast2obj_list(state, (asdl_seq*)o->v.MatchMapping.patterns, + ast2obj_pattern); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->patterns, value) == -1) + goto failed; + Py_DECREF(value); + value = ast2obj_identifier(state, o->v.MatchMapping.rest); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->rest, value) == -1) + goto failed; + Py_DECREF(value); + break; + case MatchClass_kind: + tp = (PyTypeObject *)state->MatchClass_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) goto failed; + value = ast2obj_expr(state, o->v.MatchClass.cls); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->cls, value) == -1) + goto failed; + Py_DECREF(value); + value = ast2obj_list(state, (asdl_seq*)o->v.MatchClass.patterns, + ast2obj_pattern); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->patterns, value) == -1) + goto failed; + Py_DECREF(value); + value = ast2obj_list(state, (asdl_seq*)o->v.MatchClass.kwd_attrs, + ast2obj_identifier); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->kwd_attrs, value) == -1) + goto failed; + Py_DECREF(value); + value = ast2obj_list(state, (asdl_seq*)o->v.MatchClass.kwd_patterns, + ast2obj_pattern); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->kwd_patterns, value) == -1) + goto failed; + Py_DECREF(value); + break; + case MatchStar_kind: + tp = (PyTypeObject *)state->MatchStar_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) goto failed; + value = ast2obj_identifier(state, o->v.MatchStar.name); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->name, value) == -1) + goto failed; + Py_DECREF(value); + break; + case MatchAs_kind: + tp = (PyTypeObject *)state->MatchAs_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) goto failed; + value = ast2obj_pattern(state, o->v.MatchAs.pattern); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->pattern, value) == -1) + goto failed; + Py_DECREF(value); + value = ast2obj_identifier(state, o->v.MatchAs.name); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->name, value) == -1) + goto failed; + Py_DECREF(value); + break; + case MatchOr_kind: + tp = (PyTypeObject *)state->MatchOr_type; + result = PyType_GenericNew(tp, NULL, NULL); + if (!result) goto failed; + value = ast2obj_list(state, (asdl_seq*)o->v.MatchOr.patterns, + ast2obj_pattern); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->patterns, value) == -1) + goto failed; + Py_DECREF(value); + break; + } + value = ast2obj_int(state, o->lineno); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->lineno, value) < 0) + goto failed; + Py_DECREF(value); + value = ast2obj_int(state, o->col_offset); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->col_offset, value) < 0) + goto failed; + Py_DECREF(value); + value = ast2obj_int(state, o->end_lineno); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->end_lineno, value) < 0) + goto failed; + Py_DECREF(value); + value = ast2obj_int(state, o->end_col_offset); + if (!value) goto failed; + if (PyObject_SetAttr(result, state->end_col_offset, value) < 0) + goto failed; + Py_DECREF(value); + return result; +failed: + Py_XDECREF(value); + Py_XDECREF(result); + return NULL; +} + +PyObject* +ast2obj_type_ignore(struct ast_state *state, void* _o) { type_ignore_ty o = (type_ignore_ty)_o; PyObject *result = NULL, *value = NULL; @@ -4882,7 +5328,7 @@ failed: int -obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) +obj2ast_mod(struct ast_state *state, PyObject* obj, mod_ty* out, PyArena* arena) { int isinstance; @@ -4899,8 +5345,8 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* body; - asdl_seq* type_ignores; + asdl_stmt_seq* body; + asdl_type_ignore_seq* type_ignores; if (_PyObject_LookupAttr(obj, state->body, &tmp) < 0) { return 1; @@ -4918,7 +5364,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -4955,7 +5401,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - type_ignores = _Py_asdl_seq_new(len, arena); + type_ignores = _Py_asdl_type_ignore_seq_new(len, arena); if (type_ignores == NULL) goto failed; for (i = 0; i < len; i++) { type_ignore_ty val; @@ -4976,7 +5422,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Module(body, type_ignores, arena); + *out = _PyAST_Module(body, type_ignores, arena); if (*out == NULL) goto failed; return 0; } @@ -4986,7 +5432,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* body; + asdl_stmt_seq* body; if (_PyObject_LookupAttr(obj, state->body, &tmp) < 0) { return 1; @@ -5004,7 +5450,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -5025,7 +5471,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Interactive(body, arena); + *out = _PyAST_Interactive(body, arena); if (*out == NULL) goto failed; return 0; } @@ -5054,7 +5500,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Expression(body, arena); + *out = _PyAST_Expression(body, arena); if (*out == NULL) goto failed; return 0; } @@ -5064,7 +5510,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* argtypes; + asdl_expr_seq* argtypes; expr_ty returns; if (_PyObject_LookupAttr(obj, state->argtypes, &tmp) < 0) { @@ -5083,7 +5529,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - argtypes = _Py_asdl_seq_new(len, arena); + argtypes = _Py_asdl_expr_seq_new(len, arena); if (argtypes == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -5121,7 +5567,7 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = FunctionType(argtypes, returns, arena); + *out = _PyAST_FunctionType(argtypes, returns, arena); if (*out == NULL) goto failed; return 0; } @@ -5133,7 +5579,8 @@ obj2ast_mod(astmodulestate *state, PyObject* obj, mod_ty* out, PyArena* arena) } int -obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) +obj2ast_stmt(struct ast_state *state, PyObject* obj, stmt_ty* out, PyArena* + arena) { int isinstance; @@ -5224,8 +5671,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (isinstance) { identifier name; arguments_ty args; - asdl_seq* body; - asdl_seq* decorator_list; + asdl_stmt_seq* body; + asdl_expr_seq* decorator_list; expr_ty returns; string type_comment; @@ -5279,7 +5726,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -5316,7 +5763,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - decorator_list = _Py_asdl_seq_new(len, arena); + decorator_list = _Py_asdl_expr_seq_new(len, arena); if (decorator_list == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -5371,9 +5818,9 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = FunctionDef(name, args, body, decorator_list, returns, - type_comment, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_FunctionDef(name, args, body, decorator_list, returns, + type_comment, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -5385,8 +5832,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (isinstance) { identifier name; arguments_ty args; - asdl_seq* body; - asdl_seq* decorator_list; + asdl_stmt_seq* body; + asdl_expr_seq* decorator_list; expr_ty returns; string type_comment; @@ -5440,7 +5887,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -5477,7 +5924,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - decorator_list = _Py_asdl_seq_new(len, arena); + decorator_list = _Py_asdl_expr_seq_new(len, arena); if (decorator_list == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -5532,9 +5979,10 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = AsyncFunctionDef(name, args, body, decorator_list, returns, - type_comment, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_AsyncFunctionDef(name, args, body, decorator_list, + returns, type_comment, lineno, + col_offset, end_lineno, end_col_offset, + arena); if (*out == NULL) goto failed; return 0; } @@ -5545,10 +5993,10 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } if (isinstance) { identifier name; - asdl_seq* bases; - asdl_seq* keywords; - asdl_seq* body; - asdl_seq* decorator_list; + asdl_expr_seq* bases; + asdl_keyword_seq* keywords; + asdl_stmt_seq* body; + asdl_expr_seq* decorator_list; if (_PyObject_LookupAttr(obj, state->name, &tmp) < 0) { return 1; @@ -5583,7 +6031,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - bases = _Py_asdl_seq_new(len, arena); + bases = _Py_asdl_expr_seq_new(len, arena); if (bases == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -5620,7 +6068,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - keywords = _Py_asdl_seq_new(len, arena); + keywords = _Py_asdl_keyword_seq_new(len, arena); if (keywords == NULL) goto failed; for (i = 0; i < len; i++) { keyword_ty val; @@ -5657,7 +6105,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -5694,7 +6142,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - decorator_list = _Py_asdl_seq_new(len, arena); + decorator_list = _Py_asdl_expr_seq_new(len, arena); if (decorator_list == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -5715,8 +6163,9 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = ClassDef(name, bases, keywords, body, decorator_list, lineno, - col_offset, end_lineno, end_col_offset, arena); + *out = _PyAST_ClassDef(name, bases, keywords, body, decorator_list, + lineno, col_offset, end_lineno, end_col_offset, + arena); if (*out == NULL) goto failed; return 0; } @@ -5745,8 +6194,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Return(value, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Return(value, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -5756,7 +6205,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* targets; + asdl_expr_seq* targets; if (_PyObject_LookupAttr(obj, state->targets, &tmp) < 0) { return 1; @@ -5774,7 +6223,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - targets = _Py_asdl_seq_new(len, arena); + targets = _Py_asdl_expr_seq_new(len, arena); if (targets == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -5795,8 +6244,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Delete(targets, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Delete(targets, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -5806,7 +6255,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* targets; + asdl_expr_seq* targets; expr_ty value; string type_comment; @@ -5826,7 +6275,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - targets = _Py_asdl_seq_new(len, arena); + targets = _Py_asdl_expr_seq_new(len, arena); if (targets == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -5881,8 +6330,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Assign(targets, value, type_comment, lineno, col_offset, - end_lineno, end_col_offset, arena); + *out = _PyAST_Assign(targets, value, type_comment, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -5947,8 +6396,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = AugAssign(target, op, value, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_AugAssign(target, op, value, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -6031,8 +6480,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = AnnAssign(target, annotation, value, simple, lineno, col_offset, - end_lineno, end_col_offset, arena); + *out = _PyAST_AnnAssign(target, annotation, value, simple, lineno, + col_offset, end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -6044,8 +6493,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (isinstance) { expr_ty target; expr_ty iter; - asdl_seq* body; - asdl_seq* orelse; + asdl_stmt_seq* body; + asdl_stmt_seq* orelse; string type_comment; if (_PyObject_LookupAttr(obj, state->target, &tmp) < 0) { @@ -6098,7 +6547,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6135,7 +6584,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - orelse = _Py_asdl_seq_new(len, arena); + orelse = _Py_asdl_stmt_seq_new(len, arena); if (orelse == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6173,8 +6622,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = For(target, iter, body, orelse, type_comment, lineno, - col_offset, end_lineno, end_col_offset, arena); + *out = _PyAST_For(target, iter, body, orelse, type_comment, lineno, + col_offset, end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -6186,8 +6635,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (isinstance) { expr_ty target; expr_ty iter; - asdl_seq* body; - asdl_seq* orelse; + asdl_stmt_seq* body; + asdl_stmt_seq* orelse; string type_comment; if (_PyObject_LookupAttr(obj, state->target, &tmp) < 0) { @@ -6240,7 +6689,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6277,7 +6726,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - orelse = _Py_asdl_seq_new(len, arena); + orelse = _Py_asdl_stmt_seq_new(len, arena); if (orelse == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6315,8 +6764,9 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = AsyncFor(target, iter, body, orelse, type_comment, lineno, - col_offset, end_lineno, end_col_offset, arena); + *out = _PyAST_AsyncFor(target, iter, body, orelse, type_comment, + lineno, col_offset, end_lineno, end_col_offset, + arena); if (*out == NULL) goto failed; return 0; } @@ -6327,8 +6777,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } if (isinstance) { expr_ty test; - asdl_seq* body; - asdl_seq* orelse; + asdl_stmt_seq* body; + asdl_stmt_seq* orelse; if (_PyObject_LookupAttr(obj, state->test, &tmp) < 0) { return 1; @@ -6363,7 +6813,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6400,7 +6850,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - orelse = _Py_asdl_seq_new(len, arena); + orelse = _Py_asdl_stmt_seq_new(len, arena); if (orelse == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6421,8 +6871,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = While(test, body, orelse, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_While(test, body, orelse, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -6433,8 +6883,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } if (isinstance) { expr_ty test; - asdl_seq* body; - asdl_seq* orelse; + asdl_stmt_seq* body; + asdl_stmt_seq* orelse; if (_PyObject_LookupAttr(obj, state->test, &tmp) < 0) { return 1; @@ -6469,7 +6919,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6506,7 +6956,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - orelse = _Py_asdl_seq_new(len, arena); + orelse = _Py_asdl_stmt_seq_new(len, arena); if (orelse == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6527,8 +6977,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = If(test, body, orelse, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_If(test, body, orelse, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -6538,8 +6988,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* items; - asdl_seq* body; + asdl_withitem_seq* items; + asdl_stmt_seq* body; string type_comment; if (_PyObject_LookupAttr(obj, state->items, &tmp) < 0) { @@ -6558,7 +7008,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - items = _Py_asdl_seq_new(len, arena); + items = _Py_asdl_withitem_seq_new(len, arena); if (items == NULL) goto failed; for (i = 0; i < len; i++) { withitem_ty val; @@ -6595,7 +7045,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6633,8 +7083,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = With(items, body, type_comment, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_With(items, body, type_comment, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -6644,8 +7094,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* items; - asdl_seq* body; + asdl_withitem_seq* items; + asdl_stmt_seq* body; string type_comment; if (_PyObject_LookupAttr(obj, state->items, &tmp) < 0) { @@ -6664,7 +7114,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - items = _Py_asdl_seq_new(len, arena); + items = _Py_asdl_withitem_seq_new(len, arena); if (items == NULL) goto failed; for (i = 0; i < len; i++) { withitem_ty val; @@ -6701,7 +7151,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6739,8 +7189,76 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = AsyncWith(items, body, type_comment, lineno, col_offset, - end_lineno, end_col_offset, arena); + *out = _PyAST_AsyncWith(items, body, type_comment, lineno, col_offset, + end_lineno, end_col_offset, arena); + if (*out == NULL) goto failed; + return 0; + } + tp = state->Match_type; + isinstance = PyObject_IsInstance(obj, tp); + if (isinstance == -1) { + return 1; + } + if (isinstance) { + expr_ty subject; + asdl_match_case_seq* cases; + + if (_PyObject_LookupAttr(obj, state->subject, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"subject\" missing from Match"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'Match' node")) { + goto failed; + } + res = obj2ast_expr(state, tmp, &subject, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->cases, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"cases\" missing from Match"); + return 1; + } + else { + int res; + Py_ssize_t len; + Py_ssize_t i; + if (!PyList_Check(tmp)) { + PyErr_Format(PyExc_TypeError, "Match field \"cases\" must be a list, not a %.200s", _PyType_Name(Py_TYPE(tmp))); + goto failed; + } + len = PyList_GET_SIZE(tmp); + cases = _Py_asdl_match_case_seq_new(len, arena); + if (cases == NULL) goto failed; + for (i = 0; i < len; i++) { + match_case_ty val; + PyObject *tmp2 = PyList_GET_ITEM(tmp, i); + Py_INCREF(tmp2); + if (Py_EnterRecursiveCall(" while traversing 'Match' node")) { + goto failed; + } + res = obj2ast_match_case(state, tmp2, &val, arena); + Py_LeaveRecursiveCall(); + Py_DECREF(tmp2); + if (res != 0) goto failed; + if (len != PyList_GET_SIZE(tmp)) { + PyErr_SetString(PyExc_RuntimeError, "Match field \"cases\" changed size during iteration"); + goto failed; + } + asdl_seq_SET(cases, i, val); + } + Py_CLEAR(tmp); + } + *out = _PyAST_Match(subject, cases, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -6787,8 +7305,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Raise(exc, cause, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Raise(exc, cause, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -6798,10 +7316,10 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* body; - asdl_seq* handlers; - asdl_seq* orelse; - asdl_seq* finalbody; + asdl_stmt_seq* body; + asdl_excepthandler_seq* handlers; + asdl_stmt_seq* orelse; + asdl_stmt_seq* finalbody; if (_PyObject_LookupAttr(obj, state->body, &tmp) < 0) { return 1; @@ -6819,7 +7337,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6856,7 +7374,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - handlers = _Py_asdl_seq_new(len, arena); + handlers = _Py_asdl_excepthandler_seq_new(len, arena); if (handlers == NULL) goto failed; for (i = 0; i < len; i++) { excepthandler_ty val; @@ -6893,7 +7411,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - orelse = _Py_asdl_seq_new(len, arena); + orelse = _Py_asdl_stmt_seq_new(len, arena); if (orelse == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6930,7 +7448,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - finalbody = _Py_asdl_seq_new(len, arena); + finalbody = _Py_asdl_stmt_seq_new(len, arena); if (finalbody == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -6951,8 +7469,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Try(body, handlers, orelse, finalbody, lineno, col_offset, - end_lineno, end_col_offset, arena); + *out = _PyAST_Try(body, handlers, orelse, finalbody, lineno, + col_offset, end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -6999,8 +7517,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Assert(test, msg, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Assert(test, msg, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7010,7 +7528,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* names; + asdl_alias_seq* names; if (_PyObject_LookupAttr(obj, state->names, &tmp) < 0) { return 1; @@ -7028,7 +7546,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - names = _Py_asdl_seq_new(len, arena); + names = _Py_asdl_alias_seq_new(len, arena); if (names == NULL) goto failed; for (i = 0; i < len; i++) { alias_ty val; @@ -7049,8 +7567,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Import(names, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Import(names, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7061,7 +7579,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } if (isinstance) { identifier module; - asdl_seq* names; + asdl_alias_seq* names; int level; if (_PyObject_LookupAttr(obj, state->module, &tmp) < 0) { @@ -7097,7 +7615,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - names = _Py_asdl_seq_new(len, arena); + names = _Py_asdl_alias_seq_new(len, arena); if (names == NULL) goto failed; for (i = 0; i < len; i++) { alias_ty val; @@ -7135,8 +7653,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = ImportFrom(module, names, level, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_ImportFrom(module, names, level, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7146,7 +7664,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* names; + asdl_identifier_seq* names; if (_PyObject_LookupAttr(obj, state->names, &tmp) < 0) { return 1; @@ -7164,7 +7682,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - names = _Py_asdl_seq_new(len, arena); + names = _Py_asdl_identifier_seq_new(len, arena); if (names == NULL) goto failed; for (i = 0; i < len; i++) { identifier val; @@ -7185,8 +7703,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Global(names, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Global(names, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7196,7 +7714,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* names; + asdl_identifier_seq* names; if (_PyObject_LookupAttr(obj, state->names, &tmp) < 0) { return 1; @@ -7214,7 +7732,7 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - names = _Py_asdl_seq_new(len, arena); + names = _Py_asdl_identifier_seq_new(len, arena); if (names == NULL) goto failed; for (i = 0; i < len; i++) { identifier val; @@ -7235,8 +7753,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Nonlocal(names, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Nonlocal(names, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7265,8 +7783,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Expr(value, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Expr(value, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7277,7 +7795,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } if (isinstance) { - *out = Pass(lineno, col_offset, end_lineno, end_col_offset, arena); + *out = _PyAST_Pass(lineno, col_offset, end_lineno, end_col_offset, + arena); if (*out == NULL) goto failed; return 0; } @@ -7288,7 +7807,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } if (isinstance) { - *out = Break(lineno, col_offset, end_lineno, end_col_offset, arena); + *out = _PyAST_Break(lineno, col_offset, end_lineno, end_col_offset, + arena); if (*out == NULL) goto failed; return 0; } @@ -7299,7 +7819,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } if (isinstance) { - *out = Continue(lineno, col_offset, end_lineno, end_col_offset, arena); + *out = _PyAST_Continue(lineno, col_offset, end_lineno, end_col_offset, + arena); if (*out == NULL) goto failed; return 0; } @@ -7311,7 +7832,8 @@ obj2ast_stmt(astmodulestate *state, PyObject* obj, stmt_ty* out, PyArena* arena) } int -obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) +obj2ast_expr(struct ast_state *state, PyObject* obj, expr_ty* out, PyArena* + arena) { int isinstance; @@ -7401,7 +7923,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } if (isinstance) { boolop_ty op; - asdl_seq* values; + asdl_expr_seq* values; if (_PyObject_LookupAttr(obj, state->op, &tmp) < 0) { return 1; @@ -7436,7 +7958,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - values = _Py_asdl_seq_new(len, arena); + values = _Py_asdl_expr_seq_new(len, arena); if (values == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -7457,8 +7979,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = BoolOp(op, values, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_BoolOp(op, values, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7505,8 +8027,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = NamedExpr(target, value, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_NamedExpr(target, value, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7571,8 +8093,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = BinOp(left, op, right, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_BinOp(left, op, right, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7619,8 +8141,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = UnaryOp(op, operand, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_UnaryOp(op, operand, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7667,8 +8189,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Lambda(args, body, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Lambda(args, body, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7733,8 +8255,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = IfExp(test, body, orelse, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_IfExp(test, body, orelse, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7744,8 +8266,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* keys; - asdl_seq* values; + asdl_expr_seq* keys; + asdl_expr_seq* values; if (_PyObject_LookupAttr(obj, state->keys, &tmp) < 0) { return 1; @@ -7763,7 +8285,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - keys = _Py_asdl_seq_new(len, arena); + keys = _Py_asdl_expr_seq_new(len, arena); if (keys == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -7800,7 +8322,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - values = _Py_asdl_seq_new(len, arena); + values = _Py_asdl_expr_seq_new(len, arena); if (values == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -7821,8 +8343,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Dict(keys, values, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Dict(keys, values, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7832,7 +8354,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* elts; + asdl_expr_seq* elts; if (_PyObject_LookupAttr(obj, state->elts, &tmp) < 0) { return 1; @@ -7850,7 +8372,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - elts = _Py_asdl_seq_new(len, arena); + elts = _Py_asdl_expr_seq_new(len, arena); if (elts == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -7871,7 +8393,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Set(elts, lineno, col_offset, end_lineno, end_col_offset, arena); + *out = _PyAST_Set(elts, lineno, col_offset, end_lineno, end_col_offset, + arena); if (*out == NULL) goto failed; return 0; } @@ -7882,7 +8405,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } if (isinstance) { expr_ty elt; - asdl_seq* generators; + asdl_comprehension_seq* generators; if (_PyObject_LookupAttr(obj, state->elt, &tmp) < 0) { return 1; @@ -7917,7 +8440,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - generators = _Py_asdl_seq_new(len, arena); + generators = _Py_asdl_comprehension_seq_new(len, arena); if (generators == NULL) goto failed; for (i = 0; i < len; i++) { comprehension_ty val; @@ -7938,8 +8461,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = ListComp(elt, generators, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_ListComp(elt, generators, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -7950,7 +8473,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } if (isinstance) { expr_ty elt; - asdl_seq* generators; + asdl_comprehension_seq* generators; if (_PyObject_LookupAttr(obj, state->elt, &tmp) < 0) { return 1; @@ -7985,7 +8508,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - generators = _Py_asdl_seq_new(len, arena); + generators = _Py_asdl_comprehension_seq_new(len, arena); if (generators == NULL) goto failed; for (i = 0; i < len; i++) { comprehension_ty val; @@ -8006,8 +8529,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = SetComp(elt, generators, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_SetComp(elt, generators, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8019,7 +8542,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (isinstance) { expr_ty key; expr_ty value; - asdl_seq* generators; + asdl_comprehension_seq* generators; if (_PyObject_LookupAttr(obj, state->key, &tmp) < 0) { return 1; @@ -8071,7 +8594,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - generators = _Py_asdl_seq_new(len, arena); + generators = _Py_asdl_comprehension_seq_new(len, arena); if (generators == NULL) goto failed; for (i = 0; i < len; i++) { comprehension_ty val; @@ -8092,8 +8615,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = DictComp(key, value, generators, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_DictComp(key, value, generators, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8104,7 +8627,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } if (isinstance) { expr_ty elt; - asdl_seq* generators; + asdl_comprehension_seq* generators; if (_PyObject_LookupAttr(obj, state->elt, &tmp) < 0) { return 1; @@ -8139,7 +8662,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - generators = _Py_asdl_seq_new(len, arena); + generators = _Py_asdl_comprehension_seq_new(len, arena); if (generators == NULL) goto failed; for (i = 0; i < len; i++) { comprehension_ty val; @@ -8160,8 +8683,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = GeneratorExp(elt, generators, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_GeneratorExp(elt, generators, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8190,8 +8713,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Await(value, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Await(value, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8220,8 +8743,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Yield(value, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Yield(value, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8250,8 +8773,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = YieldFrom(value, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_YieldFrom(value, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8263,7 +8786,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (isinstance) { expr_ty left; asdl_int_seq* ops; - asdl_seq* comparators; + asdl_expr_seq* comparators; if (_PyObject_LookupAttr(obj, state->left, &tmp) < 0) { return 1; @@ -8335,7 +8858,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - comparators = _Py_asdl_seq_new(len, arena); + comparators = _Py_asdl_expr_seq_new(len, arena); if (comparators == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -8356,8 +8879,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Compare(left, ops, comparators, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Compare(left, ops, comparators, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8368,8 +8891,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } if (isinstance) { expr_ty func; - asdl_seq* args; - asdl_seq* keywords; + asdl_expr_seq* args; + asdl_keyword_seq* keywords; if (_PyObject_LookupAttr(obj, state->func, &tmp) < 0) { return 1; @@ -8404,7 +8927,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - args = _Py_asdl_seq_new(len, arena); + args = _Py_asdl_expr_seq_new(len, arena); if (args == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -8441,7 +8964,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - keywords = _Py_asdl_seq_new(len, arena); + keywords = _Py_asdl_keyword_seq_new(len, arena); if (keywords == NULL) goto failed; for (i = 0; i < len; i++) { keyword_ty val; @@ -8462,8 +8985,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = Call(func, args, keywords, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Call(func, args, keywords, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8497,9 +9020,9 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (_PyObject_LookupAttr(obj, state->conversion, &tmp) < 0) { return 1; } - if (tmp == NULL || tmp == Py_None) { - Py_CLEAR(tmp); - conversion = 0; + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"conversion\" missing from FormattedValue"); + return 1; } else { int res; @@ -8528,8 +9051,9 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = FormattedValue(value, conversion, format_spec, lineno, - col_offset, end_lineno, end_col_offset, arena); + *out = _PyAST_FormattedValue(value, conversion, format_spec, lineno, + col_offset, end_lineno, end_col_offset, + arena); if (*out == NULL) goto failed; return 0; } @@ -8539,7 +9063,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* values; + asdl_expr_seq* values; if (_PyObject_LookupAttr(obj, state->values, &tmp) < 0) { return 1; @@ -8557,7 +9081,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - values = _Py_asdl_seq_new(len, arena); + values = _Py_asdl_expr_seq_new(len, arena); if (values == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -8578,8 +9102,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } Py_CLEAR(tmp); } - *out = JoinedStr(values, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_JoinedStr(values, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8626,8 +9150,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Constant(value, kind, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Constant(value, kind, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8692,8 +9216,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Attribute(value, attr, ctx, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Attribute(value, attr, ctx, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8758,8 +9282,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Subscript(value, slice, ctx, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Subscript(value, slice, ctx, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8806,8 +9330,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Starred(value, ctx, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Starred(value, ctx, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8854,8 +9378,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Name(id, ctx, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Name(id, ctx, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8865,7 +9389,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* elts; + asdl_expr_seq* elts; expr_context_ty ctx; if (_PyObject_LookupAttr(obj, state->elts, &tmp) < 0) { @@ -8884,7 +9408,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - elts = _Py_asdl_seq_new(len, arena); + elts = _Py_asdl_expr_seq_new(len, arena); if (elts == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -8922,8 +9446,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = List(elts, ctx, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_List(elts, ctx, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -8933,7 +9457,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) return 1; } if (isinstance) { - asdl_seq* elts; + asdl_expr_seq* elts; expr_context_ty ctx; if (_PyObject_LookupAttr(obj, state->elts, &tmp) < 0) { @@ -8952,7 +9476,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) goto failed; } len = PyList_GET_SIZE(tmp); - elts = _Py_asdl_seq_new(len, arena); + elts = _Py_asdl_expr_seq_new(len, arena); if (elts == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -8990,8 +9514,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Tuple(elts, ctx, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_Tuple(elts, ctx, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -9056,8 +9580,8 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = Slice(lower, upper, step, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_Slice(lower, upper, step, lineno, col_offset, end_lineno, + end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -9069,7 +9593,7 @@ obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, PyArena* arena) } int -obj2ast_expr_context(astmodulestate *state, PyObject* obj, expr_context_ty* +obj2ast_expr_context(struct ast_state *state, PyObject* obj, expr_context_ty* out, PyArena* arena) { int isinstance; @@ -9104,7 +9628,7 @@ obj2ast_expr_context(astmodulestate *state, PyObject* obj, expr_context_ty* } int -obj2ast_boolop(astmodulestate *state, PyObject* obj, boolop_ty* out, PyArena* +obj2ast_boolop(struct ast_state *state, PyObject* obj, boolop_ty* out, PyArena* arena) { int isinstance; @@ -9131,7 +9655,7 @@ obj2ast_boolop(astmodulestate *state, PyObject* obj, boolop_ty* out, PyArena* } int -obj2ast_operator(astmodulestate *state, PyObject* obj, operator_ty* out, +obj2ast_operator(struct ast_state *state, PyObject* obj, operator_ty* out, PyArena* arena) { int isinstance; @@ -9246,8 +9770,8 @@ obj2ast_operator(astmodulestate *state, PyObject* obj, operator_ty* out, } int -obj2ast_unaryop(astmodulestate *state, PyObject* obj, unaryop_ty* out, PyArena* - arena) +obj2ast_unaryop(struct ast_state *state, PyObject* obj, unaryop_ty* out, + PyArena* arena) { int isinstance; @@ -9289,7 +9813,7 @@ obj2ast_unaryop(astmodulestate *state, PyObject* obj, unaryop_ty* out, PyArena* } int -obj2ast_cmpop(astmodulestate *state, PyObject* obj, cmpop_ty* out, PyArena* +obj2ast_cmpop(struct ast_state *state, PyObject* obj, cmpop_ty* out, PyArena* arena) { int isinstance; @@ -9380,13 +9904,13 @@ obj2ast_cmpop(astmodulestate *state, PyObject* obj, cmpop_ty* out, PyArena* } int -obj2ast_comprehension(astmodulestate *state, PyObject* obj, comprehension_ty* +obj2ast_comprehension(struct ast_state *state, PyObject* obj, comprehension_ty* out, PyArena* arena) { PyObject* tmp = NULL; expr_ty target; expr_ty iter; - asdl_seq* ifs; + asdl_expr_seq* ifs; int is_async; if (_PyObject_LookupAttr(obj, state->target, &tmp) < 0) { @@ -9439,7 +9963,7 @@ obj2ast_comprehension(astmodulestate *state, PyObject* obj, comprehension_ty* goto failed; } len = PyList_GET_SIZE(tmp); - ifs = _Py_asdl_seq_new(len, arena); + ifs = _Py_asdl_expr_seq_new(len, arena); if (ifs == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -9477,7 +10001,7 @@ obj2ast_comprehension(astmodulestate *state, PyObject* obj, comprehension_ty* if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = comprehension(target, iter, ifs, is_async, arena); + *out = _PyAST_comprehension(target, iter, ifs, is_async, arena); return 0; failed: Py_XDECREF(tmp); @@ -9485,7 +10009,7 @@ failed: } int -obj2ast_excepthandler(astmodulestate *state, PyObject* obj, excepthandler_ty* +obj2ast_excepthandler(struct ast_state *state, PyObject* obj, excepthandler_ty* out, PyArena* arena) { int isinstance; @@ -9577,7 +10101,7 @@ obj2ast_excepthandler(astmodulestate *state, PyObject* obj, excepthandler_ty* if (isinstance) { expr_ty type; identifier name; - asdl_seq* body; + asdl_stmt_seq* body; if (_PyObject_LookupAttr(obj, state->type, &tmp) < 0) { return 1; @@ -9629,7 +10153,7 @@ obj2ast_excepthandler(astmodulestate *state, PyObject* obj, excepthandler_ty* goto failed; } len = PyList_GET_SIZE(tmp); - body = _Py_asdl_seq_new(len, arena); + body = _Py_asdl_stmt_seq_new(len, arena); if (body == NULL) goto failed; for (i = 0; i < len; i++) { stmt_ty val; @@ -9650,8 +10174,8 @@ obj2ast_excepthandler(astmodulestate *state, PyObject* obj, excepthandler_ty* } Py_CLEAR(tmp); } - *out = ExceptHandler(type, name, body, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_ExceptHandler(type, name, body, lineno, col_offset, + end_lineno, end_col_offset, arena); if (*out == NULL) goto failed; return 0; } @@ -9663,17 +10187,17 @@ obj2ast_excepthandler(astmodulestate *state, PyObject* obj, excepthandler_ty* } int -obj2ast_arguments(astmodulestate *state, PyObject* obj, arguments_ty* out, +obj2ast_arguments(struct ast_state *state, PyObject* obj, arguments_ty* out, PyArena* arena) { PyObject* tmp = NULL; - asdl_seq* posonlyargs; - asdl_seq* args; + asdl_arg_seq* posonlyargs; + asdl_arg_seq* args; arg_ty vararg; - asdl_seq* kwonlyargs; - asdl_seq* kw_defaults; + asdl_arg_seq* kwonlyargs; + asdl_expr_seq* kw_defaults; arg_ty kwarg; - asdl_seq* defaults; + asdl_expr_seq* defaults; if (_PyObject_LookupAttr(obj, state->posonlyargs, &tmp) < 0) { return 1; @@ -9691,7 +10215,7 @@ obj2ast_arguments(astmodulestate *state, PyObject* obj, arguments_ty* out, goto failed; } len = PyList_GET_SIZE(tmp); - posonlyargs = _Py_asdl_seq_new(len, arena); + posonlyargs = _Py_asdl_arg_seq_new(len, arena); if (posonlyargs == NULL) goto failed; for (i = 0; i < len; i++) { arg_ty val; @@ -9728,7 +10252,7 @@ obj2ast_arguments(astmodulestate *state, PyObject* obj, arguments_ty* out, goto failed; } len = PyList_GET_SIZE(tmp); - args = _Py_asdl_seq_new(len, arena); + args = _Py_asdl_arg_seq_new(len, arena); if (args == NULL) goto failed; for (i = 0; i < len; i++) { arg_ty val; @@ -9782,7 +10306,7 @@ obj2ast_arguments(astmodulestate *state, PyObject* obj, arguments_ty* out, goto failed; } len = PyList_GET_SIZE(tmp); - kwonlyargs = _Py_asdl_seq_new(len, arena); + kwonlyargs = _Py_asdl_arg_seq_new(len, arena); if (kwonlyargs == NULL) goto failed; for (i = 0; i < len; i++) { arg_ty val; @@ -9819,7 +10343,7 @@ obj2ast_arguments(astmodulestate *state, PyObject* obj, arguments_ty* out, goto failed; } len = PyList_GET_SIZE(tmp); - kw_defaults = _Py_asdl_seq_new(len, arena); + kw_defaults = _Py_asdl_expr_seq_new(len, arena); if (kw_defaults == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -9873,7 +10397,7 @@ obj2ast_arguments(astmodulestate *state, PyObject* obj, arguments_ty* out, goto failed; } len = PyList_GET_SIZE(tmp); - defaults = _Py_asdl_seq_new(len, arena); + defaults = _Py_asdl_expr_seq_new(len, arena); if (defaults == NULL) goto failed; for (i = 0; i < len; i++) { expr_ty val; @@ -9894,8 +10418,8 @@ obj2ast_arguments(astmodulestate *state, PyObject* obj, arguments_ty* out, } Py_CLEAR(tmp); } - *out = arguments(posonlyargs, args, vararg, kwonlyargs, kw_defaults, kwarg, - defaults, arena); + *out = _PyAST_arguments(posonlyargs, args, vararg, kwonlyargs, kw_defaults, + kwarg, defaults, arena); return 0; failed: Py_XDECREF(tmp); @@ -9903,7 +10427,7 @@ failed: } int -obj2ast_arg(astmodulestate *state, PyObject* obj, arg_ty* out, PyArena* arena) +obj2ast_arg(struct ast_state *state, PyObject* obj, arg_ty* out, PyArena* arena) { PyObject* tmp = NULL; identifier arg; @@ -10033,8 +10557,8 @@ obj2ast_arg(astmodulestate *state, PyObject* obj, arg_ty* out, PyArena* arena) if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = arg(arg, annotation, type_comment, lineno, col_offset, end_lineno, - end_col_offset, arena); + *out = _PyAST_arg(arg, annotation, type_comment, lineno, col_offset, + end_lineno, end_col_offset, arena); return 0; failed: Py_XDECREF(tmp); @@ -10042,8 +10566,8 @@ failed: } int -obj2ast_keyword(astmodulestate *state, PyObject* obj, keyword_ty* out, PyArena* - arena) +obj2ast_keyword(struct ast_state *state, PyObject* obj, keyword_ty* out, + PyArena* arena) { PyObject* tmp = NULL; identifier arg; @@ -10155,8 +10679,8 @@ obj2ast_keyword(astmodulestate *state, PyObject* obj, keyword_ty* out, PyArena* if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = keyword(arg, value, lineno, col_offset, end_lineno, end_col_offset, - arena); + *out = _PyAST_keyword(arg, value, lineno, col_offset, end_lineno, + end_col_offset, arena); return 0; failed: Py_XDECREF(tmp); @@ -10164,12 +10688,16 @@ failed: } int -obj2ast_alias(astmodulestate *state, PyObject* obj, alias_ty* out, PyArena* +obj2ast_alias(struct ast_state *state, PyObject* obj, alias_ty* out, PyArena* arena) { PyObject* tmp = NULL; identifier name; identifier asname; + int lineno; + int col_offset; + int end_lineno; + int end_col_offset; if (_PyObject_LookupAttr(obj, state->name, &tmp) < 0) { return 1; @@ -10205,7 +10733,76 @@ obj2ast_alias(astmodulestate *state, PyObject* obj, alias_ty* out, PyArena* if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = alias(name, asname, arena); + if (_PyObject_LookupAttr(obj, state->lineno, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"lineno\" missing from alias"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'alias' node")) { + goto failed; + } + res = obj2ast_int(state, tmp, &lineno, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->col_offset, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"col_offset\" missing from alias"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'alias' node")) { + goto failed; + } + res = obj2ast_int(state, tmp, &col_offset, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->end_lineno, &tmp) < 0) { + return 1; + } + if (tmp == NULL || tmp == Py_None) { + Py_CLEAR(tmp); + end_lineno = 0; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'alias' node")) { + goto failed; + } + res = obj2ast_int(state, tmp, &end_lineno, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->end_col_offset, &tmp) < 0) { + return 1; + } + if (tmp == NULL || tmp == Py_None) { + Py_CLEAR(tmp); + end_col_offset = 0; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'alias' node")) { + goto failed; + } + res = obj2ast_int(state, tmp, &end_col_offset, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + *out = _PyAST_alias(name, asname, lineno, col_offset, end_lineno, + end_col_offset, arena); return 0; failed: Py_XDECREF(tmp); @@ -10213,7 +10810,7 @@ failed: } int -obj2ast_withitem(astmodulestate *state, PyObject* obj, withitem_ty* out, +obj2ast_withitem(struct ast_state *state, PyObject* obj, withitem_ty* out, PyArena* arena) { PyObject* tmp = NULL; @@ -10254,7 +10851,94 @@ obj2ast_withitem(astmodulestate *state, PyObject* obj, withitem_ty* out, if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = withitem(context_expr, optional_vars, arena); + *out = _PyAST_withitem(context_expr, optional_vars, arena); + return 0; +failed: + Py_XDECREF(tmp); + return 1; +} + +int +obj2ast_match_case(struct ast_state *state, PyObject* obj, match_case_ty* out, + PyArena* arena) +{ + PyObject* tmp = NULL; + pattern_ty pattern; + expr_ty guard; + asdl_stmt_seq* body; + + if (_PyObject_LookupAttr(obj, state->pattern, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"pattern\" missing from match_case"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'match_case' node")) { + goto failed; + } + res = obj2ast_pattern(state, tmp, &pattern, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->guard, &tmp) < 0) { + return 1; + } + if (tmp == NULL || tmp == Py_None) { + Py_CLEAR(tmp); + guard = NULL; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'match_case' node")) { + goto failed; + } + res = obj2ast_expr(state, tmp, &guard, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->body, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"body\" missing from match_case"); + return 1; + } + else { + int res; + Py_ssize_t len; + Py_ssize_t i; + if (!PyList_Check(tmp)) { + PyErr_Format(PyExc_TypeError, "match_case field \"body\" must be a list, not a %.200s", _PyType_Name(Py_TYPE(tmp))); + goto failed; + } + len = PyList_GET_SIZE(tmp); + body = _Py_asdl_stmt_seq_new(len, arena); + if (body == NULL) goto failed; + for (i = 0; i < len; i++) { + stmt_ty val; + PyObject *tmp2 = PyList_GET_ITEM(tmp, i); + Py_INCREF(tmp2); + if (Py_EnterRecursiveCall(" while traversing 'match_case' node")) { + goto failed; + } + res = obj2ast_stmt(state, tmp2, &val, arena); + Py_LeaveRecursiveCall(); + Py_DECREF(tmp2); + if (res != 0) goto failed; + if (len != PyList_GET_SIZE(tmp)) { + PyErr_SetString(PyExc_RuntimeError, "match_case field \"body\" changed size during iteration"); + goto failed; + } + asdl_seq_SET(body, i, val); + } + Py_CLEAR(tmp); + } + *out = _PyAST_match_case(pattern, guard, body, arena); return 0; failed: Py_XDECREF(tmp); @@ -10262,8 +10946,589 @@ failed: } int -obj2ast_type_ignore(astmodulestate *state, PyObject* obj, type_ignore_ty* out, - PyArena* arena) +obj2ast_pattern(struct ast_state *state, PyObject* obj, pattern_ty* out, + PyArena* arena) +{ + int isinstance; + + PyObject *tmp = NULL; + PyObject *tp; + int lineno; + int col_offset; + int end_lineno; + int end_col_offset; + + if (obj == Py_None) { + *out = NULL; + return 0; + } + if (_PyObject_LookupAttr(obj, state->lineno, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"lineno\" missing from pattern"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'pattern' node")) { + goto failed; + } + res = obj2ast_int(state, tmp, &lineno, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->col_offset, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"col_offset\" missing from pattern"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'pattern' node")) { + goto failed; + } + res = obj2ast_int(state, tmp, &col_offset, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->end_lineno, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"end_lineno\" missing from pattern"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'pattern' node")) { + goto failed; + } + res = obj2ast_int(state, tmp, &end_lineno, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->end_col_offset, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"end_col_offset\" missing from pattern"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'pattern' node")) { + goto failed; + } + res = obj2ast_int(state, tmp, &end_col_offset, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + tp = state->MatchValue_type; + isinstance = PyObject_IsInstance(obj, tp); + if (isinstance == -1) { + return 1; + } + if (isinstance) { + expr_ty value; + + if (_PyObject_LookupAttr(obj, state->value, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"value\" missing from MatchValue"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'MatchValue' node")) { + goto failed; + } + res = obj2ast_expr(state, tmp, &value, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + *out = _PyAST_MatchValue(value, lineno, col_offset, end_lineno, + end_col_offset, arena); + if (*out == NULL) goto failed; + return 0; + } + tp = state->MatchSingleton_type; + isinstance = PyObject_IsInstance(obj, tp); + if (isinstance == -1) { + return 1; + } + if (isinstance) { + constant value; + + if (_PyObject_LookupAttr(obj, state->value, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"value\" missing from MatchSingleton"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'MatchSingleton' node")) { + goto failed; + } + res = obj2ast_constant(state, tmp, &value, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + *out = _PyAST_MatchSingleton(value, lineno, col_offset, end_lineno, + end_col_offset, arena); + if (*out == NULL) goto failed; + return 0; + } + tp = state->MatchSequence_type; + isinstance = PyObject_IsInstance(obj, tp); + if (isinstance == -1) { + return 1; + } + if (isinstance) { + asdl_pattern_seq* patterns; + + if (_PyObject_LookupAttr(obj, state->patterns, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"patterns\" missing from MatchSequence"); + return 1; + } + else { + int res; + Py_ssize_t len; + Py_ssize_t i; + if (!PyList_Check(tmp)) { + PyErr_Format(PyExc_TypeError, "MatchSequence field \"patterns\" must be a list, not a %.200s", _PyType_Name(Py_TYPE(tmp))); + goto failed; + } + len = PyList_GET_SIZE(tmp); + patterns = _Py_asdl_pattern_seq_new(len, arena); + if (patterns == NULL) goto failed; + for (i = 0; i < len; i++) { + pattern_ty val; + PyObject *tmp2 = PyList_GET_ITEM(tmp, i); + Py_INCREF(tmp2); + if (Py_EnterRecursiveCall(" while traversing 'MatchSequence' node")) { + goto failed; + } + res = obj2ast_pattern(state, tmp2, &val, arena); + Py_LeaveRecursiveCall(); + Py_DECREF(tmp2); + if (res != 0) goto failed; + if (len != PyList_GET_SIZE(tmp)) { + PyErr_SetString(PyExc_RuntimeError, "MatchSequence field \"patterns\" changed size during iteration"); + goto failed; + } + asdl_seq_SET(patterns, i, val); + } + Py_CLEAR(tmp); + } + *out = _PyAST_MatchSequence(patterns, lineno, col_offset, end_lineno, + end_col_offset, arena); + if (*out == NULL) goto failed; + return 0; + } + tp = state->MatchMapping_type; + isinstance = PyObject_IsInstance(obj, tp); + if (isinstance == -1) { + return 1; + } + if (isinstance) { + asdl_expr_seq* keys; + asdl_pattern_seq* patterns; + identifier rest; + + if (_PyObject_LookupAttr(obj, state->keys, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"keys\" missing from MatchMapping"); + return 1; + } + else { + int res; + Py_ssize_t len; + Py_ssize_t i; + if (!PyList_Check(tmp)) { + PyErr_Format(PyExc_TypeError, "MatchMapping field \"keys\" must be a list, not a %.200s", _PyType_Name(Py_TYPE(tmp))); + goto failed; + } + len = PyList_GET_SIZE(tmp); + keys = _Py_asdl_expr_seq_new(len, arena); + if (keys == NULL) goto failed; + for (i = 0; i < len; i++) { + expr_ty val; + PyObject *tmp2 = PyList_GET_ITEM(tmp, i); + Py_INCREF(tmp2); + if (Py_EnterRecursiveCall(" while traversing 'MatchMapping' node")) { + goto failed; + } + res = obj2ast_expr(state, tmp2, &val, arena); + Py_LeaveRecursiveCall(); + Py_DECREF(tmp2); + if (res != 0) goto failed; + if (len != PyList_GET_SIZE(tmp)) { + PyErr_SetString(PyExc_RuntimeError, "MatchMapping field \"keys\" changed size during iteration"); + goto failed; + } + asdl_seq_SET(keys, i, val); + } + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->patterns, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"patterns\" missing from MatchMapping"); + return 1; + } + else { + int res; + Py_ssize_t len; + Py_ssize_t i; + if (!PyList_Check(tmp)) { + PyErr_Format(PyExc_TypeError, "MatchMapping field \"patterns\" must be a list, not a %.200s", _PyType_Name(Py_TYPE(tmp))); + goto failed; + } + len = PyList_GET_SIZE(tmp); + patterns = _Py_asdl_pattern_seq_new(len, arena); + if (patterns == NULL) goto failed; + for (i = 0; i < len; i++) { + pattern_ty val; + PyObject *tmp2 = PyList_GET_ITEM(tmp, i); + Py_INCREF(tmp2); + if (Py_EnterRecursiveCall(" while traversing 'MatchMapping' node")) { + goto failed; + } + res = obj2ast_pattern(state, tmp2, &val, arena); + Py_LeaveRecursiveCall(); + Py_DECREF(tmp2); + if (res != 0) goto failed; + if (len != PyList_GET_SIZE(tmp)) { + PyErr_SetString(PyExc_RuntimeError, "MatchMapping field \"patterns\" changed size during iteration"); + goto failed; + } + asdl_seq_SET(patterns, i, val); + } + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->rest, &tmp) < 0) { + return 1; + } + if (tmp == NULL || tmp == Py_None) { + Py_CLEAR(tmp); + rest = NULL; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'MatchMapping' node")) { + goto failed; + } + res = obj2ast_identifier(state, tmp, &rest, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + *out = _PyAST_MatchMapping(keys, patterns, rest, lineno, col_offset, + end_lineno, end_col_offset, arena); + if (*out == NULL) goto failed; + return 0; + } + tp = state->MatchClass_type; + isinstance = PyObject_IsInstance(obj, tp); + if (isinstance == -1) { + return 1; + } + if (isinstance) { + expr_ty cls; + asdl_pattern_seq* patterns; + asdl_identifier_seq* kwd_attrs; + asdl_pattern_seq* kwd_patterns; + + if (_PyObject_LookupAttr(obj, state->cls, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"cls\" missing from MatchClass"); + return 1; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'MatchClass' node")) { + goto failed; + } + res = obj2ast_expr(state, tmp, &cls, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->patterns, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"patterns\" missing from MatchClass"); + return 1; + } + else { + int res; + Py_ssize_t len; + Py_ssize_t i; + if (!PyList_Check(tmp)) { + PyErr_Format(PyExc_TypeError, "MatchClass field \"patterns\" must be a list, not a %.200s", _PyType_Name(Py_TYPE(tmp))); + goto failed; + } + len = PyList_GET_SIZE(tmp); + patterns = _Py_asdl_pattern_seq_new(len, arena); + if (patterns == NULL) goto failed; + for (i = 0; i < len; i++) { + pattern_ty val; + PyObject *tmp2 = PyList_GET_ITEM(tmp, i); + Py_INCREF(tmp2); + if (Py_EnterRecursiveCall(" while traversing 'MatchClass' node")) { + goto failed; + } + res = obj2ast_pattern(state, tmp2, &val, arena); + Py_LeaveRecursiveCall(); + Py_DECREF(tmp2); + if (res != 0) goto failed; + if (len != PyList_GET_SIZE(tmp)) { + PyErr_SetString(PyExc_RuntimeError, "MatchClass field \"patterns\" changed size during iteration"); + goto failed; + } + asdl_seq_SET(patterns, i, val); + } + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->kwd_attrs, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"kwd_attrs\" missing from MatchClass"); + return 1; + } + else { + int res; + Py_ssize_t len; + Py_ssize_t i; + if (!PyList_Check(tmp)) { + PyErr_Format(PyExc_TypeError, "MatchClass field \"kwd_attrs\" must be a list, not a %.200s", _PyType_Name(Py_TYPE(tmp))); + goto failed; + } + len = PyList_GET_SIZE(tmp); + kwd_attrs = _Py_asdl_identifier_seq_new(len, arena); + if (kwd_attrs == NULL) goto failed; + for (i = 0; i < len; i++) { + identifier val; + PyObject *tmp2 = PyList_GET_ITEM(tmp, i); + Py_INCREF(tmp2); + if (Py_EnterRecursiveCall(" while traversing 'MatchClass' node")) { + goto failed; + } + res = obj2ast_identifier(state, tmp2, &val, arena); + Py_LeaveRecursiveCall(); + Py_DECREF(tmp2); + if (res != 0) goto failed; + if (len != PyList_GET_SIZE(tmp)) { + PyErr_SetString(PyExc_RuntimeError, "MatchClass field \"kwd_attrs\" changed size during iteration"); + goto failed; + } + asdl_seq_SET(kwd_attrs, i, val); + } + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->kwd_patterns, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"kwd_patterns\" missing from MatchClass"); + return 1; + } + else { + int res; + Py_ssize_t len; + Py_ssize_t i; + if (!PyList_Check(tmp)) { + PyErr_Format(PyExc_TypeError, "MatchClass field \"kwd_patterns\" must be a list, not a %.200s", _PyType_Name(Py_TYPE(tmp))); + goto failed; + } + len = PyList_GET_SIZE(tmp); + kwd_patterns = _Py_asdl_pattern_seq_new(len, arena); + if (kwd_patterns == NULL) goto failed; + for (i = 0; i < len; i++) { + pattern_ty val; + PyObject *tmp2 = PyList_GET_ITEM(tmp, i); + Py_INCREF(tmp2); + if (Py_EnterRecursiveCall(" while traversing 'MatchClass' node")) { + goto failed; + } + res = obj2ast_pattern(state, tmp2, &val, arena); + Py_LeaveRecursiveCall(); + Py_DECREF(tmp2); + if (res != 0) goto failed; + if (len != PyList_GET_SIZE(tmp)) { + PyErr_SetString(PyExc_RuntimeError, "MatchClass field \"kwd_patterns\" changed size during iteration"); + goto failed; + } + asdl_seq_SET(kwd_patterns, i, val); + } + Py_CLEAR(tmp); + } + *out = _PyAST_MatchClass(cls, patterns, kwd_attrs, kwd_patterns, + lineno, col_offset, end_lineno, + end_col_offset, arena); + if (*out == NULL) goto failed; + return 0; + } + tp = state->MatchStar_type; + isinstance = PyObject_IsInstance(obj, tp); + if (isinstance == -1) { + return 1; + } + if (isinstance) { + identifier name; + + if (_PyObject_LookupAttr(obj, state->name, &tmp) < 0) { + return 1; + } + if (tmp == NULL || tmp == Py_None) { + Py_CLEAR(tmp); + name = NULL; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'MatchStar' node")) { + goto failed; + } + res = obj2ast_identifier(state, tmp, &name, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + *out = _PyAST_MatchStar(name, lineno, col_offset, end_lineno, + end_col_offset, arena); + if (*out == NULL) goto failed; + return 0; + } + tp = state->MatchAs_type; + isinstance = PyObject_IsInstance(obj, tp); + if (isinstance == -1) { + return 1; + } + if (isinstance) { + pattern_ty pattern; + identifier name; + + if (_PyObject_LookupAttr(obj, state->pattern, &tmp) < 0) { + return 1; + } + if (tmp == NULL || tmp == Py_None) { + Py_CLEAR(tmp); + pattern = NULL; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'MatchAs' node")) { + goto failed; + } + res = obj2ast_pattern(state, tmp, &pattern, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + if (_PyObject_LookupAttr(obj, state->name, &tmp) < 0) { + return 1; + } + if (tmp == NULL || tmp == Py_None) { + Py_CLEAR(tmp); + name = NULL; + } + else { + int res; + if (Py_EnterRecursiveCall(" while traversing 'MatchAs' node")) { + goto failed; + } + res = obj2ast_identifier(state, tmp, &name, arena); + Py_LeaveRecursiveCall(); + if (res != 0) goto failed; + Py_CLEAR(tmp); + } + *out = _PyAST_MatchAs(pattern, name, lineno, col_offset, end_lineno, + end_col_offset, arena); + if (*out == NULL) goto failed; + return 0; + } + tp = state->MatchOr_type; + isinstance = PyObject_IsInstance(obj, tp); + if (isinstance == -1) { + return 1; + } + if (isinstance) { + asdl_pattern_seq* patterns; + + if (_PyObject_LookupAttr(obj, state->patterns, &tmp) < 0) { + return 1; + } + if (tmp == NULL) { + PyErr_SetString(PyExc_TypeError, "required field \"patterns\" missing from MatchOr"); + return 1; + } + else { + int res; + Py_ssize_t len; + Py_ssize_t i; + if (!PyList_Check(tmp)) { + PyErr_Format(PyExc_TypeError, "MatchOr field \"patterns\" must be a list, not a %.200s", _PyType_Name(Py_TYPE(tmp))); + goto failed; + } + len = PyList_GET_SIZE(tmp); + patterns = _Py_asdl_pattern_seq_new(len, arena); + if (patterns == NULL) goto failed; + for (i = 0; i < len; i++) { + pattern_ty val; + PyObject *tmp2 = PyList_GET_ITEM(tmp, i); + Py_INCREF(tmp2); + if (Py_EnterRecursiveCall(" while traversing 'MatchOr' node")) { + goto failed; + } + res = obj2ast_pattern(state, tmp2, &val, arena); + Py_LeaveRecursiveCall(); + Py_DECREF(tmp2); + if (res != 0) goto failed; + if (len != PyList_GET_SIZE(tmp)) { + PyErr_SetString(PyExc_RuntimeError, "MatchOr field \"patterns\" changed size during iteration"); + goto failed; + } + asdl_seq_SET(patterns, i, val); + } + Py_CLEAR(tmp); + } + *out = _PyAST_MatchOr(patterns, lineno, col_offset, end_lineno, + end_col_offset, arena); + if (*out == NULL) goto failed; + return 0; + } + + PyErr_Format(PyExc_TypeError, "expected some sort of pattern, but got %R", obj); + failed: + Py_XDECREF(tmp); + return 1; +} + +int +obj2ast_type_ignore(struct ast_state *state, PyObject* obj, type_ignore_ty* + out, PyArena* arena) { int isinstance; @@ -10317,7 +11582,7 @@ obj2ast_type_ignore(astmodulestate *state, PyObject* obj, type_ignore_ty* out, if (res != 0) goto failed; Py_CLEAR(tmp); } - *out = TypeIgnore(lineno, tag, arena); + *out = _PyAST_TypeIgnore(lineno, tag, arena); if (*out == NULL) goto failed; return 0; } @@ -10332,15 +11597,13 @@ obj2ast_type_ignore(astmodulestate *state, PyObject* obj, type_ignore_ty* out, static int astmodule_exec(PyObject *m) { - astmodulestate *state = get_ast_state(m); - - if (!init_types(state)) { + struct ast_state *state = get_ast_state(); + if (state == NULL) { return -1; } - if (PyModule_AddObject(m, "AST", state->AST_type) < 0) { + if (PyModule_AddObjectRef(m, "AST", state->AST_type) < 0) { return -1; } - Py_INCREF(state->AST_type); if (PyModule_AddIntMacro(m, PyCF_ALLOW_TOP_LEVEL_AWAIT) < 0) { return -1; } @@ -10350,432 +11613,368 @@ astmodule_exec(PyObject *m) if (PyModule_AddIntMacro(m, PyCF_TYPE_COMMENTS) < 0) { return -1; } - if (PyModule_AddObject(m, "mod", state->mod_type) < 0) { + if (PyModule_AddObjectRef(m, "mod", state->mod_type) < 0) { return -1; } - Py_INCREF(state->mod_type); - if (PyModule_AddObject(m, "Module", state->Module_type) < 0) { + if (PyModule_AddObjectRef(m, "Module", state->Module_type) < 0) { return -1; } - Py_INCREF(state->Module_type); - if (PyModule_AddObject(m, "Interactive", state->Interactive_type) < 0) { + if (PyModule_AddObjectRef(m, "Interactive", state->Interactive_type) < 0) { return -1; } - Py_INCREF(state->Interactive_type); - if (PyModule_AddObject(m, "Expression", state->Expression_type) < 0) { + if (PyModule_AddObjectRef(m, "Expression", state->Expression_type) < 0) { return -1; } - Py_INCREF(state->Expression_type); - if (PyModule_AddObject(m, "FunctionType", state->FunctionType_type) < 0) { + if (PyModule_AddObjectRef(m, "FunctionType", state->FunctionType_type) < 0) + { return -1; } - Py_INCREF(state->FunctionType_type); - if (PyModule_AddObject(m, "stmt", state->stmt_type) < 0) { + if (PyModule_AddObjectRef(m, "stmt", state->stmt_type) < 0) { return -1; } - Py_INCREF(state->stmt_type); - if (PyModule_AddObject(m, "FunctionDef", state->FunctionDef_type) < 0) { + if (PyModule_AddObjectRef(m, "FunctionDef", state->FunctionDef_type) < 0) { return -1; } - Py_INCREF(state->FunctionDef_type); - if (PyModule_AddObject(m, "AsyncFunctionDef", state->AsyncFunctionDef_type) - < 0) { + if (PyModule_AddObjectRef(m, "AsyncFunctionDef", + state->AsyncFunctionDef_type) < 0) { return -1; } - Py_INCREF(state->AsyncFunctionDef_type); - if (PyModule_AddObject(m, "ClassDef", state->ClassDef_type) < 0) { + if (PyModule_AddObjectRef(m, "ClassDef", state->ClassDef_type) < 0) { return -1; } - Py_INCREF(state->ClassDef_type); - if (PyModule_AddObject(m, "Return", state->Return_type) < 0) { + if (PyModule_AddObjectRef(m, "Return", state->Return_type) < 0) { return -1; } - Py_INCREF(state->Return_type); - if (PyModule_AddObject(m, "Delete", state->Delete_type) < 0) { + if (PyModule_AddObjectRef(m, "Delete", state->Delete_type) < 0) { return -1; } - Py_INCREF(state->Delete_type); - if (PyModule_AddObject(m, "Assign", state->Assign_type) < 0) { + if (PyModule_AddObjectRef(m, "Assign", state->Assign_type) < 0) { return -1; } - Py_INCREF(state->Assign_type); - if (PyModule_AddObject(m, "AugAssign", state->AugAssign_type) < 0) { + if (PyModule_AddObjectRef(m, "AugAssign", state->AugAssign_type) < 0) { return -1; } - Py_INCREF(state->AugAssign_type); - if (PyModule_AddObject(m, "AnnAssign", state->AnnAssign_type) < 0) { + if (PyModule_AddObjectRef(m, "AnnAssign", state->AnnAssign_type) < 0) { return -1; } - Py_INCREF(state->AnnAssign_type); - if (PyModule_AddObject(m, "For", state->For_type) < 0) { + if (PyModule_AddObjectRef(m, "For", state->For_type) < 0) { return -1; } - Py_INCREF(state->For_type); - if (PyModule_AddObject(m, "AsyncFor", state->AsyncFor_type) < 0) { + if (PyModule_AddObjectRef(m, "AsyncFor", state->AsyncFor_type) < 0) { return -1; } - Py_INCREF(state->AsyncFor_type); - if (PyModule_AddObject(m, "While", state->While_type) < 0) { + if (PyModule_AddObjectRef(m, "While", state->While_type) < 0) { return -1; } - Py_INCREF(state->While_type); - if (PyModule_AddObject(m, "If", state->If_type) < 0) { + if (PyModule_AddObjectRef(m, "If", state->If_type) < 0) { return -1; } - Py_INCREF(state->If_type); - if (PyModule_AddObject(m, "With", state->With_type) < 0) { + if (PyModule_AddObjectRef(m, "With", state->With_type) < 0) { return -1; } - Py_INCREF(state->With_type); - if (PyModule_AddObject(m, "AsyncWith", state->AsyncWith_type) < 0) { + if (PyModule_AddObjectRef(m, "AsyncWith", state->AsyncWith_type) < 0) { return -1; } - Py_INCREF(state->AsyncWith_type); - if (PyModule_AddObject(m, "Raise", state->Raise_type) < 0) { + if (PyModule_AddObjectRef(m, "Match", state->Match_type) < 0) { return -1; } - Py_INCREF(state->Raise_type); - if (PyModule_AddObject(m, "Try", state->Try_type) < 0) { + if (PyModule_AddObjectRef(m, "Raise", state->Raise_type) < 0) { return -1; } - Py_INCREF(state->Try_type); - if (PyModule_AddObject(m, "Assert", state->Assert_type) < 0) { + if (PyModule_AddObjectRef(m, "Try", state->Try_type) < 0) { return -1; } - Py_INCREF(state->Assert_type); - if (PyModule_AddObject(m, "Import", state->Import_type) < 0) { + if (PyModule_AddObjectRef(m, "Assert", state->Assert_type) < 0) { return -1; } - Py_INCREF(state->Import_type); - if (PyModule_AddObject(m, "ImportFrom", state->ImportFrom_type) < 0) { + if (PyModule_AddObjectRef(m, "Import", state->Import_type) < 0) { return -1; } - Py_INCREF(state->ImportFrom_type); - if (PyModule_AddObject(m, "Global", state->Global_type) < 0) { + if (PyModule_AddObjectRef(m, "ImportFrom", state->ImportFrom_type) < 0) { return -1; } - Py_INCREF(state->Global_type); - if (PyModule_AddObject(m, "Nonlocal", state->Nonlocal_type) < 0) { + if (PyModule_AddObjectRef(m, "Global", state->Global_type) < 0) { return -1; } - Py_INCREF(state->Nonlocal_type); - if (PyModule_AddObject(m, "Expr", state->Expr_type) < 0) { + if (PyModule_AddObjectRef(m, "Nonlocal", state->Nonlocal_type) < 0) { return -1; } - Py_INCREF(state->Expr_type); - if (PyModule_AddObject(m, "Pass", state->Pass_type) < 0) { + if (PyModule_AddObjectRef(m, "Expr", state->Expr_type) < 0) { return -1; } - Py_INCREF(state->Pass_type); - if (PyModule_AddObject(m, "Break", state->Break_type) < 0) { + if (PyModule_AddObjectRef(m, "Pass", state->Pass_type) < 0) { return -1; } - Py_INCREF(state->Break_type); - if (PyModule_AddObject(m, "Continue", state->Continue_type) < 0) { + if (PyModule_AddObjectRef(m, "Break", state->Break_type) < 0) { return -1; } - Py_INCREF(state->Continue_type); - if (PyModule_AddObject(m, "expr", state->expr_type) < 0) { + if (PyModule_AddObjectRef(m, "Continue", state->Continue_type) < 0) { return -1; } - Py_INCREF(state->expr_type); - if (PyModule_AddObject(m, "BoolOp", state->BoolOp_type) < 0) { + if (PyModule_AddObjectRef(m, "expr", state->expr_type) < 0) { return -1; } - Py_INCREF(state->BoolOp_type); - if (PyModule_AddObject(m, "NamedExpr", state->NamedExpr_type) < 0) { + if (PyModule_AddObjectRef(m, "BoolOp", state->BoolOp_type) < 0) { return -1; } - Py_INCREF(state->NamedExpr_type); - if (PyModule_AddObject(m, "BinOp", state->BinOp_type) < 0) { + if (PyModule_AddObjectRef(m, "NamedExpr", state->NamedExpr_type) < 0) { return -1; } - Py_INCREF(state->BinOp_type); - if (PyModule_AddObject(m, "UnaryOp", state->UnaryOp_type) < 0) { + if (PyModule_AddObjectRef(m, "BinOp", state->BinOp_type) < 0) { return -1; } - Py_INCREF(state->UnaryOp_type); - if (PyModule_AddObject(m, "Lambda", state->Lambda_type) < 0) { + if (PyModule_AddObjectRef(m, "UnaryOp", state->UnaryOp_type) < 0) { return -1; } - Py_INCREF(state->Lambda_type); - if (PyModule_AddObject(m, "IfExp", state->IfExp_type) < 0) { + if (PyModule_AddObjectRef(m, "Lambda", state->Lambda_type) < 0) { return -1; } - Py_INCREF(state->IfExp_type); - if (PyModule_AddObject(m, "Dict", state->Dict_type) < 0) { + if (PyModule_AddObjectRef(m, "IfExp", state->IfExp_type) < 0) { return -1; } - Py_INCREF(state->Dict_type); - if (PyModule_AddObject(m, "Set", state->Set_type) < 0) { + if (PyModule_AddObjectRef(m, "Dict", state->Dict_type) < 0) { return -1; } - Py_INCREF(state->Set_type); - if (PyModule_AddObject(m, "ListComp", state->ListComp_type) < 0) { + if (PyModule_AddObjectRef(m, "Set", state->Set_type) < 0) { return -1; } - Py_INCREF(state->ListComp_type); - if (PyModule_AddObject(m, "SetComp", state->SetComp_type) < 0) { + if (PyModule_AddObjectRef(m, "ListComp", state->ListComp_type) < 0) { return -1; } - Py_INCREF(state->SetComp_type); - if (PyModule_AddObject(m, "DictComp", state->DictComp_type) < 0) { + if (PyModule_AddObjectRef(m, "SetComp", state->SetComp_type) < 0) { return -1; } - Py_INCREF(state->DictComp_type); - if (PyModule_AddObject(m, "GeneratorExp", state->GeneratorExp_type) < 0) { + if (PyModule_AddObjectRef(m, "DictComp", state->DictComp_type) < 0) { return -1; } - Py_INCREF(state->GeneratorExp_type); - if (PyModule_AddObject(m, "Await", state->Await_type) < 0) { + if (PyModule_AddObjectRef(m, "GeneratorExp", state->GeneratorExp_type) < 0) + { return -1; } - Py_INCREF(state->Await_type); - if (PyModule_AddObject(m, "Yield", state->Yield_type) < 0) { + if (PyModule_AddObjectRef(m, "Await", state->Await_type) < 0) { return -1; } - Py_INCREF(state->Yield_type); - if (PyModule_AddObject(m, "YieldFrom", state->YieldFrom_type) < 0) { + if (PyModule_AddObjectRef(m, "Yield", state->Yield_type) < 0) { return -1; } - Py_INCREF(state->YieldFrom_type); - if (PyModule_AddObject(m, "Compare", state->Compare_type) < 0) { + if (PyModule_AddObjectRef(m, "YieldFrom", state->YieldFrom_type) < 0) { return -1; } - Py_INCREF(state->Compare_type); - if (PyModule_AddObject(m, "Call", state->Call_type) < 0) { + if (PyModule_AddObjectRef(m, "Compare", state->Compare_type) < 0) { return -1; } - Py_INCREF(state->Call_type); - if (PyModule_AddObject(m, "FormattedValue", state->FormattedValue_type) < - 0) { + if (PyModule_AddObjectRef(m, "Call", state->Call_type) < 0) { return -1; } - Py_INCREF(state->FormattedValue_type); - if (PyModule_AddObject(m, "JoinedStr", state->JoinedStr_type) < 0) { + if (PyModule_AddObjectRef(m, "FormattedValue", state->FormattedValue_type) + < 0) { return -1; } - Py_INCREF(state->JoinedStr_type); - if (PyModule_AddObject(m, "Constant", state->Constant_type) < 0) { + if (PyModule_AddObjectRef(m, "JoinedStr", state->JoinedStr_type) < 0) { return -1; } - Py_INCREF(state->Constant_type); - if (PyModule_AddObject(m, "Attribute", state->Attribute_type) < 0) { + if (PyModule_AddObjectRef(m, "Constant", state->Constant_type) < 0) { return -1; } - Py_INCREF(state->Attribute_type); - if (PyModule_AddObject(m, "Subscript", state->Subscript_type) < 0) { + if (PyModule_AddObjectRef(m, "Attribute", state->Attribute_type) < 0) { return -1; } - Py_INCREF(state->Subscript_type); - if (PyModule_AddObject(m, "Starred", state->Starred_type) < 0) { + if (PyModule_AddObjectRef(m, "Subscript", state->Subscript_type) < 0) { return -1; } - Py_INCREF(state->Starred_type); - if (PyModule_AddObject(m, "Name", state->Name_type) < 0) { + if (PyModule_AddObjectRef(m, "Starred", state->Starred_type) < 0) { return -1; } - Py_INCREF(state->Name_type); - if (PyModule_AddObject(m, "List", state->List_type) < 0) { + if (PyModule_AddObjectRef(m, "Name", state->Name_type) < 0) { return -1; } - Py_INCREF(state->List_type); - if (PyModule_AddObject(m, "Tuple", state->Tuple_type) < 0) { + if (PyModule_AddObjectRef(m, "List", state->List_type) < 0) { return -1; } - Py_INCREF(state->Tuple_type); - if (PyModule_AddObject(m, "Slice", state->Slice_type) < 0) { + if (PyModule_AddObjectRef(m, "Tuple", state->Tuple_type) < 0) { return -1; } - Py_INCREF(state->Slice_type); - if (PyModule_AddObject(m, "expr_context", state->expr_context_type) < 0) { + if (PyModule_AddObjectRef(m, "Slice", state->Slice_type) < 0) { return -1; } - Py_INCREF(state->expr_context_type); - if (PyModule_AddObject(m, "Load", state->Load_type) < 0) { + if (PyModule_AddObjectRef(m, "expr_context", state->expr_context_type) < 0) + { return -1; } - Py_INCREF(state->Load_type); - if (PyModule_AddObject(m, "Store", state->Store_type) < 0) { + if (PyModule_AddObjectRef(m, "Load", state->Load_type) < 0) { return -1; } - Py_INCREF(state->Store_type); - if (PyModule_AddObject(m, "Del", state->Del_type) < 0) { + if (PyModule_AddObjectRef(m, "Store", state->Store_type) < 0) { return -1; } - Py_INCREF(state->Del_type); - if (PyModule_AddObject(m, "boolop", state->boolop_type) < 0) { + if (PyModule_AddObjectRef(m, "Del", state->Del_type) < 0) { return -1; } - Py_INCREF(state->boolop_type); - if (PyModule_AddObject(m, "And", state->And_type) < 0) { + if (PyModule_AddObjectRef(m, "boolop", state->boolop_type) < 0) { return -1; } - Py_INCREF(state->And_type); - if (PyModule_AddObject(m, "Or", state->Or_type) < 0) { + if (PyModule_AddObjectRef(m, "And", state->And_type) < 0) { return -1; } - Py_INCREF(state->Or_type); - if (PyModule_AddObject(m, "operator", state->operator_type) < 0) { + if (PyModule_AddObjectRef(m, "Or", state->Or_type) < 0) { return -1; } - Py_INCREF(state->operator_type); - if (PyModule_AddObject(m, "Add", state->Add_type) < 0) { + if (PyModule_AddObjectRef(m, "operator", state->operator_type) < 0) { return -1; } - Py_INCREF(state->Add_type); - if (PyModule_AddObject(m, "Sub", state->Sub_type) < 0) { + if (PyModule_AddObjectRef(m, "Add", state->Add_type) < 0) { return -1; } - Py_INCREF(state->Sub_type); - if (PyModule_AddObject(m, "Mult", state->Mult_type) < 0) { + if (PyModule_AddObjectRef(m, "Sub", state->Sub_type) < 0) { return -1; } - Py_INCREF(state->Mult_type); - if (PyModule_AddObject(m, "MatMult", state->MatMult_type) < 0) { + if (PyModule_AddObjectRef(m, "Mult", state->Mult_type) < 0) { return -1; } - Py_INCREF(state->MatMult_type); - if (PyModule_AddObject(m, "Div", state->Div_type) < 0) { + if (PyModule_AddObjectRef(m, "MatMult", state->MatMult_type) < 0) { return -1; } - Py_INCREF(state->Div_type); - if (PyModule_AddObject(m, "Mod", state->Mod_type) < 0) { + if (PyModule_AddObjectRef(m, "Div", state->Div_type) < 0) { return -1; } - Py_INCREF(state->Mod_type); - if (PyModule_AddObject(m, "Pow", state->Pow_type) < 0) { + if (PyModule_AddObjectRef(m, "Mod", state->Mod_type) < 0) { return -1; } - Py_INCREF(state->Pow_type); - if (PyModule_AddObject(m, "LShift", state->LShift_type) < 0) { + if (PyModule_AddObjectRef(m, "Pow", state->Pow_type) < 0) { return -1; } - Py_INCREF(state->LShift_type); - if (PyModule_AddObject(m, "RShift", state->RShift_type) < 0) { + if (PyModule_AddObjectRef(m, "LShift", state->LShift_type) < 0) { return -1; } - Py_INCREF(state->RShift_type); - if (PyModule_AddObject(m, "BitOr", state->BitOr_type) < 0) { + if (PyModule_AddObjectRef(m, "RShift", state->RShift_type) < 0) { return -1; } - Py_INCREF(state->BitOr_type); - if (PyModule_AddObject(m, "BitXor", state->BitXor_type) < 0) { + if (PyModule_AddObjectRef(m, "BitOr", state->BitOr_type) < 0) { return -1; } - Py_INCREF(state->BitXor_type); - if (PyModule_AddObject(m, "BitAnd", state->BitAnd_type) < 0) { + if (PyModule_AddObjectRef(m, "BitXor", state->BitXor_type) < 0) { return -1; } - Py_INCREF(state->BitAnd_type); - if (PyModule_AddObject(m, "FloorDiv", state->FloorDiv_type) < 0) { + if (PyModule_AddObjectRef(m, "BitAnd", state->BitAnd_type) < 0) { return -1; } - Py_INCREF(state->FloorDiv_type); - if (PyModule_AddObject(m, "unaryop", state->unaryop_type) < 0) { + if (PyModule_AddObjectRef(m, "FloorDiv", state->FloorDiv_type) < 0) { return -1; } - Py_INCREF(state->unaryop_type); - if (PyModule_AddObject(m, "Invert", state->Invert_type) < 0) { + if (PyModule_AddObjectRef(m, "unaryop", state->unaryop_type) < 0) { return -1; } - Py_INCREF(state->Invert_type); - if (PyModule_AddObject(m, "Not", state->Not_type) < 0) { + if (PyModule_AddObjectRef(m, "Invert", state->Invert_type) < 0) { return -1; } - Py_INCREF(state->Not_type); - if (PyModule_AddObject(m, "UAdd", state->UAdd_type) < 0) { + if (PyModule_AddObjectRef(m, "Not", state->Not_type) < 0) { return -1; } - Py_INCREF(state->UAdd_type); - if (PyModule_AddObject(m, "USub", state->USub_type) < 0) { + if (PyModule_AddObjectRef(m, "UAdd", state->UAdd_type) < 0) { return -1; } - Py_INCREF(state->USub_type); - if (PyModule_AddObject(m, "cmpop", state->cmpop_type) < 0) { + if (PyModule_AddObjectRef(m, "USub", state->USub_type) < 0) { return -1; } - Py_INCREF(state->cmpop_type); - if (PyModule_AddObject(m, "Eq", state->Eq_type) < 0) { + if (PyModule_AddObjectRef(m, "cmpop", state->cmpop_type) < 0) { return -1; } - Py_INCREF(state->Eq_type); - if (PyModule_AddObject(m, "NotEq", state->NotEq_type) < 0) { + if (PyModule_AddObjectRef(m, "Eq", state->Eq_type) < 0) { return -1; } - Py_INCREF(state->NotEq_type); - if (PyModule_AddObject(m, "Lt", state->Lt_type) < 0) { + if (PyModule_AddObjectRef(m, "NotEq", state->NotEq_type) < 0) { return -1; } - Py_INCREF(state->Lt_type); - if (PyModule_AddObject(m, "LtE", state->LtE_type) < 0) { + if (PyModule_AddObjectRef(m, "Lt", state->Lt_type) < 0) { return -1; } - Py_INCREF(state->LtE_type); - if (PyModule_AddObject(m, "Gt", state->Gt_type) < 0) { + if (PyModule_AddObjectRef(m, "LtE", state->LtE_type) < 0) { return -1; } - Py_INCREF(state->Gt_type); - if (PyModule_AddObject(m, "GtE", state->GtE_type) < 0) { + if (PyModule_AddObjectRef(m, "Gt", state->Gt_type) < 0) { return -1; } - Py_INCREF(state->GtE_type); - if (PyModule_AddObject(m, "Is", state->Is_type) < 0) { + if (PyModule_AddObjectRef(m, "GtE", state->GtE_type) < 0) { return -1; } - Py_INCREF(state->Is_type); - if (PyModule_AddObject(m, "IsNot", state->IsNot_type) < 0) { + if (PyModule_AddObjectRef(m, "Is", state->Is_type) < 0) { return -1; } - Py_INCREF(state->IsNot_type); - if (PyModule_AddObject(m, "In", state->In_type) < 0) { + if (PyModule_AddObjectRef(m, "IsNot", state->IsNot_type) < 0) { return -1; } - Py_INCREF(state->In_type); - if (PyModule_AddObject(m, "NotIn", state->NotIn_type) < 0) { + if (PyModule_AddObjectRef(m, "In", state->In_type) < 0) { return -1; } - Py_INCREF(state->NotIn_type); - if (PyModule_AddObject(m, "comprehension", state->comprehension_type) < 0) { + if (PyModule_AddObjectRef(m, "NotIn", state->NotIn_type) < 0) { return -1; } - Py_INCREF(state->comprehension_type); - if (PyModule_AddObject(m, "excepthandler", state->excepthandler_type) < 0) { + if (PyModule_AddObjectRef(m, "comprehension", state->comprehension_type) < + 0) { return -1; } - Py_INCREF(state->excepthandler_type); - if (PyModule_AddObject(m, "ExceptHandler", state->ExceptHandler_type) < 0) { + if (PyModule_AddObjectRef(m, "excepthandler", state->excepthandler_type) < + 0) { return -1; } - Py_INCREF(state->ExceptHandler_type); - if (PyModule_AddObject(m, "arguments", state->arguments_type) < 0) { + if (PyModule_AddObjectRef(m, "ExceptHandler", state->ExceptHandler_type) < + 0) { return -1; } - Py_INCREF(state->arguments_type); - if (PyModule_AddObject(m, "arg", state->arg_type) < 0) { + if (PyModule_AddObjectRef(m, "arguments", state->arguments_type) < 0) { return -1; } - Py_INCREF(state->arg_type); - if (PyModule_AddObject(m, "keyword", state->keyword_type) < 0) { + if (PyModule_AddObjectRef(m, "arg", state->arg_type) < 0) { return -1; } - Py_INCREF(state->keyword_type); - if (PyModule_AddObject(m, "alias", state->alias_type) < 0) { + if (PyModule_AddObjectRef(m, "keyword", state->keyword_type) < 0) { return -1; } - Py_INCREF(state->alias_type); - if (PyModule_AddObject(m, "withitem", state->withitem_type) < 0) { + if (PyModule_AddObjectRef(m, "alias", state->alias_type) < 0) { return -1; } - Py_INCREF(state->withitem_type); - if (PyModule_AddObject(m, "type_ignore", state->type_ignore_type) < 0) { + if (PyModule_AddObjectRef(m, "withitem", state->withitem_type) < 0) { return -1; } - Py_INCREF(state->type_ignore_type); - if (PyModule_AddObject(m, "TypeIgnore", state->TypeIgnore_type) < 0) { + if (PyModule_AddObjectRef(m, "match_case", state->match_case_type) < 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "pattern", state->pattern_type) < 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "MatchValue", state->MatchValue_type) < 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "MatchSingleton", state->MatchSingleton_type) + < 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "MatchSequence", state->MatchSequence_type) < + 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "MatchMapping", state->MatchMapping_type) < 0) + { + return -1; + } + if (PyModule_AddObjectRef(m, "MatchClass", state->MatchClass_type) < 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "MatchStar", state->MatchStar_type) < 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "MatchAs", state->MatchAs_type) < 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "MatchOr", state->MatchOr_type) < 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "type_ignore", state->type_ignore_type) < 0) { + return -1; + } + if (PyModule_AddObjectRef(m, "TypeIgnore", state->TypeIgnore_type) < 0) { return -1; } - Py_INCREF(state->TypeIgnore_type); return 0; } @@ -10787,7 +11986,7 @@ static PyModuleDef_Slot astmodule_slots[] = { static struct PyModuleDef _astmodule = { PyModuleDef_HEAD_INIT, .m_name = "_ast", - // The _ast module uses a global state (global_ast_state). + // The _ast module uses a per-interpreter state (PyInterpreterState.ast) .m_size = 0, .m_slots = astmodule_slots, }; @@ -10801,7 +12000,7 @@ PyInit__ast(void) PyObject* PyAST_mod2obj(mod_ty t) { - astmodulestate *state = get_global_ast_state(); + struct ast_state *state = get_ast_state(); if (state == NULL) { return NULL; } @@ -10818,7 +12017,11 @@ mod_ty PyAST_obj2mod(PyObject* ast, PyArena* arena, int mode) return NULL; } - astmodulestate *state = get_global_ast_state(); + struct ast_state *state = get_ast_state(); + if (state == NULL) { + return NULL; + } + PyObject *req_type[3]; req_type[0] = state->Module_type; req_type[1] = state->Expression_type; @@ -10844,7 +12047,7 @@ mod_ty PyAST_obj2mod(PyObject* ast, PyArena* arena, int mode) int PyAST_Check(PyObject* obj) { - astmodulestate *state = get_global_ast_state(); + struct ast_state *state = get_ast_state(); if (state == NULL) { return -1; } diff --git a/contrib/tools/python3/src/Python/_warnings.c b/contrib/tools/python3/src/Python/_warnings.c index 91a78fe72b3..2c9a2a76872 100644 --- a/contrib/tools/python3/src/Python/_warnings.c +++ b/contrib/tools/python3/src/Python/_warnings.c @@ -1,6 +1,7 @@ #include "Python.h" #include "pycore_initconfig.h" #include "pycore_interp.h" // PyInterpreterState.warnings +#include "pycore_long.h" // _PyLong_GetZero() #include "pycore_pyerrors.h" #include "pycore_pystate.h" // _PyThreadState_GET() #include "frameobject.h" // PyFrame_GetBack() @@ -23,23 +24,20 @@ _Py_IDENTIFIER(ignore); typedef struct _warnings_runtime_state WarningsState; -/* Forward declaration of the _warnings module definition. */ -static struct PyModuleDef warningsmodule; - _Py_IDENTIFIER(__name__); /* Given a module object, get its per-module state. */ static WarningsState * warnings_get_state(void) { - PyThreadState *tstate = _PyThreadState_GET(); - if (tstate == NULL) { - _PyErr_SetString(tstate, PyExc_RuntimeError, - "warnings_get_state: could not identify " - "current interpreter"); + PyInterpreterState *interp = _PyInterpreterState_GET(); + if (interp == NULL) { + PyErr_SetString(PyExc_RuntimeError, + "warnings_get_state: could not identify " + "current interpreter"); return NULL; } - return &tstate->interp->warnings; + return &interp->warnings; } /* Clear the given warnings module state. */ @@ -68,13 +66,12 @@ create_filter(PyObject *category, _Py_Identifier *id, const char *modname) return NULL; } } else { - modname_obj = Py_None; - Py_INCREF(modname_obj); + modname_obj = Py_NewRef(Py_None); } /* This assumes the line number is zero for now. */ PyObject *filter = PyTuple_Pack(5, action_str, Py_None, - category, modname_obj, _PyLong_Zero); + category, modname_obj, _PyLong_GetZero()); Py_DECREF(modname_obj); return filter; } @@ -116,37 +113,34 @@ init_filters(void) } /* Initialize the given warnings module state. */ -static int -warnings_init_state(WarningsState *st) +int +_PyWarnings_InitState(PyInterpreterState *interp) { + WarningsState *st = &interp->warnings; + if (st->filters == NULL) { st->filters = init_filters(); if (st->filters == NULL) { - goto error; + return -1; } } if (st->once_registry == NULL) { st->once_registry = PyDict_New(); if (st->once_registry == NULL) { - goto error; + return -1; } } if (st->default_action == NULL) { st->default_action = PyUnicode_FromString("default"); if (st->default_action == NULL) { - goto error; + return -1; } } st->filters_version = 0; - return 0; - -error: - warnings_clear_state(st); - return -1; } @@ -475,7 +469,7 @@ update_registry(PyObject *registry, PyObject *text, PyObject *category, int rc; if (add_zero) - altkey = PyTuple_Pack(3, text, category, _PyLong_Zero); + altkey = PyTuple_Pack(3, text, category, _PyLong_GetZero()); else altkey = PyTuple_Pack(2, text, category); @@ -854,7 +848,7 @@ setup_context(Py_ssize_t stack_level, PyObject **filename, int *lineno, } if (f == NULL) { - globals = _PyInterpreterState_GET()->sysdict; + globals = tstate->interp->sysdict; *filename = PyUnicode_FromString("sys"); *lineno = 1; } @@ -1356,70 +1350,45 @@ static PyMethodDef warnings_functions[] = { }; -static struct PyModuleDef warningsmodule = { - PyModuleDef_HEAD_INIT, - MODULE_NAME, /* m_name */ - warnings__doc__, /* m_doc */ - 0, /* m_size */ - warnings_functions, /* m_methods */ - NULL, /* m_reload */ - NULL, /* m_traverse */ - NULL, /* m_clear */ - NULL /* m_free */ -}; - - -PyStatus -_PyWarnings_InitState(PyThreadState *tstate) -{ - if (warnings_init_state(&tstate->interp->warnings) < 0) { - return _PyStatus_ERR("can't initialize warnings"); - } - return _PyStatus_OK(); -} - - -PyMODINIT_FUNC -_PyWarnings_Init(void) +static int +warnings_module_exec(PyObject *module) { - PyObject *m; - - m = PyModule_Create(&warningsmodule); - if (m == NULL) { - return NULL; - } - WarningsState *st = warnings_get_state(); if (st == NULL) { - goto error; + return -1; } - if (warnings_init_state(st) < 0) { - goto error; + if (PyModule_AddObjectRef(module, "filters", st->filters) < 0) { + return -1; } - - Py_INCREF(st->filters); - if (PyModule_AddObject(m, "filters", st->filters) < 0) { - goto error; + if (PyModule_AddObjectRef(module, "_onceregistry", st->once_registry) < 0) { + return -1; } - - Py_INCREF(st->once_registry); - if (PyModule_AddObject(m, "_onceregistry", st->once_registry) < 0) { - goto error; + if (PyModule_AddObjectRef(module, "_defaultaction", st->default_action) < 0) { + return -1; } + return 0; +} - Py_INCREF(st->default_action); - if (PyModule_AddObject(m, "_defaultaction", st->default_action) < 0) { - goto error; - } - return m; +static PyModuleDef_Slot warnings_slots[] = { + {Py_mod_exec, warnings_module_exec}, + {0, NULL} +}; -error: - if (st != NULL) { - warnings_clear_state(st); - } - Py_DECREF(m); - return NULL; +static struct PyModuleDef warnings_module = { + PyModuleDef_HEAD_INIT, + .m_name = MODULE_NAME, + .m_doc = warnings__doc__, + .m_size = 0, + .m_methods = warnings_functions, + .m_slots = warnings_slots, +}; + + +PyMODINIT_FUNC +_PyWarnings_Init(void) +{ + return PyModuleDef_Init(&warnings_module); } // We need this to ensure that warnings still work until late in finalization. diff --git a/contrib/tools/python3/src/Python/asdl.c b/contrib/tools/python3/src/Python/asdl.c index c2110781181..a7f2180c88e 100644 --- a/contrib/tools/python3/src/Python/asdl.c +++ b/contrib/tools/python3/src/Python/asdl.c @@ -1,64 +1,6 @@ #include "Python.h" -#include "asdl.h" +#include "pycore_asdl.h" -asdl_seq * -_Py_asdl_seq_new(Py_ssize_t size, PyArena *arena) -{ - asdl_seq *seq = NULL; - size_t n; - - /* check size is sane */ - if (size < 0 || - (size && (((size_t)size - 1) > (SIZE_MAX / sizeof(void *))))) { - PyErr_NoMemory(); - return NULL; - } - n = (size ? (sizeof(void *) * (size - 1)) : 0); - - /* check if size can be added safely */ - if (n > SIZE_MAX - sizeof(asdl_seq)) { - PyErr_NoMemory(); - return NULL; - } - n += sizeof(asdl_seq); - - seq = (asdl_seq *)PyArena_Malloc(arena, n); - if (!seq) { - PyErr_NoMemory(); - return NULL; - } - memset(seq, 0, n); - seq->size = size; - return seq; -} - -asdl_int_seq * -_Py_asdl_int_seq_new(Py_ssize_t size, PyArena *arena) -{ - asdl_int_seq *seq = NULL; - size_t n; - - /* check size is sane */ - if (size < 0 || - (size && (((size_t)size - 1) > (SIZE_MAX / sizeof(void *))))) { - PyErr_NoMemory(); - return NULL; - } - n = (size ? (sizeof(void *) * (size - 1)) : 0); - - /* check if size can be added safely */ - if (n > SIZE_MAX - sizeof(asdl_seq)) { - PyErr_NoMemory(); - return NULL; - } - n += sizeof(asdl_seq); - - seq = (asdl_int_seq *)PyArena_Malloc(arena, n); - if (!seq) { - PyErr_NoMemory(); - return NULL; - } - memset(seq, 0, n); - seq->size = size; - return seq; -} +GENERATE_ASDL_SEQ_CONSTRUCTOR(generic, void*); +GENERATE_ASDL_SEQ_CONSTRUCTOR(identifier, PyObject*); +GENERATE_ASDL_SEQ_CONSTRUCTOR(int, int); diff --git a/contrib/tools/python3/src/Python/ast.c b/contrib/tools/python3/src/Python/ast.c index 6dd70592631..2113124dbd5 100644 --- a/contrib/tools/python3/src/Python/ast.c +++ b/contrib/tools/python3/src/Python/ast.c @@ -1,25 +1,26 @@ /* - * This file includes functions to transform a concrete syntax tree (CST) to - * an abstract syntax tree (AST). The main function is PyAST_FromNode(). - * + * This file exposes PyAST_Validate interface to check the integrity + * of the given abstract syntax tree (potentially constructed manually). */ #include "Python.h" -#include "Python-ast.h" -#include "node.h" -#include "ast.h" -#include "token.h" -#include "pythonrun.h" +#include "pycore_ast.h" // asdl_stmt_seq +#include "pycore_pystate.h" // _PyThreadState_GET() #include <assert.h> #include <stdbool.h> -#define MAXLEVEL 200 /* Max parentheses level */ +struct validator { + int recursion_depth; /* current recursion depth */ + int recursion_limit; /* recursion limit */ +}; -static int validate_stmts(asdl_seq *); -static int validate_exprs(asdl_seq *, expr_context_ty, int); -static int validate_nonempty_seq(asdl_seq *, const char *, const char *); -static int validate_stmt(stmt_ty); -static int validate_expr(expr_ty, expr_context_ty); +static int validate_stmts(struct validator *, asdl_stmt_seq *); +static int validate_exprs(struct validator *, asdl_expr_seq *, expr_context_ty, int); +static int validate_patterns(struct validator *, asdl_pattern_seq *, int); +static int _validate_nonempty_seq(asdl_seq *, const char *, const char *); +static int validate_stmt(struct validator *, stmt_ty); +static int validate_expr(struct validator *, expr_ty, expr_context_ty); +static int validate_pattern(struct validator *, pattern_ty, int); static int validate_name(PyObject *name) @@ -33,7 +34,7 @@ validate_name(PyObject *name) }; for (int i = 0; forbidden[i] != NULL; i++) { if (_PyUnicode_EqualToASCIIString(name, forbidden[i])) { - PyErr_Format(PyExc_ValueError, "Name node can't be used with '%s' constant", forbidden[i]); + PyErr_Format(PyExc_ValueError, "identifier field can't represent '%s' constant", forbidden[i]); return 0; } } @@ -41,7 +42,7 @@ validate_name(PyObject *name) } static int -validate_comprehension(asdl_seq *gens) +validate_comprehension(struct validator *state, asdl_comprehension_seq *gens) { Py_ssize_t i; if (!asdl_seq_LEN(gens)) { @@ -50,31 +51,31 @@ validate_comprehension(asdl_seq *gens) } for (i = 0; i < asdl_seq_LEN(gens); i++) { comprehension_ty comp = asdl_seq_GET(gens, i); - if (!validate_expr(comp->target, Store) || - !validate_expr(comp->iter, Load) || - !validate_exprs(comp->ifs, Load, 0)) + if (!validate_expr(state, comp->target, Store) || + !validate_expr(state, comp->iter, Load) || + !validate_exprs(state, comp->ifs, Load, 0)) return 0; } return 1; } static int -validate_keywords(asdl_seq *keywords) +validate_keywords(struct validator *state, asdl_keyword_seq *keywords) { Py_ssize_t i; for (i = 0; i < asdl_seq_LEN(keywords); i++) - if (!validate_expr(((keyword_ty)asdl_seq_GET(keywords, i))->value, Load)) + if (!validate_expr(state, (asdl_seq_GET(keywords, i))->value, Load)) return 0; return 1; } static int -validate_args(asdl_seq *args) +validate_args(struct validator *state, asdl_arg_seq *args) { Py_ssize_t i; for (i = 0; i < asdl_seq_LEN(args); i++) { arg_ty arg = asdl_seq_GET(args, i); - if (arg->annotation && !validate_expr(arg->annotation, Load)) + if (arg->annotation && !validate_expr(state, arg->annotation, Load)) return 0; } return 1; @@ -90,25 +91,25 @@ expr_context_name(expr_context_ty ctx) return "Store"; case Del: return "Del"; - default: - Py_UNREACHABLE(); + // No default case so compiler emits warning for unhandled cases } + Py_UNREACHABLE(); } static int -validate_arguments(arguments_ty args) +validate_arguments(struct validator *state, arguments_ty args) { - if (!validate_args(args->posonlyargs) || !validate_args(args->args)) { + if (!validate_args(state, args->posonlyargs) || !validate_args(state, args->args)) { return 0; } if (args->vararg && args->vararg->annotation - && !validate_expr(args->vararg->annotation, Load)) { + && !validate_expr(state, args->vararg->annotation, Load)) { return 0; } - if (!validate_args(args->kwonlyargs)) + if (!validate_args(state, args->kwonlyargs)) return 0; if (args->kwarg && args->kwarg->annotation - && !validate_expr(args->kwarg->annotation, Load)) { + && !validate_expr(state, args->kwarg->annotation, Load)) { return 0; } if (asdl_seq_LEN(args->defaults) > asdl_seq_LEN(args->posonlyargs) + asdl_seq_LEN(args->args)) { @@ -120,11 +121,11 @@ validate_arguments(arguments_ty args) "kw_defaults on arguments"); return 0; } - return validate_exprs(args->defaults, Load, 0) && validate_exprs(args->kw_defaults, Load, 1); + return validate_exprs(state, args->defaults, Load, 0) && validate_exprs(state, args->kw_defaults, Load, 1); } static int -validate_constant(PyObject *value) +validate_constant(struct validator *state, PyObject *value) { if (value == Py_None || value == Py_Ellipsis) return 1; @@ -138,9 +139,13 @@ validate_constant(PyObject *value) return 1; if (PyTuple_CheckExact(value) || PyFrozenSet_CheckExact(value)) { - PyObject *it; + if (++state->recursion_depth > state->recursion_limit) { + PyErr_SetString(PyExc_RecursionError, + "maximum recursion depth exceeded during compilation"); + return 0; + } - it = PyObject_GetIter(value); + PyObject *it = PyObject_GetIter(value); if (it == NULL) return 0; @@ -154,7 +159,7 @@ validate_constant(PyObject *value) break; } - if (!validate_constant(item)) { + if (!validate_constant(state, item)) { Py_DECREF(it); Py_DECREF(item); return 0; @@ -163,6 +168,7 @@ validate_constant(PyObject *value) } Py_DECREF(it); + --state->recursion_depth; return 1; } @@ -175,8 +181,14 @@ validate_constant(PyObject *value) } static int -validate_expr(expr_ty exp, expr_context_ty ctx) +validate_expr(struct validator *state, expr_ty exp, expr_context_ty ctx) { + int ret = -1; + if (++state->recursion_depth > state->recursion_limit) { + PyErr_SetString(PyExc_RecursionError, + "maximum recursion depth exceeded during compilation"); + return 0; + } int check_ctx = 1; expr_context_ty actual_ctx; @@ -226,19 +238,24 @@ validate_expr(expr_ty exp, expr_context_ty ctx) PyErr_SetString(PyExc_ValueError, "BoolOp with less than 2 values"); return 0; } - return validate_exprs(exp->v.BoolOp.values, Load, 0); + ret = validate_exprs(state, exp->v.BoolOp.values, Load, 0); + break; case BinOp_kind: - return validate_expr(exp->v.BinOp.left, Load) && - validate_expr(exp->v.BinOp.right, Load); + ret = validate_expr(state, exp->v.BinOp.left, Load) && + validate_expr(state, exp->v.BinOp.right, Load); + break; case UnaryOp_kind: - return validate_expr(exp->v.UnaryOp.operand, Load); + ret = validate_expr(state, exp->v.UnaryOp.operand, Load); + break; case Lambda_kind: - return validate_arguments(exp->v.Lambda.args) && - validate_expr(exp->v.Lambda.body, Load); + ret = validate_arguments(state, exp->v.Lambda.args) && + validate_expr(state, exp->v.Lambda.body, Load); + break; case IfExp_kind: - return validate_expr(exp->v.IfExp.test, Load) && - validate_expr(exp->v.IfExp.body, Load) && - validate_expr(exp->v.IfExp.orelse, Load); + ret = validate_expr(state, exp->v.IfExp.test, Load) && + validate_expr(state, exp->v.IfExp.body, Load) && + validate_expr(state, exp->v.IfExp.orelse, Load); + break; case Dict_kind: if (asdl_seq_LEN(exp->v.Dict.keys) != asdl_seq_LEN(exp->v.Dict.values)) { PyErr_SetString(PyExc_ValueError, @@ -247,28 +264,35 @@ validate_expr(expr_ty exp, expr_context_ty ctx) } /* null_ok=1 for keys expressions to allow dict unpacking to work in dict literals, i.e. ``{**{a:b}}`` */ - return validate_exprs(exp->v.Dict.keys, Load, /*null_ok=*/ 1) && - validate_exprs(exp->v.Dict.values, Load, /*null_ok=*/ 0); + ret = validate_exprs(state, exp->v.Dict.keys, Load, /*null_ok=*/ 1) && + validate_exprs(state, exp->v.Dict.values, Load, /*null_ok=*/ 0); + break; case Set_kind: - return validate_exprs(exp->v.Set.elts, Load, 0); + ret = validate_exprs(state, exp->v.Set.elts, Load, 0); + break; #define COMP(NAME) \ case NAME ## _kind: \ - return validate_comprehension(exp->v.NAME.generators) && \ - validate_expr(exp->v.NAME.elt, Load); + ret = validate_comprehension(state, exp->v.NAME.generators) && \ + validate_expr(state, exp->v.NAME.elt, Load); \ + break; COMP(ListComp) COMP(SetComp) COMP(GeneratorExp) #undef COMP case DictComp_kind: - return validate_comprehension(exp->v.DictComp.generators) && - validate_expr(exp->v.DictComp.key, Load) && - validate_expr(exp->v.DictComp.value, Load); + ret = validate_comprehension(state, exp->v.DictComp.generators) && + validate_expr(state, exp->v.DictComp.key, Load) && + validate_expr(state, exp->v.DictComp.value, Load); + break; case Yield_kind: - return !exp->v.Yield.value || validate_expr(exp->v.Yield.value, Load); + ret = !exp->v.Yield.value || validate_expr(state, exp->v.Yield.value, Load); + break; case YieldFrom_kind: - return validate_expr(exp->v.YieldFrom.value, Load); + ret = validate_expr(state, exp->v.YieldFrom.value, Load); + break; case Await_kind: - return validate_expr(exp->v.Await.value, Load); + ret = validate_expr(state, exp->v.Await.value, Load); + break; case Compare_kind: if (!asdl_seq_LEN(exp->v.Compare.comparators)) { PyErr_SetString(PyExc_ValueError, "Compare with no comparators"); @@ -280,98 +304,411 @@ validate_expr(expr_ty exp, expr_context_ty ctx) "of comparators and operands"); return 0; } - return validate_exprs(exp->v.Compare.comparators, Load, 0) && - validate_expr(exp->v.Compare.left, Load); + ret = validate_exprs(state, exp->v.Compare.comparators, Load, 0) && + validate_expr(state, exp->v.Compare.left, Load); + break; case Call_kind: - return validate_expr(exp->v.Call.func, Load) && - validate_exprs(exp->v.Call.args, Load, 0) && - validate_keywords(exp->v.Call.keywords); + ret = validate_expr(state, exp->v.Call.func, Load) && + validate_exprs(state, exp->v.Call.args, Load, 0) && + validate_keywords(state, exp->v.Call.keywords); + break; case Constant_kind: - if (!validate_constant(exp->v.Constant.value)) { + if (!validate_constant(state, exp->v.Constant.value)) { return 0; } - return 1; + ret = 1; + break; case JoinedStr_kind: - return validate_exprs(exp->v.JoinedStr.values, Load, 0); + ret = validate_exprs(state, exp->v.JoinedStr.values, Load, 0); + break; case FormattedValue_kind: - if (validate_expr(exp->v.FormattedValue.value, Load) == 0) + if (validate_expr(state, exp->v.FormattedValue.value, Load) == 0) return 0; - if (exp->v.FormattedValue.format_spec) - return validate_expr(exp->v.FormattedValue.format_spec, Load); - return 1; + if (exp->v.FormattedValue.format_spec) { + ret = validate_expr(state, exp->v.FormattedValue.format_spec, Load); + break; + } + ret = 1; + break; case Attribute_kind: - return validate_expr(exp->v.Attribute.value, Load); + ret = validate_expr(state, exp->v.Attribute.value, Load); + break; case Subscript_kind: - return validate_expr(exp->v.Subscript.slice, Load) && - validate_expr(exp->v.Subscript.value, Load); + ret = validate_expr(state, exp->v.Subscript.slice, Load) && + validate_expr(state, exp->v.Subscript.value, Load); + break; case Starred_kind: - return validate_expr(exp->v.Starred.value, ctx); + ret = validate_expr(state, exp->v.Starred.value, ctx); + break; case Slice_kind: - return (!exp->v.Slice.lower || validate_expr(exp->v.Slice.lower, Load)) && - (!exp->v.Slice.upper || validate_expr(exp->v.Slice.upper, Load)) && - (!exp->v.Slice.step || validate_expr(exp->v.Slice.step, Load)); + ret = (!exp->v.Slice.lower || validate_expr(state, exp->v.Slice.lower, Load)) && + (!exp->v.Slice.upper || validate_expr(state, exp->v.Slice.upper, Load)) && + (!exp->v.Slice.step || validate_expr(state, exp->v.Slice.step, Load)); + break; case List_kind: - return validate_exprs(exp->v.List.elts, ctx, 0); + ret = validate_exprs(state, exp->v.List.elts, ctx, 0); + break; case Tuple_kind: - return validate_exprs(exp->v.Tuple.elts, ctx, 0); + ret = validate_exprs(state, exp->v.Tuple.elts, ctx, 0); + break; case NamedExpr_kind: - return validate_expr(exp->v.NamedExpr.value, Load); + ret = validate_expr(state, exp->v.NamedExpr.value, Load); + break; /* This last case doesn't have any checking. */ case Name_kind: - return 1; + ret = 1; + break; + // No default case so compiler emits warning for unhandled cases + } + if (ret < 0) { + PyErr_SetString(PyExc_SystemError, "unexpected expression"); + ret = 0; + } + state->recursion_depth--; + return ret; +} + + +// Note: the ensure_literal_* functions are only used to validate a restricted +// set of non-recursive literals that have already been checked with +// validate_expr, so they don't accept the validator state +static int +ensure_literal_number(expr_ty exp, bool allow_real, bool allow_imaginary) +{ + assert(exp->kind == Constant_kind); + PyObject *value = exp->v.Constant.value; + return (allow_real && PyFloat_CheckExact(value)) || + (allow_real && PyLong_CheckExact(value)) || + (allow_imaginary && PyComplex_CheckExact(value)); +} + +static int +ensure_literal_negative(expr_ty exp, bool allow_real, bool allow_imaginary) +{ + assert(exp->kind == UnaryOp_kind); + // Must be negation ... + if (exp->v.UnaryOp.op != USub) { + return 0; + } + // ... of a constant ... + expr_ty operand = exp->v.UnaryOp.operand; + if (operand->kind != Constant_kind) { + return 0; + } + // ... number + return ensure_literal_number(operand, allow_real, allow_imaginary); +} + +static int +ensure_literal_complex(expr_ty exp) +{ + assert(exp->kind == BinOp_kind); + expr_ty left = exp->v.BinOp.left; + expr_ty right = exp->v.BinOp.right; + // Ensure op is addition or subtraction + if (exp->v.BinOp.op != Add && exp->v.BinOp.op != Sub) { + return 0; + } + // Check LHS is a real number (potentially signed) + switch (left->kind) + { + case Constant_kind: + if (!ensure_literal_number(left, /*real=*/true, /*imaginary=*/false)) { + return 0; + } + break; + case UnaryOp_kind: + if (!ensure_literal_negative(left, /*real=*/true, /*imaginary=*/false)) { + return 0; + } + break; + default: + return 0; + } + // Check RHS is an imaginary number (no separate sign allowed) + switch (right->kind) + { + case Constant_kind: + if (!ensure_literal_number(right, /*real=*/false, /*imaginary=*/true)) { + return 0; + } + break; + default: + return 0; + } + return 1; +} + +static int +validate_pattern_match_value(struct validator *state, expr_ty exp) +{ + if (!validate_expr(state, exp, Load)) { + return 0; + } + + switch (exp->kind) + { + case Constant_kind: + /* Ellipsis and immutable sequences are not allowed. + For True, False and None, MatchSingleton() should + be used */ + if (!validate_expr(state, exp, Load)) { + return 0; + } + PyObject *literal = exp->v.Constant.value; + if (PyLong_CheckExact(literal) || PyFloat_CheckExact(literal) || + PyBytes_CheckExact(literal) || PyComplex_CheckExact(literal) || + PyUnicode_CheckExact(literal)) { + return 1; + } + PyErr_SetString(PyExc_ValueError, + "unexpected constant inside of a literal pattern"); + return 0; + case Attribute_kind: + // Constants and attribute lookups are always permitted + return 1; + case UnaryOp_kind: + // Negated numbers are permitted (whether real or imaginary) + // Compiler will complain if AST folding doesn't create a constant + if (ensure_literal_negative(exp, /*real=*/true, /*imaginary=*/true)) { + return 1; + } + break; + case BinOp_kind: + // Complex literals are permitted + // Compiler will complain if AST folding doesn't create a constant + if (ensure_literal_complex(exp)) { + return 1; + } + break; + case JoinedStr_kind: + // Handled in the later stages + return 1; + default: + break; } - PyErr_SetString(PyExc_SystemError, "unexpected expression"); + PyErr_SetString(PyExc_ValueError, + "patterns may only match literals and attribute lookups"); return 0; } static int -validate_nonempty_seq(asdl_seq *seq, const char *what, const char *owner) +validate_capture(PyObject *name) +{ + if (_PyUnicode_EqualToASCIIString(name, "_")) { + PyErr_Format(PyExc_ValueError, "can't capture name '_' in patterns"); + return 0; + } + return validate_name(name); +} + +static int +validate_pattern(struct validator *state, pattern_ty p, int star_ok) +{ + int ret = -1; + if (++state->recursion_depth > state->recursion_limit) { + PyErr_SetString(PyExc_RecursionError, + "maximum recursion depth exceeded during compilation"); + return 0; + } + switch (p->kind) { + case MatchValue_kind: + ret = validate_pattern_match_value(state, p->v.MatchValue.value); + break; + case MatchSingleton_kind: + ret = p->v.MatchSingleton.value == Py_None || PyBool_Check(p->v.MatchSingleton.value); + if (!ret) { + PyErr_SetString(PyExc_ValueError, + "MatchSingleton can only contain True, False and None"); + } + break; + case MatchSequence_kind: + ret = validate_patterns(state, p->v.MatchSequence.patterns, /*star_ok=*/1); + break; + case MatchMapping_kind: + if (asdl_seq_LEN(p->v.MatchMapping.keys) != asdl_seq_LEN(p->v.MatchMapping.patterns)) { + PyErr_SetString(PyExc_ValueError, + "MatchMapping doesn't have the same number of keys as patterns"); + ret = 0; + break; + } + + if (p->v.MatchMapping.rest && !validate_capture(p->v.MatchMapping.rest)) { + ret = 0; + break; + } + + asdl_expr_seq *keys = p->v.MatchMapping.keys; + for (Py_ssize_t i = 0; i < asdl_seq_LEN(keys); i++) { + expr_ty key = asdl_seq_GET(keys, i); + if (key->kind == Constant_kind) { + PyObject *literal = key->v.Constant.value; + if (literal == Py_None || PyBool_Check(literal)) { + /* validate_pattern_match_value will ensure the key + doesn't contain True, False and None but it is + syntactically valid, so we will pass those on in + a special case. */ + continue; + } + } + if (!validate_pattern_match_value(state, key)) { + ret = 0; + break; + } + } + + ret = validate_patterns(state, p->v.MatchMapping.patterns, /*star_ok=*/0); + break; + case MatchClass_kind: + if (asdl_seq_LEN(p->v.MatchClass.kwd_attrs) != asdl_seq_LEN(p->v.MatchClass.kwd_patterns)) { + PyErr_SetString(PyExc_ValueError, + "MatchClass doesn't have the same number of keyword attributes as patterns"); + ret = 0; + break; + } + if (!validate_expr(state, p->v.MatchClass.cls, Load)) { + ret = 0; + break; + } + + expr_ty cls = p->v.MatchClass.cls; + while (1) { + if (cls->kind == Name_kind) { + break; + } + else if (cls->kind == Attribute_kind) { + cls = cls->v.Attribute.value; + continue; + } + else { + PyErr_SetString(PyExc_ValueError, + "MatchClass cls field can only contain Name or Attribute nodes."); + ret = 0; + break; + } + } + + for (Py_ssize_t i = 0; i < asdl_seq_LEN(p->v.MatchClass.kwd_attrs); i++) { + PyObject *identifier = asdl_seq_GET(p->v.MatchClass.kwd_attrs, i); + if (!validate_name(identifier)) { + ret = 0; + break; + } + } + + if (!validate_patterns(state, p->v.MatchClass.patterns, /*star_ok=*/0)) { + ret = 0; + break; + } + + ret = validate_patterns(state, p->v.MatchClass.kwd_patterns, /*star_ok=*/0); + break; + case MatchStar_kind: + if (!star_ok) { + PyErr_SetString(PyExc_ValueError, "can't use MatchStar here"); + ret = 0; + break; + } + ret = p->v.MatchStar.name == NULL || validate_capture(p->v.MatchStar.name); + break; + case MatchAs_kind: + if (p->v.MatchAs.name && !validate_capture(p->v.MatchAs.name)) { + ret = 0; + break; + } + if (p->v.MatchAs.pattern == NULL) { + ret = 1; + } + else if (p->v.MatchAs.name == NULL) { + PyErr_SetString(PyExc_ValueError, + "MatchAs must specify a target name if a pattern is given"); + ret = 0; + } + else { + ret = validate_pattern(state, p->v.MatchAs.pattern, /*star_ok=*/0); + } + break; + case MatchOr_kind: + if (asdl_seq_LEN(p->v.MatchOr.patterns) < 2) { + PyErr_SetString(PyExc_ValueError, + "MatchOr requires at least 2 patterns"); + ret = 0; + break; + } + ret = validate_patterns(state, p->v.MatchOr.patterns, /*star_ok=*/0); + break; + // No default case, so the compiler will emit a warning if new pattern + // kinds are added without being handled here + } + if (ret < 0) { + PyErr_SetString(PyExc_SystemError, "unexpected pattern"); + ret = 0; + } + state->recursion_depth--; + return ret; +} + +static int +_validate_nonempty_seq(asdl_seq *seq, const char *what, const char *owner) { if (asdl_seq_LEN(seq)) return 1; PyErr_Format(PyExc_ValueError, "empty %s on %s", what, owner); return 0; } +#define validate_nonempty_seq(seq, what, owner) _validate_nonempty_seq((asdl_seq*)seq, what, owner) static int -validate_assignlist(asdl_seq *targets, expr_context_ty ctx) +validate_assignlist(struct validator *state, asdl_expr_seq *targets, expr_context_ty ctx) { return validate_nonempty_seq(targets, "targets", ctx == Del ? "Delete" : "Assign") && - validate_exprs(targets, ctx, 0); + validate_exprs(state, targets, ctx, 0); } static int -validate_body(asdl_seq *body, const char *owner) +validate_body(struct validator *state, asdl_stmt_seq *body, const char *owner) { - return validate_nonempty_seq(body, "body", owner) && validate_stmts(body); + return validate_nonempty_seq(body, "body", owner) && validate_stmts(state, body); } static int -validate_stmt(stmt_ty stmt) +validate_stmt(struct validator *state, stmt_ty stmt) { + int ret = -1; Py_ssize_t i; + if (++state->recursion_depth > state->recursion_limit) { + PyErr_SetString(PyExc_RecursionError, + "maximum recursion depth exceeded during compilation"); + return 0; + } switch (stmt->kind) { case FunctionDef_kind: - return validate_body(stmt->v.FunctionDef.body, "FunctionDef") && - validate_arguments(stmt->v.FunctionDef.args) && - validate_exprs(stmt->v.FunctionDef.decorator_list, Load, 0) && + ret = validate_body(state, stmt->v.FunctionDef.body, "FunctionDef") && + validate_arguments(state, stmt->v.FunctionDef.args) && + validate_exprs(state, stmt->v.FunctionDef.decorator_list, Load, 0) && (!stmt->v.FunctionDef.returns || - validate_expr(stmt->v.FunctionDef.returns, Load)); + validate_expr(state, stmt->v.FunctionDef.returns, Load)); + break; case ClassDef_kind: - return validate_body(stmt->v.ClassDef.body, "ClassDef") && - validate_exprs(stmt->v.ClassDef.bases, Load, 0) && - validate_keywords(stmt->v.ClassDef.keywords) && - validate_exprs(stmt->v.ClassDef.decorator_list, Load, 0); + ret = validate_body(state, stmt->v.ClassDef.body, "ClassDef") && + validate_exprs(state, stmt->v.ClassDef.bases, Load, 0) && + validate_keywords(state, stmt->v.ClassDef.keywords) && + validate_exprs(state, stmt->v.ClassDef.decorator_list, Load, 0); + break; case Return_kind: - return !stmt->v.Return.value || validate_expr(stmt->v.Return.value, Load); + ret = !stmt->v.Return.value || validate_expr(state, stmt->v.Return.value, Load); + break; case Delete_kind: - return validate_assignlist(stmt->v.Delete.targets, Del); + ret = validate_assignlist(state, stmt->v.Delete.targets, Del); + break; case Assign_kind: - return validate_assignlist(stmt->v.Assign.targets, Store) && - validate_expr(stmt->v.Assign.value, Load); + ret = validate_assignlist(state, stmt->v.Assign.targets, Store) && + validate_expr(state, stmt->v.Assign.value, Load); + break; case AugAssign_kind: - return validate_expr(stmt->v.AugAssign.target, Store) && - validate_expr(stmt->v.AugAssign.value, Load); + ret = validate_expr(state, stmt->v.AugAssign.target, Store) && + validate_expr(state, stmt->v.AugAssign.value, Load); + break; case AnnAssign_kind: if (stmt->v.AnnAssign.target->kind != Name_kind && stmt->v.AnnAssign.simple) { @@ -379,60 +716,84 @@ validate_stmt(stmt_ty stmt) "AnnAssign with simple non-Name target"); return 0; } - return validate_expr(stmt->v.AnnAssign.target, Store) && + ret = validate_expr(state, stmt->v.AnnAssign.target, Store) && (!stmt->v.AnnAssign.value || - validate_expr(stmt->v.AnnAssign.value, Load)) && - validate_expr(stmt->v.AnnAssign.annotation, Load); + validate_expr(state, stmt->v.AnnAssign.value, Load)) && + validate_expr(state, stmt->v.AnnAssign.annotation, Load); + break; case For_kind: - return validate_expr(stmt->v.For.target, Store) && - validate_expr(stmt->v.For.iter, Load) && - validate_body(stmt->v.For.body, "For") && - validate_stmts(stmt->v.For.orelse); + ret = validate_expr(state, stmt->v.For.target, Store) && + validate_expr(state, stmt->v.For.iter, Load) && + validate_body(state, stmt->v.For.body, "For") && + validate_stmts(state, stmt->v.For.orelse); + break; case AsyncFor_kind: - return validate_expr(stmt->v.AsyncFor.target, Store) && - validate_expr(stmt->v.AsyncFor.iter, Load) && - validate_body(stmt->v.AsyncFor.body, "AsyncFor") && - validate_stmts(stmt->v.AsyncFor.orelse); + ret = validate_expr(state, stmt->v.AsyncFor.target, Store) && + validate_expr(state, stmt->v.AsyncFor.iter, Load) && + validate_body(state, stmt->v.AsyncFor.body, "AsyncFor") && + validate_stmts(state, stmt->v.AsyncFor.orelse); + break; case While_kind: - return validate_expr(stmt->v.While.test, Load) && - validate_body(stmt->v.While.body, "While") && - validate_stmts(stmt->v.While.orelse); + ret = validate_expr(state, stmt->v.While.test, Load) && + validate_body(state, stmt->v.While.body, "While") && + validate_stmts(state, stmt->v.While.orelse); + break; case If_kind: - return validate_expr(stmt->v.If.test, Load) && - validate_body(stmt->v.If.body, "If") && - validate_stmts(stmt->v.If.orelse); + ret = validate_expr(state, stmt->v.If.test, Load) && + validate_body(state, stmt->v.If.body, "If") && + validate_stmts(state, stmt->v.If.orelse); + break; case With_kind: if (!validate_nonempty_seq(stmt->v.With.items, "items", "With")) return 0; for (i = 0; i < asdl_seq_LEN(stmt->v.With.items); i++) { withitem_ty item = asdl_seq_GET(stmt->v.With.items, i); - if (!validate_expr(item->context_expr, Load) || - (item->optional_vars && !validate_expr(item->optional_vars, Store))) + if (!validate_expr(state, item->context_expr, Load) || + (item->optional_vars && !validate_expr(state, item->optional_vars, Store))) return 0; } - return validate_body(stmt->v.With.body, "With"); + ret = validate_body(state, stmt->v.With.body, "With"); + break; case AsyncWith_kind: if (!validate_nonempty_seq(stmt->v.AsyncWith.items, "items", "AsyncWith")) return 0; for (i = 0; i < asdl_seq_LEN(stmt->v.AsyncWith.items); i++) { withitem_ty item = asdl_seq_GET(stmt->v.AsyncWith.items, i); - if (!validate_expr(item->context_expr, Load) || - (item->optional_vars && !validate_expr(item->optional_vars, Store))) + if (!validate_expr(state, item->context_expr, Load) || + (item->optional_vars && !validate_expr(state, item->optional_vars, Store))) + return 0; + } + ret = validate_body(state, stmt->v.AsyncWith.body, "AsyncWith"); + break; + case Match_kind: + if (!validate_expr(state, stmt->v.Match.subject, Load) + || !validate_nonempty_seq(stmt->v.Match.cases, "cases", "Match")) { + return 0; + } + for (i = 0; i < asdl_seq_LEN(stmt->v.Match.cases); i++) { + match_case_ty m = asdl_seq_GET(stmt->v.Match.cases, i); + if (!validate_pattern(state, m->pattern, /*star_ok=*/0) + || (m->guard && !validate_expr(state, m->guard, Load)) + || !validate_body(state, m->body, "match_case")) { return 0; + } } - return validate_body(stmt->v.AsyncWith.body, "AsyncWith"); + ret = 1; + break; case Raise_kind: if (stmt->v.Raise.exc) { - return validate_expr(stmt->v.Raise.exc, Load) && - (!stmt->v.Raise.cause || validate_expr(stmt->v.Raise.cause, Load)); + ret = validate_expr(state, stmt->v.Raise.exc, Load) && + (!stmt->v.Raise.cause || validate_expr(state, stmt->v.Raise.cause, Load)); + break; } if (stmt->v.Raise.cause) { PyErr_SetString(PyExc_ValueError, "Raise with cause but no exception"); return 0; } - return 1; + ret = 1; + break; case Try_kind: - if (!validate_body(stmt->v.Try.body, "Try")) + if (!validate_body(state, stmt->v.Try.body, "Try")) return 0; if (!asdl_seq_LEN(stmt->v.Try.handlers) && !asdl_seq_LEN(stmt->v.Try.finalbody)) { @@ -447,55 +808,68 @@ validate_stmt(stmt_ty stmt) for (i = 0; i < asdl_seq_LEN(stmt->v.Try.handlers); i++) { excepthandler_ty handler = asdl_seq_GET(stmt->v.Try.handlers, i); if ((handler->v.ExceptHandler.type && - !validate_expr(handler->v.ExceptHandler.type, Load)) || - !validate_body(handler->v.ExceptHandler.body, "ExceptHandler")) + !validate_expr(state, handler->v.ExceptHandler.type, Load)) || + !validate_body(state, handler->v.ExceptHandler.body, "ExceptHandler")) return 0; } - return (!asdl_seq_LEN(stmt->v.Try.finalbody) || - validate_stmts(stmt->v.Try.finalbody)) && + ret = (!asdl_seq_LEN(stmt->v.Try.finalbody) || + validate_stmts(state, stmt->v.Try.finalbody)) && (!asdl_seq_LEN(stmt->v.Try.orelse) || - validate_stmts(stmt->v.Try.orelse)); + validate_stmts(state, stmt->v.Try.orelse)); + break; case Assert_kind: - return validate_expr(stmt->v.Assert.test, Load) && - (!stmt->v.Assert.msg || validate_expr(stmt->v.Assert.msg, Load)); + ret = validate_expr(state, stmt->v.Assert.test, Load) && + (!stmt->v.Assert.msg || validate_expr(state, stmt->v.Assert.msg, Load)); + break; case Import_kind: - return validate_nonempty_seq(stmt->v.Import.names, "names", "Import"); + ret = validate_nonempty_seq(stmt->v.Import.names, "names", "Import"); + break; case ImportFrom_kind: if (stmt->v.ImportFrom.level < 0) { PyErr_SetString(PyExc_ValueError, "Negative ImportFrom level"); return 0; } - return validate_nonempty_seq(stmt->v.ImportFrom.names, "names", "ImportFrom"); + ret = validate_nonempty_seq(stmt->v.ImportFrom.names, "names", "ImportFrom"); + break; case Global_kind: - return validate_nonempty_seq(stmt->v.Global.names, "names", "Global"); + ret = validate_nonempty_seq(stmt->v.Global.names, "names", "Global"); + break; case Nonlocal_kind: - return validate_nonempty_seq(stmt->v.Nonlocal.names, "names", "Nonlocal"); + ret = validate_nonempty_seq(stmt->v.Nonlocal.names, "names", "Nonlocal"); + break; case Expr_kind: - return validate_expr(stmt->v.Expr.value, Load); + ret = validate_expr(state, stmt->v.Expr.value, Load); + break; case AsyncFunctionDef_kind: - return validate_body(stmt->v.AsyncFunctionDef.body, "AsyncFunctionDef") && - validate_arguments(stmt->v.AsyncFunctionDef.args) && - validate_exprs(stmt->v.AsyncFunctionDef.decorator_list, Load, 0) && + ret = validate_body(state, stmt->v.AsyncFunctionDef.body, "AsyncFunctionDef") && + validate_arguments(state, stmt->v.AsyncFunctionDef.args) && + validate_exprs(state, stmt->v.AsyncFunctionDef.decorator_list, Load, 0) && (!stmt->v.AsyncFunctionDef.returns || - validate_expr(stmt->v.AsyncFunctionDef.returns, Load)); + validate_expr(state, stmt->v.AsyncFunctionDef.returns, Load)); + break; case Pass_kind: case Break_kind: case Continue_kind: - return 1; - default: + ret = 1; + break; + // No default case so compiler emits warning for unhandled cases + } + if (ret < 0) { PyErr_SetString(PyExc_SystemError, "unexpected statement"); - return 0; + ret = 0; } + state->recursion_depth--; + return ret; } static int -validate_stmts(asdl_seq *seq) +validate_stmts(struct validator *state, asdl_stmt_seq *seq) { Py_ssize_t i; for (i = 0; i < asdl_seq_LEN(seq); i++) { stmt_ty stmt = asdl_seq_GET(seq, i); if (stmt) { - if (!validate_stmt(stmt)) + if (!validate_stmt(state, stmt)) return 0; } else { @@ -508,13 +882,13 @@ validate_stmts(asdl_seq *seq) } static int -validate_exprs(asdl_seq *exprs, expr_context_ty ctx, int null_ok) +validate_exprs(struct validator *state, asdl_expr_seq *exprs, expr_context_ty ctx, int null_ok) { Py_ssize_t i; for (i = 0; i < asdl_seq_LEN(exprs); i++) { expr_ty expr = asdl_seq_GET(exprs, i); if (expr) { - if (!validate_expr(expr, ctx)) + if (!validate_expr(state, expr, ctx)) return 0; } else if (!null_ok) { @@ -527,5326 +901,83 @@ validate_exprs(asdl_seq *exprs, expr_context_ty ctx, int null_ok) return 1; } -int -PyAST_Validate(mod_ty mod) -{ - int res = 0; - - switch (mod->kind) { - case Module_kind: - res = validate_stmts(mod->v.Module.body); - break; - case Interactive_kind: - res = validate_stmts(mod->v.Interactive.body); - break; - case Expression_kind: - res = validate_expr(mod->v.Expression.body, Load); - break; - default: - PyErr_SetString(PyExc_SystemError, "impossible module node"); - res = 0; - break; - } - return res; -} - -/* This is done here, so defines like "test" don't interfere with AST use above. */ -#include "grammar.h" -#include "parsetok.h" -#include "graminit.h" - -/* Data structure used internally */ -struct compiling { - PyArena *c_arena; /* Arena for allocating memory. */ - PyObject *c_filename; /* filename */ - PyObject *c_normalize; /* Normalization function from unicodedata. */ - int c_feature_version; /* Latest minor version of Python for allowed features */ -}; - -static asdl_seq *seq_for_testlist(struct compiling *, const node *); -static expr_ty ast_for_expr(struct compiling *, const node *); -static stmt_ty ast_for_stmt(struct compiling *, const node *); -static asdl_seq *ast_for_suite(struct compiling *c, const node *n); -static asdl_seq *ast_for_exprlist(struct compiling *, const node *, - expr_context_ty); -static expr_ty ast_for_testlist(struct compiling *, const node *); -static stmt_ty ast_for_classdef(struct compiling *, const node *, asdl_seq *); - -static stmt_ty ast_for_with_stmt(struct compiling *, const node *, bool); -static stmt_ty ast_for_for_stmt(struct compiling *, const node *, bool); - -/* Note different signature for ast_for_call */ -static expr_ty ast_for_call(struct compiling *, const node *, expr_ty, - const node *, const node *, const node *); - -static PyObject *parsenumber(struct compiling *, const char *); -static expr_ty parsestrplus(struct compiling *, const node *n); -static void get_last_end_pos(asdl_seq *, int *, int *); - -#define COMP_GENEXP 0 -#define COMP_LISTCOMP 1 -#define COMP_SETCOMP 2 - -static int -init_normalization(struct compiling *c) -{ - PyObject *m = PyImport_ImportModuleNoBlock("unicodedata"); - if (!m) - return 0; - c->c_normalize = PyObject_GetAttrString(m, "normalize"); - Py_DECREF(m); - if (!c->c_normalize) - return 0; - return 1; -} - -static identifier -new_identifier(const char *n, struct compiling *c) -{ - PyObject *id = PyUnicode_DecodeUTF8(n, strlen(n), NULL); - if (!id) - return NULL; - /* PyUnicode_DecodeUTF8 should always return a ready string. */ - assert(PyUnicode_IS_READY(id)); - /* Check whether there are non-ASCII characters in the - identifier; if so, normalize to NFKC. */ - if (!PyUnicode_IS_ASCII(id)) { - PyObject *id2; - if (!c->c_normalize && !init_normalization(c)) { - Py_DECREF(id); - return NULL; - } - PyObject *form = PyUnicode_InternFromString("NFKC"); - if (form == NULL) { - Py_DECREF(id); - return NULL; - } - PyObject *args[2] = {form, id}; - id2 = _PyObject_FastCall(c->c_normalize, args, 2); - Py_DECREF(id); - Py_DECREF(form); - if (!id2) - return NULL; - if (!PyUnicode_Check(id2)) { - PyErr_Format(PyExc_TypeError, - "unicodedata.normalize() must return a string, not " - "%.200s", - _PyType_Name(Py_TYPE(id2))); - Py_DECREF(id2); - return NULL; - } - id = id2; - } - PyUnicode_InternInPlace(&id); - if (PyArena_AddPyObject(c->c_arena, id) < 0) { - Py_DECREF(id); - return NULL; - } - return id; -} - -#define NEW_IDENTIFIER(n) new_identifier(STR(n), c) - static int -ast_error(struct compiling *c, const node *n, const char *errmsg, ...) +validate_patterns(struct validator *state, asdl_pattern_seq *patterns, int star_ok) { - PyObject *value, *errstr, *loc, *tmp; - va_list va; - - va_start(va, errmsg); - errstr = PyUnicode_FromFormatV(errmsg, va); - va_end(va); - if (!errstr) { - return 0; - } - loc = PyErr_ProgramTextObject(c->c_filename, LINENO(n)); - if (!loc) { - Py_INCREF(Py_None); - loc = Py_None; - } - tmp = Py_BuildValue("(OiiN)", c->c_filename, LINENO(n), n->n_col_offset + 1, loc); - if (!tmp) { - Py_DECREF(errstr); - return 0; - } - value = PyTuple_Pack(2, errstr, tmp); - Py_DECREF(errstr); - Py_DECREF(tmp); - if (value) { - PyErr_SetObject(PyExc_SyntaxError, value); - Py_DECREF(value); - } - return 0; -} - -/* num_stmts() returns number of contained statements. - - Use this routine to determine how big a sequence is needed for - the statements in a parse tree. Its raison d'etre is this bit of - grammar: - - stmt: simple_stmt | compound_stmt - simple_stmt: small_stmt (';' small_stmt)* [';'] NEWLINE - - A simple_stmt can contain multiple small_stmt elements joined - by semicolons. If the arg is a simple_stmt, the number of - small_stmt elements is returned. -*/ - -static string -new_type_comment(const char *s, struct compiling *c) -{ - PyObject *res = PyUnicode_DecodeUTF8(s, strlen(s), NULL); - if (res == NULL) - return NULL; - if (PyArena_AddPyObject(c->c_arena, res) < 0) { - Py_DECREF(res); - return NULL; - } - return res; -} -#define NEW_TYPE_COMMENT(n) new_type_comment(STR(n), c) - -static int -num_stmts(const node *n) -{ - int i, l; - node *ch; - - switch (TYPE(n)) { - case single_input: - if (TYPE(CHILD(n, 0)) == NEWLINE) - return 0; - else - return num_stmts(CHILD(n, 0)); - case file_input: - l = 0; - for (i = 0; i < NCH(n); i++) { - ch = CHILD(n, i); - if (TYPE(ch) == stmt) - l += num_stmts(ch); - } - return l; - case stmt: - return num_stmts(CHILD(n, 0)); - case compound_stmt: - return 1; - case simple_stmt: - return NCH(n) / 2; /* Divide by 2 to remove count of semi-colons */ - case suite: - case func_body_suite: - /* func_body_suite: simple_stmt | NEWLINE [TYPE_COMMENT NEWLINE] INDENT stmt+ DEDENT */ - /* suite: simple_stmt | NEWLINE INDENT stmt+ DEDENT */ - if (NCH(n) == 1) - return num_stmts(CHILD(n, 0)); - else { - i = 2; - l = 0; - if (TYPE(CHILD(n, 1)) == TYPE_COMMENT) - i += 2; - for (; i < (NCH(n) - 1); i++) - l += num_stmts(CHILD(n, i)); - return l; - } - default: { - _Py_FatalErrorFormat(__func__, "Non-statement found: %d %d", - TYPE(n), NCH(n)); - } - } - Py_UNREACHABLE(); -} - -/* Transform the CST rooted at node * to the appropriate AST -*/ - -mod_ty -PyAST_FromNodeObject(const node *n, PyCompilerFlags *flags, - PyObject *filename, PyArena *arena) -{ - int i, j, k, num; - asdl_seq *stmts = NULL; - asdl_seq *type_ignores = NULL; - stmt_ty s; - node *ch; - struct compiling c; - mod_ty res = NULL; - asdl_seq *argtypes = NULL; - expr_ty ret, arg; - - c.c_arena = arena; - /* borrowed reference */ - c.c_filename = filename; - c.c_normalize = NULL; - c.c_feature_version = flags && (flags->cf_flags & PyCF_ONLY_AST) ? - flags->cf_feature_version : PY_MINOR_VERSION; - - if (TYPE(n) == encoding_decl) - n = CHILD(n, 0); - - k = 0; - switch (TYPE(n)) { - case file_input: - stmts = _Py_asdl_seq_new(num_stmts(n), arena); - if (!stmts) - goto out; - for (i = 0; i < NCH(n) - 1; i++) { - ch = CHILD(n, i); - if (TYPE(ch) == NEWLINE) - continue; - REQ(ch, stmt); - num = num_stmts(ch); - if (num == 1) { - s = ast_for_stmt(&c, ch); - if (!s) - goto out; - asdl_seq_SET(stmts, k++, s); - } - else { - ch = CHILD(ch, 0); - REQ(ch, simple_stmt); - for (j = 0; j < num; j++) { - s = ast_for_stmt(&c, CHILD(ch, j * 2)); - if (!s) - goto out; - asdl_seq_SET(stmts, k++, s); - } - } - } - - /* Type ignores are stored under the ENDMARKER in file_input. */ - ch = CHILD(n, NCH(n) - 1); - REQ(ch, ENDMARKER); - num = NCH(ch); - type_ignores = _Py_asdl_seq_new(num, arena); - if (!type_ignores) - goto out; - - for (i = 0; i < num; i++) { - string type_comment = new_type_comment(STR(CHILD(ch, i)), &c); - if (!type_comment) - goto out; - type_ignore_ty ti = TypeIgnore(LINENO(CHILD(ch, i)), type_comment, arena); - if (!ti) - goto out; - asdl_seq_SET(type_ignores, i, ti); - } - - res = Module(stmts, type_ignores, arena); - break; - case eval_input: { - expr_ty testlist_ast; - - /* XXX Why not comp_for here? */ - testlist_ast = ast_for_testlist(&c, CHILD(n, 0)); - if (!testlist_ast) - goto out; - res = Expression(testlist_ast, arena); - break; - } - case single_input: - if (TYPE(CHILD(n, 0)) == NEWLINE) { - stmts = _Py_asdl_seq_new(1, arena); - if (!stmts) - goto out; - asdl_seq_SET(stmts, 0, Pass(n->n_lineno, n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, - arena)); - if (!asdl_seq_GET(stmts, 0)) - goto out; - res = Interactive(stmts, arena); - } - else { - n = CHILD(n, 0); - num = num_stmts(n); - stmts = _Py_asdl_seq_new(num, arena); - if (!stmts) - goto out; - if (num == 1) { - s = ast_for_stmt(&c, n); - if (!s) - goto out; - asdl_seq_SET(stmts, 0, s); - } - else { - /* Only a simple_stmt can contain multiple statements. */ - REQ(n, simple_stmt); - for (i = 0; i < NCH(n); i += 2) { - if (TYPE(CHILD(n, i)) == NEWLINE) - break; - s = ast_for_stmt(&c, CHILD(n, i)); - if (!s) - goto out; - asdl_seq_SET(stmts, i / 2, s); - } - } - - res = Interactive(stmts, arena); - } - break; - case func_type_input: - n = CHILD(n, 0); - REQ(n, func_type); - - if (TYPE(CHILD(n, 1)) == typelist) { - ch = CHILD(n, 1); - /* this is overly permissive -- we don't pay any attention to - * stars on the args -- just parse them into an ordered list */ - num = 0; - for (i = 0; i < NCH(ch); i++) { - if (TYPE(CHILD(ch, i)) == test) { - num++; - } - } - - argtypes = _Py_asdl_seq_new(num, arena); - if (!argtypes) - goto out; - - j = 0; - for (i = 0; i < NCH(ch); i++) { - if (TYPE(CHILD(ch, i)) == test) { - arg = ast_for_expr(&c, CHILD(ch, i)); - if (!arg) - goto out; - asdl_seq_SET(argtypes, j++, arg); - } - } - } - else { - argtypes = _Py_asdl_seq_new(0, arena); - if (!argtypes) - goto out; - } - - ret = ast_for_expr(&c, CHILD(n, NCH(n) - 1)); - if (!ret) - goto out; - res = FunctionType(argtypes, ret, arena); - break; - default: - PyErr_Format(PyExc_SystemError, - "invalid node %d for PyAST_FromNode", TYPE(n)); - goto out; - } - out: - if (c.c_normalize) { - Py_DECREF(c.c_normalize); - } - return res; -} - -mod_ty -PyAST_FromNode(const node *n, PyCompilerFlags *flags, const char *filename_str, - PyArena *arena) -{ - mod_ty mod; - PyObject *filename; - filename = PyUnicode_DecodeFSDefault(filename_str); - if (filename == NULL) - return NULL; - mod = PyAST_FromNodeObject(n, flags, filename, arena); - Py_DECREF(filename); - return mod; - -} - -/* Return the AST repr. of the operator represented as syntax (|, ^, etc.) -*/ - -static operator_ty -get_operator(struct compiling *c, const node *n) -{ - switch (TYPE(n)) { - case VBAR: - return BitOr; - case CIRCUMFLEX: - return BitXor; - case AMPER: - return BitAnd; - case LEFTSHIFT: - return LShift; - case RIGHTSHIFT: - return RShift; - case PLUS: - return Add; - case MINUS: - return Sub; - case STAR: - return Mult; - case AT: - if (c->c_feature_version < 5) { - ast_error(c, n, - "The '@' operator is only supported in Python 3.5 and greater"); - return (operator_ty)0; - } - return MatMult; - case SLASH: - return Div; - case DOUBLESLASH: - return FloorDiv; - case PERCENT: - return Mod; - default: - return (operator_ty)0; - } -} - -static const char * const FORBIDDEN[] = { - "None", - "True", - "False", - "__debug__", - NULL, -}; - -static int -forbidden_name(struct compiling *c, identifier name, const node *n, - int full_checks) -{ - assert(PyUnicode_Check(name)); - const char * const *p = FORBIDDEN; - if (!full_checks) { - /* In most cases, the parser will protect True, False, and None - from being assign to. */ - p += 3; - } - for (; *p; p++) { - if (_PyUnicode_EqualToASCIIString(name, *p)) { - ast_error(c, n, "cannot assign to %U", name); - return 1; - } - } - return 0; -} - -static expr_ty -copy_location(expr_ty e, const node *n, const node *end) -{ - if (e) { - e->lineno = LINENO(n); - e->col_offset = n->n_col_offset; - e->end_lineno = end->n_end_lineno; - e->end_col_offset = end->n_end_col_offset; - } - return e; -} - -static const char * -get_expr_name(expr_ty e) -{ - switch (e->kind) { - case Attribute_kind: - return "attribute"; - case Subscript_kind: - return "subscript"; - case Starred_kind: - return "starred"; - case Name_kind: - return "name"; - case List_kind: - return "list"; - case Tuple_kind: - return "tuple"; - case Lambda_kind: - return "lambda"; - case Call_kind: - return "function call"; - case BoolOp_kind: - case BinOp_kind: - case UnaryOp_kind: - return "operator"; - case GeneratorExp_kind: - return "generator expression"; - case Yield_kind: - case YieldFrom_kind: - return "yield expression"; - case Await_kind: - return "await expression"; - case ListComp_kind: - return "list comprehension"; - case SetComp_kind: - return "set comprehension"; - case DictComp_kind: - return "dict comprehension"; - case Dict_kind: - return "dict display"; - case Set_kind: - return "set display"; - case JoinedStr_kind: - case FormattedValue_kind: - return "f-string expression"; - case Constant_kind: { - PyObject *value = e->v.Constant.value; - if (value == Py_None) { - return "None"; - } - if (value == Py_False) { - return "False"; - } - if (value == Py_True) { - return "True"; - } - if (value == Py_Ellipsis) { - return "Ellipsis"; - } - return "literal"; - } - case Compare_kind: - return "comparison"; - case IfExp_kind: - return "conditional expression"; - case NamedExpr_kind: - return "named expression"; - default: - PyErr_Format(PyExc_SystemError, - "unexpected expression in assignment %d (line %d)", - e->kind, e->lineno); - return NULL; - } -} - -/* Set the context ctx for expr_ty e, recursively traversing e. - - Only sets context for expr kinds that "can appear in assignment context" - (according to ../Parser/Python.asdl). For other expr kinds, it sets - an appropriate syntax error and returns false. -*/ - -static int -set_context(struct compiling *c, expr_ty e, expr_context_ty ctx, const node *n) -{ - asdl_seq *s = NULL; - - /* Expressions in an augmented assignment have a Store context. */ - - switch (e->kind) { - case Attribute_kind: - e->v.Attribute.ctx = ctx; - if (ctx == Store && forbidden_name(c, e->v.Attribute.attr, n, 1)) - return 0; - break; - case Subscript_kind: - e->v.Subscript.ctx = ctx; - break; - case Starred_kind: - e->v.Starred.ctx = ctx; - if (!set_context(c, e->v.Starred.value, ctx, n)) - return 0; - break; - case Name_kind: - if (ctx == Store) { - if (forbidden_name(c, e->v.Name.id, n, 0)) - return 0; /* forbidden_name() calls ast_error() */ - } - e->v.Name.ctx = ctx; - break; - case List_kind: - e->v.List.ctx = ctx; - s = e->v.List.elts; - break; - case Tuple_kind: - e->v.Tuple.ctx = ctx; - s = e->v.Tuple.elts; - break; - default: { - const char *expr_name = get_expr_name(e); - if (expr_name != NULL) { - ast_error(c, n, "cannot %s %s", - ctx == Store ? "assign to" : "delete", - expr_name); - } + Py_ssize_t i; + for (i = 0; i < asdl_seq_LEN(patterns); i++) { + pattern_ty pattern = asdl_seq_GET(patterns, i); + if (!validate_pattern(state, pattern, star_ok)) { return 0; } } - - /* If the LHS is a list or tuple, we need to set the assignment - context for all the contained elements. - */ - if (s) { - Py_ssize_t i; - - for (i = 0; i < asdl_seq_LEN(s); i++) { - if (!set_context(c, (expr_ty)asdl_seq_GET(s, i), ctx, n)) - return 0; - } - } return 1; } -static operator_ty -ast_for_augassign(struct compiling *c, const node *n) -{ - REQ(n, augassign); - n = CHILD(n, 0); - switch (STR(n)[0]) { - case '+': - return Add; - case '-': - return Sub; - case '/': - if (STR(n)[1] == '/') - return FloorDiv; - else - return Div; - case '%': - return Mod; - case '<': - return LShift; - case '>': - return RShift; - case '&': - return BitAnd; - case '^': - return BitXor; - case '|': - return BitOr; - case '*': - if (STR(n)[1] == '*') - return Pow; - else - return Mult; - case '@': - if (c->c_feature_version < 5) { - ast_error(c, n, - "The '@' operator is only supported in Python 3.5 and greater"); - return (operator_ty)0; - } - return MatMult; - default: - PyErr_Format(PyExc_SystemError, "invalid augassign: %s", STR(n)); - return (operator_ty)0; - } -} - -static cmpop_ty -ast_for_comp_op(struct compiling *c, const node *n) -{ - /* comp_op: '<'|'>'|'=='|'>='|'<='|'!='|'in'|'not' 'in'|'is' - |'is' 'not' - */ - REQ(n, comp_op); - if (NCH(n) == 1) { - n = CHILD(n, 0); - switch (TYPE(n)) { - case LESS: - return Lt; - case GREATER: - return Gt; - case EQEQUAL: /* == */ - return Eq; - case LESSEQUAL: - return LtE; - case GREATEREQUAL: - return GtE; - case NOTEQUAL: - return NotEq; - case NAME: - if (strcmp(STR(n), "in") == 0) - return In; - if (strcmp(STR(n), "is") == 0) - return Is; - /* fall through */ - default: - PyErr_Format(PyExc_SystemError, "invalid comp_op: %s", - STR(n)); - return (cmpop_ty)0; - } - } - else if (NCH(n) == 2) { - /* handle "not in" and "is not" */ - switch (TYPE(CHILD(n, 0))) { - case NAME: - if (strcmp(STR(CHILD(n, 1)), "in") == 0) - return NotIn; - if (strcmp(STR(CHILD(n, 0)), "is") == 0) - return IsNot; - /* fall through */ - default: - PyErr_Format(PyExc_SystemError, "invalid comp_op: %s %s", - STR(CHILD(n, 0)), STR(CHILD(n, 1))); - return (cmpop_ty)0; - } - } - PyErr_Format(PyExc_SystemError, "invalid comp_op: has %d children", - NCH(n)); - return (cmpop_ty)0; -} - -static asdl_seq * -seq_for_testlist(struct compiling *c, const node *n) -{ - /* testlist: test (',' test)* [','] - testlist_star_expr: test|star_expr (',' test|star_expr)* [','] - */ - asdl_seq *seq; - expr_ty expression; - int i; - assert(TYPE(n) == testlist || TYPE(n) == testlist_star_expr || TYPE(n) == testlist_comp); - - seq = _Py_asdl_seq_new((NCH(n) + 1) / 2, c->c_arena); - if (!seq) - return NULL; - - for (i = 0; i < NCH(n); i += 2) { - const node *ch = CHILD(n, i); - assert(TYPE(ch) == test || TYPE(ch) == test_nocond || TYPE(ch) == star_expr || TYPE(ch) == namedexpr_test); - - expression = ast_for_expr(c, ch); - if (!expression) - return NULL; - - assert(i / 2 < seq->size); - asdl_seq_SET(seq, i / 2, expression); - } - return seq; -} - -static arg_ty -ast_for_arg(struct compiling *c, const node *n) -{ - identifier name; - expr_ty annotation = NULL; - node *ch; - arg_ty ret; - - assert(TYPE(n) == tfpdef || TYPE(n) == vfpdef); - ch = CHILD(n, 0); - name = NEW_IDENTIFIER(ch); - if (!name) - return NULL; - if (forbidden_name(c, name, ch, 0)) - return NULL; - - if (NCH(n) == 3 && TYPE(CHILD(n, 1)) == COLON) { - annotation = ast_for_expr(c, CHILD(n, 2)); - if (!annotation) - return NULL; - } - - ret = arg(name, annotation, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - if (!ret) - return NULL; - return ret; -} - -/* returns -1 if failed to handle keyword only arguments - returns new position to keep processing if successful - (',' tfpdef ['=' test])* - ^^^ - start pointing here - */ -static int -handle_keywordonly_args(struct compiling *c, const node *n, int start, - asdl_seq *kwonlyargs, asdl_seq *kwdefaults) -{ - PyObject *argname; - node *ch; - expr_ty expression, annotation; - arg_ty arg = NULL; - int i = start; - int j = 0; /* index for kwdefaults and kwonlyargs */ - - if (kwonlyargs == NULL) { - ast_error(c, CHILD(n, start), "named arguments must follow bare *"); - return -1; - } - assert(kwdefaults != NULL); - while (i < NCH(n)) { - ch = CHILD(n, i); - switch (TYPE(ch)) { - case vfpdef: - case tfpdef: - if (i + 1 < NCH(n) && TYPE(CHILD(n, i + 1)) == EQUAL) { - expression = ast_for_expr(c, CHILD(n, i + 2)); - if (!expression) - goto error; - asdl_seq_SET(kwdefaults, j, expression); - i += 2; /* '=' and test */ - } - else { /* setting NULL if no default value exists */ - asdl_seq_SET(kwdefaults, j, NULL); - } - if (NCH(ch) == 3) { - /* ch is NAME ':' test */ - annotation = ast_for_expr(c, CHILD(ch, 2)); - if (!annotation) - goto error; - } - else { - annotation = NULL; - } - ch = CHILD(ch, 0); - argname = NEW_IDENTIFIER(ch); - if (!argname) - goto error; - if (forbidden_name(c, argname, ch, 0)) - goto error; - arg = arg(argname, annotation, NULL, LINENO(ch), ch->n_col_offset, - ch->n_end_lineno, ch->n_end_col_offset, - c->c_arena); - if (!arg) - goto error; - asdl_seq_SET(kwonlyargs, j++, arg); - i += 1; /* the name */ - if (i < NCH(n) && TYPE(CHILD(n, i)) == COMMA) - i += 1; /* the comma, if present */ - break; - case TYPE_COMMENT: - /* arg will be equal to the last argument processed */ - arg->type_comment = NEW_TYPE_COMMENT(ch); - if (!arg->type_comment) - goto error; - i += 1; - break; - case DOUBLESTAR: - return i; - default: - ast_error(c, ch, "unexpected node"); - goto error; - } - } - return i; - error: - return -1; -} - -/* Create AST for argument list. */ - -static arguments_ty -ast_for_arguments(struct compiling *c, const node *n) -{ - /* This function handles both typedargslist (function definition) - and varargslist (lambda definition). - - parameters: '(' [typedargslist] ')' - - The following definition for typedarglist is equivalent to this set of rules: - - arguments = argument (',' [TYPE_COMMENT] argument)* - argument = tfpdef ['=' test] - kwargs = '**' tfpdef [','] [TYPE_COMMENT] - args = '*' [tfpdef] - kwonly_kwargs = (',' [TYPE_COMMENT] argument)* (TYPE_COMMENT | [',' - [TYPE_COMMENT] [kwargs]]) - args_kwonly_kwargs = args kwonly_kwargs | kwargs - poskeyword_args_kwonly_kwargs = arguments ( TYPE_COMMENT | [',' - [TYPE_COMMENT] [args_kwonly_kwargs]]) - typedargslist_no_posonly = poskeyword_args_kwonly_kwargs | args_kwonly_kwargs - typedarglist = (arguments ',' [TYPE_COMMENT] '/' [',' [[TYPE_COMMENT] - typedargslist_no_posonly]])|(typedargslist_no_posonly)" - - typedargslist: ( (tfpdef ['=' test] (',' [TYPE_COMMENT] tfpdef ['=' test])* - ',' [TYPE_COMMENT] '/' [',' [ [TYPE_COMMENT] tfpdef ['=' test] ( ',' - [TYPE_COMMENT] tfpdef ['=' test])* (TYPE_COMMENT | [',' [TYPE_COMMENT] [ '*' - [tfpdef] (',' [TYPE_COMMENT] tfpdef ['=' test])* (TYPE_COMMENT | [',' - [TYPE_COMMENT] ['**' tfpdef [','] [TYPE_COMMENT]]]) | '**' tfpdef [','] - [TYPE_COMMENT]]]) | '*' [tfpdef] (',' [TYPE_COMMENT] tfpdef ['=' test])* - (TYPE_COMMENT | [',' [TYPE_COMMENT] ['**' tfpdef [','] [TYPE_COMMENT]]]) | - '**' tfpdef [','] [TYPE_COMMENT]]] ) | (tfpdef ['=' test] (',' - [TYPE_COMMENT] tfpdef ['=' test])* (TYPE_COMMENT | [',' [TYPE_COMMENT] [ '*' - [tfpdef] (',' [TYPE_COMMENT] tfpdef ['=' test])* (TYPE_COMMENT | [',' - [TYPE_COMMENT] ['**' tfpdef [','] [TYPE_COMMENT]]]) | '**' tfpdef [','] - [TYPE_COMMENT]]]) | '*' [tfpdef] (',' [TYPE_COMMENT] tfpdef ['=' test])* - (TYPE_COMMENT | [',' [TYPE_COMMENT] ['**' tfpdef [','] [TYPE_COMMENT]]]) | - '**' tfpdef [','] [TYPE_COMMENT])) - - tfpdef: NAME [':' test] - - The following definition for varargslist is equivalent to this set of rules: - - arguments = argument (',' argument )* - argument = vfpdef ['=' test] - kwargs = '**' vfpdef [','] - args = '*' [vfpdef] - kwonly_kwargs = (',' argument )* [',' [kwargs]] - args_kwonly_kwargs = args kwonly_kwargs | kwargs - poskeyword_args_kwonly_kwargs = arguments [',' [args_kwonly_kwargs]] - vararglist_no_posonly = poskeyword_args_kwonly_kwargs | args_kwonly_kwargs - varargslist = arguments ',' '/' [','[(vararglist_no_posonly)]] | - (vararglist_no_posonly) - - varargslist: vfpdef ['=' test ](',' vfpdef ['=' test])* ',' '/' [',' [ (vfpdef ['=' - test] (',' vfpdef ['=' test])* [',' [ '*' [vfpdef] (',' vfpdef ['=' test])* [',' - ['**' vfpdef [',']]] | '**' vfpdef [',']]] | '*' [vfpdef] (',' vfpdef ['=' test])* - [',' ['**' vfpdef [',']]] | '**' vfpdef [',']) ]] | (vfpdef ['=' test] (',' vfpdef - ['=' test])* [',' [ '*' [vfpdef] (',' vfpdef ['=' test])* [',' ['**' vfpdef [',']]] - | '**' vfpdef [',']]] | '*' [vfpdef] (',' vfpdef ['=' test])* [',' ['**' vfpdef - [',']]] | '**' vfpdef [',']) - - vfpdef: NAME - - */ - int i, j, k, l, nposonlyargs=0, nposargs = 0, nkwonlyargs = 0; - int nposdefaults = 0, found_default = 0; - asdl_seq *posonlyargs, *posargs, *posdefaults, *kwonlyargs, *kwdefaults; - arg_ty vararg = NULL, kwarg = NULL; - arg_ty arg = NULL; - node *ch; - - if (TYPE(n) == parameters) { - if (NCH(n) == 2) /* () as argument list */ - return arguments(NULL, NULL, NULL, NULL, NULL, NULL, NULL, c->c_arena); - n = CHILD(n, 1); - } - assert(TYPE(n) == typedargslist || TYPE(n) == varargslist); - - /* First count the number of positional args & defaults. The - variable i is the loop index for this for loop and the next. - The next loop picks up where the first leaves off. - */ - for (i = 0; i < NCH(n); i++) { - ch = CHILD(n, i); - if (TYPE(ch) == STAR) { - /* skip star */ - i++; - if (i < NCH(n) && /* skip argument following star */ - (TYPE(CHILD(n, i)) == tfpdef || - TYPE(CHILD(n, i)) == vfpdef)) { - i++; - } - break; - } - if (TYPE(ch) == DOUBLESTAR) break; - if (TYPE(ch) == vfpdef || TYPE(ch) == tfpdef) nposargs++; - if (TYPE(ch) == EQUAL) nposdefaults++; - if (TYPE(ch) == SLASH ) { - nposonlyargs = nposargs; - nposargs = 0; - } - } - /* count the number of keyword only args & - defaults for keyword only args */ - for ( ; i < NCH(n); ++i) { - ch = CHILD(n, i); - if (TYPE(ch) == DOUBLESTAR) break; - if (TYPE(ch) == tfpdef || TYPE(ch) == vfpdef) nkwonlyargs++; - } - posonlyargs = (nposonlyargs ? _Py_asdl_seq_new(nposonlyargs, c->c_arena) : NULL); - if (!posonlyargs && nposonlyargs) { - return NULL; - } - posargs = (nposargs ? _Py_asdl_seq_new(nposargs, c->c_arena) : NULL); - if (!posargs && nposargs) - return NULL; - kwonlyargs = (nkwonlyargs ? - _Py_asdl_seq_new(nkwonlyargs, c->c_arena) : NULL); - if (!kwonlyargs && nkwonlyargs) - return NULL; - posdefaults = (nposdefaults ? - _Py_asdl_seq_new(nposdefaults, c->c_arena) : NULL); - if (!posdefaults && nposdefaults) - return NULL; - /* The length of kwonlyargs and kwdefaults are same - since we set NULL as default for keyword only argument w/o default - - we have sequence data structure, but no dictionary */ - kwdefaults = (nkwonlyargs ? - _Py_asdl_seq_new(nkwonlyargs, c->c_arena) : NULL); - if (!kwdefaults && nkwonlyargs) - return NULL; - - /* tfpdef: NAME [':' test] - vfpdef: NAME - */ - i = 0; - j = 0; /* index for defaults */ - k = 0; /* index for args */ - l = 0; /* index for posonlyargs */ - while (i < NCH(n)) { - ch = CHILD(n, i); - switch (TYPE(ch)) { - case tfpdef: - case vfpdef: - /* XXX Need to worry about checking if TYPE(CHILD(n, i+1)) is - anything other than EQUAL or a comma? */ - /* XXX Should NCH(n) check be made a separate check? */ - if (i + 1 < NCH(n) && TYPE(CHILD(n, i + 1)) == EQUAL) { - expr_ty expression = ast_for_expr(c, CHILD(n, i + 2)); - if (!expression) - return NULL; - assert(posdefaults != NULL); - asdl_seq_SET(posdefaults, j++, expression); - i += 2; - found_default = 1; - } - else if (found_default) { - ast_error(c, n, - "non-default argument follows default argument"); - return NULL; - } - arg = ast_for_arg(c, ch); - if (!arg) - return NULL; - if (l < nposonlyargs) { - asdl_seq_SET(posonlyargs, l++, arg); - } else { - asdl_seq_SET(posargs, k++, arg); - } - i += 1; /* the name */ - if (i < NCH(n) && TYPE(CHILD(n, i)) == COMMA) - i += 1; /* the comma, if present */ - break; - case SLASH: - /* Advance the slash and the comma. If there are more names - * after the slash there will be a comma so we are advancing - * the correct number of nodes. If the slash is the last item, - * we will be advancing an extra token but then * i > NCH(n) - * and the enclosing while will finish correctly. */ - i += 2; - break; - case STAR: - if (i+1 >= NCH(n) || - (i+2 == NCH(n) && (TYPE(CHILD(n, i+1)) == COMMA - || TYPE(CHILD(n, i+1)) == TYPE_COMMENT))) { - ast_error(c, CHILD(n, i), - "named arguments must follow bare *"); - return NULL; - } - ch = CHILD(n, i+1); /* tfpdef or COMMA */ - if (TYPE(ch) == COMMA) { - int res = 0; - i += 2; /* now follows keyword only arguments */ - - if (i < NCH(n) && TYPE(CHILD(n, i)) == TYPE_COMMENT) { - ast_error(c, CHILD(n, i), - "bare * has associated type comment"); - return NULL; - } - - res = handle_keywordonly_args(c, n, i, - kwonlyargs, kwdefaults); - if (res == -1) return NULL; - i = res; /* res has new position to process */ - } - else { - vararg = ast_for_arg(c, ch); - if (!vararg) - return NULL; - - i += 2; /* the star and the name */ - if (i < NCH(n) && TYPE(CHILD(n, i)) == COMMA) - i += 1; /* the comma, if present */ - - if (i < NCH(n) && TYPE(CHILD(n, i)) == TYPE_COMMENT) { - vararg->type_comment = NEW_TYPE_COMMENT(CHILD(n, i)); - if (!vararg->type_comment) - return NULL; - i += 1; - } - - if (i < NCH(n) && (TYPE(CHILD(n, i)) == tfpdef - || TYPE(CHILD(n, i)) == vfpdef)) { - int res = 0; - res = handle_keywordonly_args(c, n, i, - kwonlyargs, kwdefaults); - if (res == -1) return NULL; - i = res; /* res has new position to process */ - } - } - break; - case DOUBLESTAR: - ch = CHILD(n, i+1); /* tfpdef */ - assert(TYPE(ch) == tfpdef || TYPE(ch) == vfpdef); - kwarg = ast_for_arg(c, ch); - if (!kwarg) - return NULL; - i += 2; /* the double star and the name */ - if (i < NCH(n) && TYPE(CHILD(n, i)) == COMMA) - i += 1; /* the comma, if present */ - break; - case TYPE_COMMENT: - assert(i); - - if (kwarg) - arg = kwarg; - - /* arg will be equal to the last argument processed */ - arg->type_comment = NEW_TYPE_COMMENT(ch); - if (!arg->type_comment) - return NULL; - i += 1; - break; - default: - PyErr_Format(PyExc_SystemError, - "unexpected node in varargslist: %d @ %d", - TYPE(ch), i); - return NULL; - } - } - return arguments(posonlyargs, posargs, vararg, kwonlyargs, kwdefaults, kwarg, posdefaults, c->c_arena); -} - -static expr_ty -ast_for_decorator(struct compiling *c, const node *n) -{ - /* decorator: '@' namedexpr_test NEWLINE */ - - REQ(n, decorator); - REQ(CHILD(n, 0), AT); - REQ(CHILD(n, 2), NEWLINE); - - return ast_for_expr(c, CHILD(n, 1)); -} - -static asdl_seq* -ast_for_decorators(struct compiling *c, const node *n) -{ - asdl_seq* decorator_seq; - expr_ty d; - int i; - - REQ(n, decorators); - decorator_seq = _Py_asdl_seq_new(NCH(n), c->c_arena); - if (!decorator_seq) - return NULL; - - for (i = 0; i < NCH(n); i++) { - d = ast_for_decorator(c, CHILD(n, i)); - if (!d) - return NULL; - asdl_seq_SET(decorator_seq, i, d); - } - return decorator_seq; -} - -static stmt_ty -ast_for_funcdef_impl(struct compiling *c, const node *n0, - asdl_seq *decorator_seq, bool is_async) -{ - /* funcdef: 'def' NAME parameters ['->' test] ':' [TYPE_COMMENT] suite */ - const node * const n = is_async ? CHILD(n0, 1) : n0; - identifier name; - arguments_ty args; - asdl_seq *body; - expr_ty returns = NULL; - int name_i = 1; - int end_lineno, end_col_offset; - node *tc; - string type_comment = NULL; - - if (is_async && c->c_feature_version < 5) { - ast_error(c, n, - "Async functions are only supported in Python 3.5 and greater"); - return NULL; - } - - REQ(n, funcdef); - - name = NEW_IDENTIFIER(CHILD(n, name_i)); - if (!name) - return NULL; - if (forbidden_name(c, name, CHILD(n, name_i), 0)) - return NULL; - args = ast_for_arguments(c, CHILD(n, name_i + 1)); - if (!args) - return NULL; - if (TYPE(CHILD(n, name_i+2)) == RARROW) { - returns = ast_for_expr(c, CHILD(n, name_i + 3)); - if (!returns) - return NULL; - name_i += 2; - } - if (TYPE(CHILD(n, name_i + 3)) == TYPE_COMMENT) { - type_comment = NEW_TYPE_COMMENT(CHILD(n, name_i + 3)); - if (!type_comment) - return NULL; - name_i += 1; - } - body = ast_for_suite(c, CHILD(n, name_i + 3)); - if (!body) - return NULL; - get_last_end_pos(body, &end_lineno, &end_col_offset); - - if (NCH(CHILD(n, name_i + 3)) > 1) { - /* Check if the suite has a type comment in it. */ - tc = CHILD(CHILD(n, name_i + 3), 1); - - if (TYPE(tc) == TYPE_COMMENT) { - if (type_comment != NULL) { - ast_error(c, n, "Cannot have two type comments on def"); - return NULL; - } - type_comment = NEW_TYPE_COMMENT(tc); - if (!type_comment) - return NULL; - } - } - - if (is_async) - return AsyncFunctionDef(name, args, body, decorator_seq, returns, type_comment, - LINENO(n0), n0->n_col_offset, end_lineno, end_col_offset, c->c_arena); - else - return FunctionDef(name, args, body, decorator_seq, returns, type_comment, - LINENO(n), n->n_col_offset, end_lineno, end_col_offset, c->c_arena); -} - -static stmt_ty -ast_for_async_funcdef(struct compiling *c, const node *n, asdl_seq *decorator_seq) -{ - /* async_funcdef: ASYNC funcdef */ - REQ(n, async_funcdef); - REQ(CHILD(n, 0), ASYNC); - REQ(CHILD(n, 1), funcdef); - - return ast_for_funcdef_impl(c, n, decorator_seq, - true /* is_async */); -} - -static stmt_ty -ast_for_funcdef(struct compiling *c, const node *n, asdl_seq *decorator_seq) -{ - /* funcdef: 'def' NAME parameters ['->' test] ':' suite */ - return ast_for_funcdef_impl(c, n, decorator_seq, - false /* is_async */); -} - - -static stmt_ty -ast_for_async_stmt(struct compiling *c, const node *n) -{ - /* async_stmt: ASYNC (funcdef | with_stmt | for_stmt) */ - REQ(n, async_stmt); - REQ(CHILD(n, 0), ASYNC); - - switch (TYPE(CHILD(n, 1))) { - case funcdef: - return ast_for_funcdef_impl(c, n, NULL, - true /* is_async */); - case with_stmt: - return ast_for_with_stmt(c, n, - true /* is_async */); - - case for_stmt: - return ast_for_for_stmt(c, n, - true /* is_async */); - - default: - PyErr_Format(PyExc_SystemError, - "invalid async stament: %s", - STR(CHILD(n, 1))); - return NULL; - } -} - -static stmt_ty -ast_for_decorated(struct compiling *c, const node *n) -{ - /* decorated: decorators (classdef | funcdef | async_funcdef) */ - stmt_ty thing = NULL; - asdl_seq *decorator_seq = NULL; - - REQ(n, decorated); - - decorator_seq = ast_for_decorators(c, CHILD(n, 0)); - if (!decorator_seq) - return NULL; - - assert(TYPE(CHILD(n, 1)) == funcdef || - TYPE(CHILD(n, 1)) == async_funcdef || - TYPE(CHILD(n, 1)) == classdef); - - if (TYPE(CHILD(n, 1)) == funcdef) { - thing = ast_for_funcdef(c, CHILD(n, 1), decorator_seq); - } else if (TYPE(CHILD(n, 1)) == classdef) { - thing = ast_for_classdef(c, CHILD(n, 1), decorator_seq); - } else if (TYPE(CHILD(n, 1)) == async_funcdef) { - thing = ast_for_async_funcdef(c, CHILD(n, 1), decorator_seq); - } - return thing; -} - -static expr_ty -ast_for_namedexpr(struct compiling *c, const node *n) -{ - /* namedexpr_test: test [':=' test] - argument: ( test [comp_for] | - test ':=' test | - test '=' test | - '**' test | - '*' test ) - */ - expr_ty target, value; - - target = ast_for_expr(c, CHILD(n, 0)); - if (!target) - return NULL; - - value = ast_for_expr(c, CHILD(n, 2)); - if (!value) - return NULL; - - if (target->kind != Name_kind) { - const char *expr_name = get_expr_name(target); - if (expr_name != NULL) { - ast_error(c, n, "cannot use assignment expressions with %s", expr_name); - } - return NULL; - } - - if (!set_context(c, target, Store, n)) - return NULL; - - return NamedExpr(target, value, LINENO(n), n->n_col_offset, n->n_end_lineno, - n->n_end_col_offset, c->c_arena); -} - -static expr_ty -ast_for_lambdef(struct compiling *c, const node *n) -{ - /* lambdef: 'lambda' [varargslist] ':' test - lambdef_nocond: 'lambda' [varargslist] ':' test_nocond */ - arguments_ty args; - expr_ty expression; - - if (NCH(n) == 3) { - args = arguments(NULL, NULL, NULL, NULL, NULL, NULL, NULL, c->c_arena); - if (!args) - return NULL; - expression = ast_for_expr(c, CHILD(n, 2)); - if (!expression) - return NULL; - } - else { - args = ast_for_arguments(c, CHILD(n, 1)); - if (!args) - return NULL; - expression = ast_for_expr(c, CHILD(n, 3)); - if (!expression) - return NULL; - } - - return Lambda(args, expression, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} - -static expr_ty -ast_for_ifexpr(struct compiling *c, const node *n) -{ - /* test: or_test 'if' or_test 'else' test */ - expr_ty expression, body, orelse; - - assert(NCH(n) == 5); - body = ast_for_expr(c, CHILD(n, 0)); - if (!body) - return NULL; - expression = ast_for_expr(c, CHILD(n, 2)); - if (!expression) - return NULL; - orelse = ast_for_expr(c, CHILD(n, 4)); - if (!orelse) - return NULL; - return IfExp(expression, body, orelse, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, - c->c_arena); -} - -/* - Count the number of 'for' loops in a comprehension. - - Helper for ast_for_comprehension(). -*/ - -static int -count_comp_fors(struct compiling *c, const node *n) -{ - int n_fors = 0; - - count_comp_for: - n_fors++; - REQ(n, comp_for); - if (NCH(n) == 2) { - REQ(CHILD(n, 0), ASYNC); - n = CHILD(n, 1); - } - else if (NCH(n) == 1) { - n = CHILD(n, 0); - } - else { - goto error; - } - if (NCH(n) == (5)) { - n = CHILD(n, 4); - } - else { - return n_fors; - } - count_comp_iter: - REQ(n, comp_iter); - n = CHILD(n, 0); - if (TYPE(n) == comp_for) - goto count_comp_for; - else if (TYPE(n) == comp_if) { - if (NCH(n) == 3) { - n = CHILD(n, 2); - goto count_comp_iter; - } - else - return n_fors; - } - - error: - /* Should never be reached */ - PyErr_SetString(PyExc_SystemError, - "logic error in count_comp_fors"); - return -1; -} - -/* Count the number of 'if' statements in a comprehension. - - Helper for ast_for_comprehension(). -*/ - -static int -count_comp_ifs(struct compiling *c, const node *n) -{ - int n_ifs = 0; - - while (1) { - REQ(n, comp_iter); - if (TYPE(CHILD(n, 0)) == comp_for) - return n_ifs; - n = CHILD(n, 0); - REQ(n, comp_if); - n_ifs++; - if (NCH(n) == 2) - return n_ifs; - n = CHILD(n, 2); - } -} - -static asdl_seq * -ast_for_comprehension(struct compiling *c, const node *n) -{ - int i, n_fors; - asdl_seq *comps; - - n_fors = count_comp_fors(c, n); - if (n_fors == -1) - return NULL; - - comps = _Py_asdl_seq_new(n_fors, c->c_arena); - if (!comps) - return NULL; - - for (i = 0; i < n_fors; i++) { - comprehension_ty comp; - asdl_seq *t; - expr_ty expression, first; - node *for_ch; - node *sync_n; - int is_async = 0; - - REQ(n, comp_for); - - if (NCH(n) == 2) { - is_async = 1; - REQ(CHILD(n, 0), ASYNC); - sync_n = CHILD(n, 1); - } - else { - sync_n = CHILD(n, 0); - } - REQ(sync_n, sync_comp_for); - - /* Async comprehensions only allowed in Python 3.6 and greater */ - if (is_async && c->c_feature_version < 6) { - ast_error(c, n, - "Async comprehensions are only supported in Python 3.6 and greater"); - return NULL; - } - - for_ch = CHILD(sync_n, 1); - t = ast_for_exprlist(c, for_ch, Store); - if (!t) - return NULL; - expression = ast_for_expr(c, CHILD(sync_n, 3)); - if (!expression) - return NULL; - - /* Check the # of children rather than the length of t, since - (x for x, in ...) has 1 element in t, but still requires a Tuple. */ - first = (expr_ty)asdl_seq_GET(t, 0); - if (NCH(for_ch) == 1) - comp = comprehension(first, expression, NULL, - is_async, c->c_arena); - else - comp = comprehension(Tuple(t, Store, first->lineno, first->col_offset, - for_ch->n_end_lineno, for_ch->n_end_col_offset, - c->c_arena), - expression, NULL, is_async, c->c_arena); - if (!comp) - return NULL; - - if (NCH(sync_n) == 5) { - int j, n_ifs; - asdl_seq *ifs; - - n = CHILD(sync_n, 4); - n_ifs = count_comp_ifs(c, n); - if (n_ifs == -1) - return NULL; - - ifs = _Py_asdl_seq_new(n_ifs, c->c_arena); - if (!ifs) - return NULL; - - for (j = 0; j < n_ifs; j++) { - REQ(n, comp_iter); - n = CHILD(n, 0); - REQ(n, comp_if); - - expression = ast_for_expr(c, CHILD(n, 1)); - if (!expression) - return NULL; - asdl_seq_SET(ifs, j, expression); - if (NCH(n) == 3) - n = CHILD(n, 2); - } - /* on exit, must guarantee that n is a comp_for */ - if (TYPE(n) == comp_iter) - n = CHILD(n, 0); - comp->ifs = ifs; - } - asdl_seq_SET(comps, i, comp); - } - return comps; -} - -static expr_ty -ast_for_itercomp(struct compiling *c, const node *n, int type) -{ - /* testlist_comp: (test|star_expr) - * ( comp_for | (',' (test|star_expr))* [','] ) */ - expr_ty elt; - asdl_seq *comps; - node *ch; - - assert(NCH(n) > 1); - - ch = CHILD(n, 0); - elt = ast_for_expr(c, ch); - if (!elt) - return NULL; - if (elt->kind == Starred_kind) { - ast_error(c, ch, "iterable unpacking cannot be used in comprehension"); - return NULL; - } - - comps = ast_for_comprehension(c, CHILD(n, 1)); - if (!comps) - return NULL; - - if (type == COMP_GENEXP) - return GeneratorExp(elt, comps, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - else if (type == COMP_LISTCOMP) - return ListComp(elt, comps, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - else if (type == COMP_SETCOMP) - return SetComp(elt, comps, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - else - /* Should never happen */ - return NULL; -} - -/* Fills in the key, value pair corresponding to the dict element. In case - * of an unpacking, key is NULL. *i is advanced by the number of ast - * elements. Iff successful, nonzero is returned. - */ -static int -ast_for_dictelement(struct compiling *c, const node *n, int *i, - expr_ty *key, expr_ty *value) -{ - expr_ty expression; - if (TYPE(CHILD(n, *i)) == DOUBLESTAR) { - assert(NCH(n) - *i >= 2); - - expression = ast_for_expr(c, CHILD(n, *i + 1)); - if (!expression) - return 0; - *key = NULL; - *value = expression; - - *i += 2; - } - else { - assert(NCH(n) - *i >= 3); - - expression = ast_for_expr(c, CHILD(n, *i)); - if (!expression) - return 0; - *key = expression; - - REQ(CHILD(n, *i + 1), COLON); - - expression = ast_for_expr(c, CHILD(n, *i + 2)); - if (!expression) - return 0; - *value = expression; - - *i += 3; - } - return 1; -} - -static expr_ty -ast_for_dictcomp(struct compiling *c, const node *n) -{ - expr_ty key, value; - asdl_seq *comps; - int i = 0; - - if (!ast_for_dictelement(c, n, &i, &key, &value)) - return NULL; - assert(key); - assert(NCH(n) - i >= 1); - - comps = ast_for_comprehension(c, CHILD(n, i)); - if (!comps) - return NULL; - - return DictComp(key, value, comps, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} - -static expr_ty -ast_for_dictdisplay(struct compiling *c, const node *n) -{ - int i; - int j; - int size; - asdl_seq *keys, *values; - - size = (NCH(n) + 1) / 3; /* +1 in case no trailing comma */ - keys = _Py_asdl_seq_new(size, c->c_arena); - if (!keys) - return NULL; - - values = _Py_asdl_seq_new(size, c->c_arena); - if (!values) - return NULL; - - j = 0; - for (i = 0; i < NCH(n); i++) { - expr_ty key, value; - - if (!ast_for_dictelement(c, n, &i, &key, &value)) - return NULL; - asdl_seq_SET(keys, j, key); - asdl_seq_SET(values, j, value); - - j++; - } - keys->size = j; - values->size = j; - return Dict(keys, values, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} - -static expr_ty -ast_for_genexp(struct compiling *c, const node *n) -{ - assert(TYPE(n) == (testlist_comp) || TYPE(n) == (argument)); - return ast_for_itercomp(c, n, COMP_GENEXP); -} - -static expr_ty -ast_for_listcomp(struct compiling *c, const node *n) -{ - assert(TYPE(n) == (testlist_comp)); - return ast_for_itercomp(c, n, COMP_LISTCOMP); -} - -static expr_ty -ast_for_setcomp(struct compiling *c, const node *n) -{ - assert(TYPE(n) == (dictorsetmaker)); - return ast_for_itercomp(c, n, COMP_SETCOMP); -} - -static expr_ty -ast_for_setdisplay(struct compiling *c, const node *n) -{ - int i; - int size; - asdl_seq *elts; - - assert(TYPE(n) == (dictorsetmaker)); - size = (NCH(n) + 1) / 2; /* +1 in case no trailing comma */ - elts = _Py_asdl_seq_new(size, c->c_arena); - if (!elts) - return NULL; - for (i = 0; i < NCH(n); i += 2) { - expr_ty expression; - expression = ast_for_expr(c, CHILD(n, i)); - if (!expression) - return NULL; - asdl_seq_SET(elts, i / 2, expression); - } - return Set(elts, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} - -static expr_ty -ast_for_atom(struct compiling *c, const node *n) -{ - /* atom: '(' [yield_expr|testlist_comp] ')' | '[' [testlist_comp] ']' - | '{' [dictmaker|testlist_comp] '}' | NAME | NUMBER | STRING+ - | '...' | 'None' | 'True' | 'False' - */ - node *ch = CHILD(n, 0); - - switch (TYPE(ch)) { - case NAME: { - PyObject *name; - const char *s = STR(ch); - size_t len = strlen(s); - if (len >= 4 && len <= 5) { - if (!strcmp(s, "None")) - return Constant(Py_None, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - if (!strcmp(s, "True")) - return Constant(Py_True, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - if (!strcmp(s, "False")) - return Constant(Py_False, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - name = new_identifier(s, c); - if (!name) - return NULL; - /* All names start in Load context, but may later be changed. */ - return Name(name, Load, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - case STRING: { - expr_ty str = parsestrplus(c, n); - if (!str) { - const char *errtype = NULL; - if (PyErr_ExceptionMatches(PyExc_UnicodeError)) - errtype = "unicode error"; - else if (PyErr_ExceptionMatches(PyExc_ValueError)) - errtype = "value error"; - if (errtype) { - PyObject *type, *value, *tback, *errstr; - PyErr_Fetch(&type, &value, &tback); - errstr = PyObject_Str(value); - if (errstr) { - ast_error(c, n, "(%s) %U", errtype, errstr); - Py_DECREF(errstr); - } - else { - PyErr_Clear(); - ast_error(c, n, "(%s) unknown error", errtype); - } - Py_DECREF(type); - Py_XDECREF(value); - Py_XDECREF(tback); - } - return NULL; - } - return str; - } - case NUMBER: { - PyObject *pynum; - /* Underscores in numeric literals are only allowed in Python 3.6 or greater */ - /* Check for underscores here rather than in parse_number so we can report a line number on error */ - if (c->c_feature_version < 6 && strchr(STR(ch), '_') != NULL) { - ast_error(c, ch, - "Underscores in numeric literals are only supported in Python 3.6 and greater"); - return NULL; - } - pynum = parsenumber(c, STR(ch)); - if (!pynum) - return NULL; - - if (PyArena_AddPyObject(c->c_arena, pynum) < 0) { - Py_DECREF(pynum); - return NULL; - } - return Constant(pynum, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - case ELLIPSIS: /* Ellipsis */ - return Constant(Py_Ellipsis, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - case LPAR: /* some parenthesized expressions */ - ch = CHILD(n, 1); - - if (TYPE(ch) == RPAR) - return Tuple(NULL, Load, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - - if (TYPE(ch) == yield_expr) - return ast_for_expr(c, ch); - - /* testlist_comp: test ( comp_for | (',' test)* [','] ) */ - if (NCH(ch) == 1) { - return ast_for_testlist(c, ch); - } - - if (TYPE(CHILD(ch, 1)) == comp_for) { - return copy_location(ast_for_genexp(c, ch), n, n); - } - else { - return copy_location(ast_for_testlist(c, ch), n, n); - } - case LSQB: /* list (or list comprehension) */ - ch = CHILD(n, 1); - - if (TYPE(ch) == RSQB) - return List(NULL, Load, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - - REQ(ch, testlist_comp); - if (NCH(ch) == 1 || TYPE(CHILD(ch, 1)) == COMMA) { - asdl_seq *elts = seq_for_testlist(c, ch); - if (!elts) - return NULL; - - return List(elts, Load, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - else { - return copy_location(ast_for_listcomp(c, ch), n, n); - } - case LBRACE: { - /* dictorsetmaker: ( ((test ':' test | '**' test) - * (comp_for | (',' (test ':' test | '**' test))* [','])) | - * ((test | '*' test) - * (comp_for | (',' (test | '*' test))* [','])) ) */ - expr_ty res; - ch = CHILD(n, 1); - if (TYPE(ch) == RBRACE) { - /* It's an empty dict. */ - return Dict(NULL, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - else { - int is_dict = (TYPE(CHILD(ch, 0)) == DOUBLESTAR); - if (NCH(ch) == 1 || - (NCH(ch) > 1 && - TYPE(CHILD(ch, 1)) == COMMA)) { - /* It's a set display. */ - res = ast_for_setdisplay(c, ch); - } - else if (NCH(ch) > 1 && - TYPE(CHILD(ch, 1)) == comp_for) { - /* It's a set comprehension. */ - res = ast_for_setcomp(c, ch); - } - else if (NCH(ch) > 3 - is_dict && - TYPE(CHILD(ch, 3 - is_dict)) == comp_for) { - /* It's a dictionary comprehension. */ - if (is_dict) { - ast_error(c, n, - "dict unpacking cannot be used in dict comprehension"); - return NULL; - } - res = ast_for_dictcomp(c, ch); - } - else { - /* It's a dictionary display. */ - res = ast_for_dictdisplay(c, ch); - } - return copy_location(res, n, n); - } - } - default: - PyErr_Format(PyExc_SystemError, "unhandled atom %d", TYPE(ch)); - return NULL; - } -} - -static expr_ty -ast_for_slice(struct compiling *c, const node *n) -{ - node *ch; - expr_ty lower = NULL, upper = NULL, step = NULL; - - REQ(n, subscript); - - /* - subscript: test | [test] ':' [test] [sliceop] - sliceop: ':' [test] - */ - ch = CHILD(n, 0); - if (NCH(n) == 1 && TYPE(ch) == test) { - return ast_for_expr(c, ch); - } - - if (TYPE(ch) == test) { - lower = ast_for_expr(c, ch); - if (!lower) - return NULL; - } - - /* If there's an upper bound it's in the second or third position. */ - if (TYPE(ch) == COLON) { - if (NCH(n) > 1) { - node *n2 = CHILD(n, 1); - - if (TYPE(n2) == test) { - upper = ast_for_expr(c, n2); - if (!upper) - return NULL; - } - } - } else if (NCH(n) > 2) { - node *n2 = CHILD(n, 2); - - if (TYPE(n2) == test) { - upper = ast_for_expr(c, n2); - if (!upper) - return NULL; - } - } - - ch = CHILD(n, NCH(n) - 1); - if (TYPE(ch) == sliceop) { - if (NCH(ch) != 1) { - ch = CHILD(ch, 1); - if (TYPE(ch) == test) { - step = ast_for_expr(c, ch); - if (!step) - return NULL; - } - } - } - - return Slice(lower, upper, step, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} - -static expr_ty -ast_for_binop(struct compiling *c, const node *n) -{ - /* Must account for a sequence of expressions. - How should A op B op C by represented? - BinOp(BinOp(A, op, B), op, C). - */ - - int i, nops; - expr_ty expr1, expr2, result; - operator_ty newoperator; - - expr1 = ast_for_expr(c, CHILD(n, 0)); - if (!expr1) - return NULL; - - expr2 = ast_for_expr(c, CHILD(n, 2)); - if (!expr2) - return NULL; - - newoperator = get_operator(c, CHILD(n, 1)); - if (!newoperator) - return NULL; - - result = BinOp(expr1, newoperator, expr2, LINENO(n), n->n_col_offset, - CHILD(n, 2)->n_end_lineno, CHILD(n, 2)->n_end_col_offset, - c->c_arena); - if (!result) - return NULL; - - nops = (NCH(n) - 1) / 2; - for (i = 1; i < nops; i++) { - expr_ty tmp_result, tmp; - const node* next_oper = CHILD(n, i * 2 + 1); - - newoperator = get_operator(c, next_oper); - if (!newoperator) - return NULL; - - tmp = ast_for_expr(c, CHILD(n, i * 2 + 2)); - if (!tmp) - return NULL; - - tmp_result = BinOp(result, newoperator, tmp, - LINENO(n), n->n_col_offset, - CHILD(n, i * 2 + 2)->n_end_lineno, - CHILD(n, i * 2 + 2)->n_end_col_offset, - c->c_arena); - if (!tmp_result) - return NULL; - result = tmp_result; - } - return result; -} - -static expr_ty -ast_for_trailer(struct compiling *c, const node *n, expr_ty left_expr, const node *start) -{ - /* trailer: '(' [arglist] ')' | '[' subscriptlist ']' | '.' NAME - subscriptlist: subscript (',' subscript)* [','] - subscript: '.' '.' '.' | test | [test] ':' [test] [sliceop] - */ - const node *n_copy = n; - REQ(n, trailer); - if (TYPE(CHILD(n, 0)) == LPAR) { - if (NCH(n) == 2) - return Call(left_expr, NULL, NULL, LINENO(start), start->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - else - return ast_for_call(c, CHILD(n, 1), left_expr, - start, CHILD(n, 0), CHILD(n, 2)); - } - else if (TYPE(CHILD(n, 0)) == DOT) { - PyObject *attr_id = NEW_IDENTIFIER(CHILD(n, 1)); - if (!attr_id) - return NULL; - return Attribute(left_expr, attr_id, Load, - LINENO(start), start->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - else { - REQ(CHILD(n, 0), LSQB); - REQ(CHILD(n, 2), RSQB); - n = CHILD(n, 1); - if (NCH(n) == 1) { - expr_ty slc = ast_for_slice(c, CHILD(n, 0)); - if (!slc) - return NULL; - return Subscript(left_expr, slc, Load, LINENO(start), start->n_col_offset, - n_copy->n_end_lineno, n_copy->n_end_col_offset, - c->c_arena); - } - else { - int j; - expr_ty slc, e; - asdl_seq *elts; - elts = _Py_asdl_seq_new((NCH(n) + 1) / 2, c->c_arena); - if (!elts) - return NULL; - for (j = 0; j < NCH(n); j += 2) { - slc = ast_for_slice(c, CHILD(n, j)); - if (!slc) - return NULL; - asdl_seq_SET(elts, j / 2, slc); - } - e = Tuple(elts, Load, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, - c->c_arena); - if (!e) - return NULL; - return Subscript(left_expr, e, - Load, LINENO(start), start->n_col_offset, - n_copy->n_end_lineno, n_copy->n_end_col_offset, - c->c_arena); - } - } -} - -static expr_ty -ast_for_factor(struct compiling *c, const node *n) -{ - expr_ty expression; - - expression = ast_for_expr(c, CHILD(n, 1)); - if (!expression) - return NULL; - - switch (TYPE(CHILD(n, 0))) { - case PLUS: - return UnaryOp(UAdd, expression, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, - c->c_arena); - case MINUS: - return UnaryOp(USub, expression, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, - c->c_arena); - case TILDE: - return UnaryOp(Invert, expression, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, - c->c_arena); - } - PyErr_Format(PyExc_SystemError, "unhandled factor: %d", - TYPE(CHILD(n, 0))); - return NULL; -} - -static expr_ty -ast_for_atom_expr(struct compiling *c, const node *n) -{ - int i, nch, start = 0; - expr_ty e; - - REQ(n, atom_expr); - nch = NCH(n); - - if (TYPE(CHILD(n, 0)) == AWAIT) { - if (c->c_feature_version < 5) { - ast_error(c, n, - "Await expressions are only supported in Python 3.5 and greater"); - return NULL; - } - start = 1; - assert(nch > 1); - } - - e = ast_for_atom(c, CHILD(n, start)); - if (!e) - return NULL; - if (nch == 1) - return e; - if (start && nch == 2) { - return Await(e, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - - for (i = start + 1; i < nch; i++) { - node *ch = CHILD(n, i); - if (TYPE(ch) != trailer) - break; - e = ast_for_trailer(c, ch, e, CHILD(n, start)); - if (!e) - return NULL; - } - - if (start) { - /* there was an 'await' */ - return Await(e, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - else { - return e; - } -} - -static expr_ty -ast_for_power(struct compiling *c, const node *n) -{ - /* power: atom trailer* ('**' factor)* - */ - expr_ty e; - REQ(n, power); - e = ast_for_atom_expr(c, CHILD(n, 0)); - if (!e) - return NULL; - if (NCH(n) == 1) - return e; - if (TYPE(CHILD(n, NCH(n) - 1)) == factor) { - expr_ty f = ast_for_expr(c, CHILD(n, NCH(n) - 1)); - if (!f) - return NULL; - e = BinOp(e, Pow, f, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - return e; -} - -static expr_ty -ast_for_starred(struct compiling *c, const node *n) -{ - expr_ty tmp; - REQ(n, star_expr); - - tmp = ast_for_expr(c, CHILD(n, 1)); - if (!tmp) - return NULL; - - /* The Load context is changed later. */ - return Starred(tmp, Load, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} - - -/* Do not name a variable 'expr'! Will cause a compile error. -*/ - -static expr_ty -ast_for_expr(struct compiling *c, const node *n) -{ - /* handle the full range of simple expressions - namedexpr_test: test [':=' test] - test: or_test ['if' or_test 'else' test] | lambdef - test_nocond: or_test | lambdef_nocond - or_test: and_test ('or' and_test)* - and_test: not_test ('and' not_test)* - not_test: 'not' not_test | comparison - comparison: expr (comp_op expr)* - expr: xor_expr ('|' xor_expr)* - xor_expr: and_expr ('^' and_expr)* - and_expr: shift_expr ('&' shift_expr)* - shift_expr: arith_expr (('<<'|'>>') arith_expr)* - arith_expr: term (('+'|'-') term)* - term: factor (('*'|'@'|'/'|'%'|'//') factor)* - factor: ('+'|'-'|'~') factor | power - power: atom_expr ['**' factor] - atom_expr: [AWAIT] atom trailer* - yield_expr: 'yield' [yield_arg] - */ - - asdl_seq *seq; - int i; - - loop: - switch (TYPE(n)) { - case namedexpr_test: - if (NCH(n) == 3) - return ast_for_namedexpr(c, n); - /* Fallthrough */ - case test: - case test_nocond: - if (TYPE(CHILD(n, 0)) == lambdef || - TYPE(CHILD(n, 0)) == lambdef_nocond) - return ast_for_lambdef(c, CHILD(n, 0)); - else if (NCH(n) > 1) - return ast_for_ifexpr(c, n); - /* Fallthrough */ - case or_test: - case and_test: - if (NCH(n) == 1) { - n = CHILD(n, 0); - goto loop; - } - seq = _Py_asdl_seq_new((NCH(n) + 1) / 2, c->c_arena); - if (!seq) - return NULL; - for (i = 0; i < NCH(n); i += 2) { - expr_ty e = ast_for_expr(c, CHILD(n, i)); - if (!e) - return NULL; - asdl_seq_SET(seq, i / 2, e); - } - if (!strcmp(STR(CHILD(n, 1)), "and")) - return BoolOp(And, seq, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, - c->c_arena); - assert(!strcmp(STR(CHILD(n, 1)), "or")); - return BoolOp(Or, seq, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - case not_test: - if (NCH(n) == 1) { - n = CHILD(n, 0); - goto loop; - } - else { - expr_ty expression = ast_for_expr(c, CHILD(n, 1)); - if (!expression) - return NULL; - - return UnaryOp(Not, expression, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, - c->c_arena); - } - case comparison: - if (NCH(n) == 1) { - n = CHILD(n, 0); - goto loop; - } - else { - expr_ty expression; - asdl_int_seq *ops; - asdl_seq *cmps; - ops = _Py_asdl_int_seq_new(NCH(n) / 2, c->c_arena); - if (!ops) - return NULL; - cmps = _Py_asdl_seq_new(NCH(n) / 2, c->c_arena); - if (!cmps) { - return NULL; - } - for (i = 1; i < NCH(n); i += 2) { - cmpop_ty newoperator; - - newoperator = ast_for_comp_op(c, CHILD(n, i)); - if (!newoperator) { - return NULL; - } - - expression = ast_for_expr(c, CHILD(n, i + 1)); - if (!expression) { - return NULL; - } - - asdl_seq_SET(ops, i / 2, newoperator); - asdl_seq_SET(cmps, i / 2, expression); - } - expression = ast_for_expr(c, CHILD(n, 0)); - if (!expression) { - return NULL; - } - - return Compare(expression, ops, cmps, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - - case star_expr: - return ast_for_starred(c, n); - /* The next five cases all handle BinOps. The main body of code - is the same in each case, but the switch turned inside out to - reuse the code for each type of operator. - */ - case expr: - case xor_expr: - case and_expr: - case shift_expr: - case arith_expr: - case term: - if (NCH(n) == 1) { - n = CHILD(n, 0); - goto loop; - } - return ast_for_binop(c, n); - case yield_expr: { - node *an = NULL; - node *en = NULL; - int is_from = 0; - expr_ty exp = NULL; - if (NCH(n) > 1) - an = CHILD(n, 1); /* yield_arg */ - if (an) { - en = CHILD(an, NCH(an) - 1); - if (NCH(an) == 2) { - is_from = 1; - exp = ast_for_expr(c, en); - } - else - exp = ast_for_testlist(c, en); - if (!exp) - return NULL; - } - if (is_from) - return YieldFrom(exp, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - return Yield(exp, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - case factor: - if (NCH(n) == 1) { - n = CHILD(n, 0); - goto loop; - } - return ast_for_factor(c, n); - case power: - return ast_for_power(c, n); - default: - PyErr_Format(PyExc_SystemError, "unhandled expr: %d", TYPE(n)); - return NULL; - } - /* should never get here unless if error is set */ - return NULL; -} - -static expr_ty -ast_for_call(struct compiling *c, const node *n, expr_ty func, - const node *start, const node *maybegenbeg, const node *closepar) -{ - /* - arglist: argument (',' argument)* [','] - argument: ( test [comp_for] | '*' test | test '=' test | '**' test ) - */ - - int i, nargs, nkeywords; - int ndoublestars; - asdl_seq *args; - asdl_seq *keywords; - - REQ(n, arglist); - - nargs = 0; - nkeywords = 0; - for (i = 0; i < NCH(n); i++) { - node *ch = CHILD(n, i); - if (TYPE(ch) == argument) { - if (NCH(ch) == 1) - nargs++; - else if (TYPE(CHILD(ch, 1)) == comp_for) { - nargs++; - if (!maybegenbeg) { - ast_error(c, ch, "invalid syntax"); - return NULL; - } - if (NCH(n) > 1) { - ast_error(c, ch, "Generator expression must be parenthesized"); - return NULL; - } - } - else if (TYPE(CHILD(ch, 0)) == STAR) - nargs++; - else if (TYPE(CHILD(ch, 1)) == COLONEQUAL) { - nargs++; - } - else - /* TYPE(CHILD(ch, 0)) == DOUBLESTAR or keyword argument */ - nkeywords++; - } - } - - args = _Py_asdl_seq_new(nargs, c->c_arena); - if (!args) - return NULL; - keywords = _Py_asdl_seq_new(nkeywords, c->c_arena); - if (!keywords) - return NULL; - - nargs = 0; /* positional arguments + iterable argument unpackings */ - nkeywords = 0; /* keyword arguments + keyword argument unpackings */ - ndoublestars = 0; /* just keyword argument unpackings */ - for (i = 0; i < NCH(n); i++) { - node *ch = CHILD(n, i); - if (TYPE(ch) == argument) { - expr_ty e; - node *chch = CHILD(ch, 0); - if (NCH(ch) == 1) { - /* a positional argument */ - if (nkeywords) { - if (ndoublestars) { - ast_error(c, chch, - "positional argument follows " - "keyword argument unpacking"); - } - else { - ast_error(c, chch, - "positional argument follows " - "keyword argument"); - } - return NULL; - } - e = ast_for_expr(c, chch); - if (!e) - return NULL; - asdl_seq_SET(args, nargs++, e); - } - else if (TYPE(chch) == STAR) { - /* an iterable argument unpacking */ - expr_ty starred; - if (ndoublestars) { - ast_error(c, chch, - "iterable argument unpacking follows " - "keyword argument unpacking"); - return NULL; - } - e = ast_for_expr(c, CHILD(ch, 1)); - if (!e) - return NULL; - starred = Starred(e, Load, LINENO(chch), - chch->n_col_offset, - e->end_lineno, e->end_col_offset, - c->c_arena); - if (!starred) - return NULL; - asdl_seq_SET(args, nargs++, starred); - - } - else if (TYPE(chch) == DOUBLESTAR) { - /* a keyword argument unpacking */ - keyword_ty kw; - i++; - e = ast_for_expr(c, CHILD(ch, 1)); - if (!e) - return NULL; - kw = keyword(NULL, e, chch->n_lineno, chch->n_col_offset, - e->end_lineno, e->end_col_offset, c->c_arena); - asdl_seq_SET(keywords, nkeywords++, kw); - ndoublestars++; - } - else if (TYPE(CHILD(ch, 1)) == comp_for) { - /* the lone generator expression */ - e = copy_location(ast_for_genexp(c, ch), maybegenbeg, closepar); - if (!e) - return NULL; - asdl_seq_SET(args, nargs++, e); - } - else if (TYPE(CHILD(ch, 1)) == COLONEQUAL) { - /* treat colon equal as positional argument */ - if (nkeywords) { - if (ndoublestars) { - ast_error(c, chch, - "positional argument follows " - "keyword argument unpacking"); - } - else { - ast_error(c, chch, - "positional argument follows " - "keyword argument"); - } - return NULL; - } - e = ast_for_namedexpr(c, ch); - if (!e) - return NULL; - asdl_seq_SET(args, nargs++, e); - } - else { - /* a keyword argument */ - keyword_ty kw; - identifier key; - - // To remain LL(1), the grammar accepts any test (basically, any - // expression) in the keyword slot of a call site. So, we need - // to manually enforce that the keyword is a NAME here. - static const int name_tree[] = { - test, - or_test, - and_test, - not_test, - comparison, - expr, - xor_expr, - and_expr, - shift_expr, - arith_expr, - term, - factor, - power, - atom_expr, - atom, - 0, - }; - node *expr_node = chch; - for (int i = 0; name_tree[i]; i++) { - if (TYPE(expr_node) != name_tree[i]) - break; - if (NCH(expr_node) != 1) - break; - expr_node = CHILD(expr_node, 0); - } - if (TYPE(expr_node) != NAME) { - ast_error(c, chch, - "expression cannot contain assignment, " - "perhaps you meant \"==\"?"); - return NULL; - } - key = new_identifier(STR(expr_node), c); - if (key == NULL) { - return NULL; - } - if (forbidden_name(c, key, chch, 1)) { - return NULL; - } - e = ast_for_expr(c, CHILD(ch, 2)); - if (!e) - return NULL; - kw = keyword(key, e, chch->n_lineno, chch->n_col_offset, - e->end_lineno, e->end_col_offset, c->c_arena); - - if (!kw) - return NULL; - asdl_seq_SET(keywords, nkeywords++, kw); - } - } - } - - return Call(func, args, keywords, LINENO(start), start->n_col_offset, - closepar->n_end_lineno, closepar->n_end_col_offset, c->c_arena); -} - -static expr_ty -ast_for_testlist(struct compiling *c, const node* n) -{ - /* testlist_comp: test (comp_for | (',' test)* [',']) */ - /* testlist: test (',' test)* [','] */ - assert(NCH(n) > 0); - if (TYPE(n) == testlist_comp) { - if (NCH(n) > 1) - assert(TYPE(CHILD(n, 1)) != comp_for); - } - else { - assert(TYPE(n) == testlist || - TYPE(n) == testlist_star_expr); - } - if (NCH(n) == 1) - return ast_for_expr(c, CHILD(n, 0)); - else { - asdl_seq *tmp = seq_for_testlist(c, n); - if (!tmp) - return NULL; - return Tuple(tmp, Load, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } -} - -static stmt_ty -ast_for_expr_stmt(struct compiling *c, const node *n) -{ - REQ(n, expr_stmt); - /* expr_stmt: testlist_star_expr (annassign | augassign (yield_expr|testlist) | - [('=' (yield_expr|testlist_star_expr))+ [TYPE_COMMENT]] ) - annassign: ':' test ['=' (yield_expr|testlist)] - testlist_star_expr: (test|star_expr) (',' (test|star_expr))* [','] - augassign: ('+=' | '-=' | '*=' | '@=' | '/=' | '%=' | '&=' | '|=' | '^=' | - '<<=' | '>>=' | '**=' | '//=') - test: ... here starts the operator precedence dance - */ - int num = NCH(n); - - if (num == 1) { - expr_ty e = ast_for_testlist(c, CHILD(n, 0)); - if (!e) - return NULL; - - return Expr(e, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - else if (TYPE(CHILD(n, 1)) == augassign) { - expr_ty expr1, expr2; - operator_ty newoperator; - node *ch = CHILD(n, 0); - - expr1 = ast_for_testlist(c, ch); - if (!expr1) - return NULL; - /* Augmented assignments can only have a name, a subscript, or an - attribute on the left, though, so we have to explicitly check for - those. */ - switch (expr1->kind) { - case Name_kind: - case Attribute_kind: - case Subscript_kind: - break; - default: - ast_error(c, ch, "'%s' is an illegal expression for augmented assignment", - get_expr_name(expr1)); - return NULL; - } - - /* set_context checks that most expressions are not the left side. */ - if(!set_context(c, expr1, Store, ch)) { - return NULL; - } - - ch = CHILD(n, 2); - if (TYPE(ch) == testlist) - expr2 = ast_for_testlist(c, ch); - else - expr2 = ast_for_expr(c, ch); - if (!expr2) - return NULL; - - newoperator = ast_for_augassign(c, CHILD(n, 1)); - if (!newoperator) - return NULL; - - return AugAssign(expr1, newoperator, expr2, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - else if (TYPE(CHILD(n, 1)) == annassign) { - expr_ty expr1, expr2, expr3; - node *ch = CHILD(n, 0); - node *deep, *ann = CHILD(n, 1); - int simple = 1; - - /* AnnAssigns are only allowed in Python 3.6 or greater */ - if (c->c_feature_version < 6) { - ast_error(c, ch, - "Variable annotation syntax is only supported in Python 3.6 and greater"); - return NULL; - } - - /* we keep track of parens to qualify (x) as expression not name */ - deep = ch; - while (NCH(deep) == 1) { - deep = CHILD(deep, 0); - } - if (NCH(deep) > 0 && TYPE(CHILD(deep, 0)) == LPAR) { - simple = 0; - } - expr1 = ast_for_testlist(c, ch); - if (!expr1) { - return NULL; - } - switch (expr1->kind) { - case Name_kind: - if (forbidden_name(c, expr1->v.Name.id, n, 0)) { - return NULL; - } - expr1->v.Name.ctx = Store; - break; - case Attribute_kind: - if (forbidden_name(c, expr1->v.Attribute.attr, n, 1)) { - return NULL; - } - expr1->v.Attribute.ctx = Store; - break; - case Subscript_kind: - expr1->v.Subscript.ctx = Store; - break; - case List_kind: - ast_error(c, ch, - "only single target (not list) can be annotated"); - return NULL; - case Tuple_kind: - ast_error(c, ch, - "only single target (not tuple) can be annotated"); - return NULL; - default: - ast_error(c, ch, - "illegal target for annotation"); - return NULL; - } - - if (expr1->kind != Name_kind) { - simple = 0; - } - ch = CHILD(ann, 1); - expr2 = ast_for_expr(c, ch); - if (!expr2) { - return NULL; - } - if (NCH(ann) == 2) { - return AnnAssign(expr1, expr2, NULL, simple, - LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - else { - ch = CHILD(ann, 3); - if (TYPE(ch) == testlist_star_expr) { - expr3 = ast_for_testlist(c, ch); - } - else { - expr3 = ast_for_expr(c, ch); - } - if (!expr3) { - return NULL; - } - return AnnAssign(expr1, expr2, expr3, simple, - LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - } - else { - int i, nch_minus_type, has_type_comment; - asdl_seq *targets; - node *value; - expr_ty expression; - string type_comment; - - /* a normal assignment */ - REQ(CHILD(n, 1), EQUAL); - - has_type_comment = TYPE(CHILD(n, num - 1)) == TYPE_COMMENT; - nch_minus_type = num - has_type_comment; - - targets = _Py_asdl_seq_new(nch_minus_type / 2, c->c_arena); - if (!targets) - return NULL; - for (i = 0; i < nch_minus_type - 2; i += 2) { - expr_ty e; - node *ch = CHILD(n, i); - if (TYPE(ch) == yield_expr) { - ast_error(c, ch, "assignment to yield expression not possible"); - return NULL; - } - e = ast_for_testlist(c, ch); - if (!e) - return NULL; - - /* set context to assign */ - if (!set_context(c, e, Store, CHILD(n, i))) - return NULL; - - asdl_seq_SET(targets, i / 2, e); - } - value = CHILD(n, nch_minus_type - 1); - if (TYPE(value) == testlist_star_expr) - expression = ast_for_testlist(c, value); - else - expression = ast_for_expr(c, value); - if (!expression) - return NULL; - if (has_type_comment) { - type_comment = NEW_TYPE_COMMENT(CHILD(n, nch_minus_type)); - if (!type_comment) - return NULL; - } - else - type_comment = NULL; - return Assign(targets, expression, type_comment, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } -} - - -static asdl_seq * -ast_for_exprlist(struct compiling *c, const node *n, expr_context_ty context) -{ - asdl_seq *seq; - int i; - expr_ty e; - - REQ(n, exprlist); - - seq = _Py_asdl_seq_new((NCH(n) + 1) / 2, c->c_arena); - if (!seq) - return NULL; - for (i = 0; i < NCH(n); i += 2) { - e = ast_for_expr(c, CHILD(n, i)); - if (!e) - return NULL; - asdl_seq_SET(seq, i / 2, e); - if (context && !set_context(c, e, context, CHILD(n, i))) - return NULL; - } - return seq; -} - -static stmt_ty -ast_for_del_stmt(struct compiling *c, const node *n) -{ - asdl_seq *expr_list; - - /* del_stmt: 'del' exprlist */ - REQ(n, del_stmt); - - expr_list = ast_for_exprlist(c, CHILD(n, 1), Del); - if (!expr_list) - return NULL; - return Delete(expr_list, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} - -static stmt_ty -ast_for_flow_stmt(struct compiling *c, const node *n) -{ - /* - flow_stmt: break_stmt | continue_stmt | return_stmt | raise_stmt - | yield_stmt - break_stmt: 'break' - continue_stmt: 'continue' - return_stmt: 'return' [testlist] - yield_stmt: yield_expr - yield_expr: 'yield' testlist | 'yield' 'from' test - raise_stmt: 'raise' [test [',' test [',' test]]] - */ - node *ch; - - REQ(n, flow_stmt); - ch = CHILD(n, 0); - switch (TYPE(ch)) { - case break_stmt: - return Break(LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - case continue_stmt: - return Continue(LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - case yield_stmt: { /* will reduce to yield_expr */ - expr_ty exp = ast_for_expr(c, CHILD(ch, 0)); - if (!exp) - return NULL; - return Expr(exp, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - case return_stmt: - if (NCH(ch) == 1) - return Return(NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - else { - expr_ty expression = ast_for_testlist(c, CHILD(ch, 1)); - if (!expression) - return NULL; - return Return(expression, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - case raise_stmt: - if (NCH(ch) == 1) - return Raise(NULL, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - else if (NCH(ch) >= 2) { - expr_ty cause = NULL; - expr_ty expression = ast_for_expr(c, CHILD(ch, 1)); - if (!expression) - return NULL; - if (NCH(ch) == 4) { - cause = ast_for_expr(c, CHILD(ch, 3)); - if (!cause) - return NULL; - } - return Raise(expression, cause, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - /* fall through */ - default: - PyErr_Format(PyExc_SystemError, - "unexpected flow_stmt: %d", TYPE(ch)); - return NULL; - } -} - -static alias_ty -alias_for_import_name(struct compiling *c, const node *n, int store) -{ - /* - import_as_name: NAME ['as' NAME] - dotted_as_name: dotted_name ['as' NAME] - dotted_name: NAME ('.' NAME)* - */ - identifier str, name; - - loop: - switch (TYPE(n)) { - case import_as_name: { - node *name_node = CHILD(n, 0); - str = NULL; - name = NEW_IDENTIFIER(name_node); - if (!name) - return NULL; - if (NCH(n) == 3) { - node *str_node = CHILD(n, 2); - str = NEW_IDENTIFIER(str_node); - if (!str) - return NULL; - if (store && forbidden_name(c, str, str_node, 0)) - return NULL; - } - else { - if (forbidden_name(c, name, name_node, 0)) - return NULL; - } - return alias(name, str, c->c_arena); - } - case dotted_as_name: - if (NCH(n) == 1) { - n = CHILD(n, 0); - goto loop; - } - else { - node *asname_node = CHILD(n, 2); - alias_ty a = alias_for_import_name(c, CHILD(n, 0), 0); - if (!a) - return NULL; - assert(!a->asname); - a->asname = NEW_IDENTIFIER(asname_node); - if (!a->asname) - return NULL; - if (forbidden_name(c, a->asname, asname_node, 0)) - return NULL; - return a; - } - case dotted_name: - if (NCH(n) == 1) { - node *name_node = CHILD(n, 0); - name = NEW_IDENTIFIER(name_node); - if (!name) - return NULL; - if (store && forbidden_name(c, name, name_node, 0)) - return NULL; - return alias(name, NULL, c->c_arena); - } - else { - /* Create a string of the form "a.b.c" */ - int i; - size_t len; - char *s; - PyObject *uni; - - len = 0; - for (i = 0; i < NCH(n); i += 2) - /* length of string plus one for the dot */ - len += strlen(STR(CHILD(n, i))) + 1; - len--; /* the last name doesn't have a dot */ - str = PyBytes_FromStringAndSize(NULL, len); - if (!str) - return NULL; - s = PyBytes_AS_STRING(str); - if (!s) - return NULL; - for (i = 0; i < NCH(n); i += 2) { - char *sch = STR(CHILD(n, i)); - strcpy(s, STR(CHILD(n, i))); - s += strlen(sch); - *s++ = '.'; - } - --s; - *s = '\0'; - uni = PyUnicode_DecodeUTF8(PyBytes_AS_STRING(str), - PyBytes_GET_SIZE(str), - NULL); - Py_DECREF(str); - if (!uni) - return NULL; - str = uni; - PyUnicode_InternInPlace(&str); - if (PyArena_AddPyObject(c->c_arena, str) < 0) { - Py_DECREF(str); - return NULL; - } - return alias(str, NULL, c->c_arena); - } - case STAR: - str = PyUnicode_InternFromString("*"); - if (!str) - return NULL; - if (PyArena_AddPyObject(c->c_arena, str) < 0) { - Py_DECREF(str); - return NULL; - } - return alias(str, NULL, c->c_arena); - default: - PyErr_Format(PyExc_SystemError, - "unexpected import name: %d", TYPE(n)); - return NULL; - } -} - -static stmt_ty -ast_for_import_stmt(struct compiling *c, const node *n) -{ - /* - import_stmt: import_name | import_from - import_name: 'import' dotted_as_names - import_from: 'from' (('.' | '...')* dotted_name | ('.' | '...')+) - 'import' ('*' | '(' import_as_names ')' | import_as_names) - */ - int lineno; - int col_offset; - int i; - asdl_seq *aliases; - - REQ(n, import_stmt); - lineno = LINENO(n); - col_offset = n->n_col_offset; - n = CHILD(n, 0); - if (TYPE(n) == import_name) { - n = CHILD(n, 1); - REQ(n, dotted_as_names); - aliases = _Py_asdl_seq_new((NCH(n) + 1) / 2, c->c_arena); - if (!aliases) - return NULL; - for (i = 0; i < NCH(n); i += 2) { - alias_ty import_alias = alias_for_import_name(c, CHILD(n, i), 1); - if (!import_alias) - return NULL; - asdl_seq_SET(aliases, i / 2, import_alias); - } - // Even though n is modified above, the end position is not changed - return Import(aliases, lineno, col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - else if (TYPE(n) == import_from) { - int n_children; - int idx, ndots = 0; - const node *n_copy = n; - alias_ty mod = NULL; - identifier modname = NULL; - - /* Count the number of dots (for relative imports) and check for the - optional module name */ - for (idx = 1; idx < NCH(n); idx++) { - if (TYPE(CHILD(n, idx)) == dotted_name) { - mod = alias_for_import_name(c, CHILD(n, idx), 0); - if (!mod) - return NULL; - idx++; - break; - } else if (TYPE(CHILD(n, idx)) == ELLIPSIS) { - /* three consecutive dots are tokenized as one ELLIPSIS */ - ndots += 3; - continue; - } else if (TYPE(CHILD(n, idx)) != DOT) { - break; - } - ndots++; - } - idx++; /* skip over the 'import' keyword */ - switch (TYPE(CHILD(n, idx))) { - case STAR: - /* from ... import * */ - n = CHILD(n, idx); - n_children = 1; - break; - case LPAR: - /* from ... import (x, y, z) */ - n = CHILD(n, idx + 1); - n_children = NCH(n); - break; - case import_as_names: - /* from ... import x, y, z */ - n = CHILD(n, idx); - n_children = NCH(n); - if (n_children % 2 == 0) { - ast_error(c, n, - "trailing comma not allowed without" - " surrounding parentheses"); - return NULL; - } - break; - default: - ast_error(c, n, "Unexpected node-type in from-import"); - return NULL; - } - - aliases = _Py_asdl_seq_new((n_children + 1) / 2, c->c_arena); - if (!aliases) - return NULL; - - /* handle "from ... import *" special b/c there's no children */ - if (TYPE(n) == STAR) { - alias_ty import_alias = alias_for_import_name(c, n, 1); - if (!import_alias) - return NULL; - asdl_seq_SET(aliases, 0, import_alias); - } - else { - for (i = 0; i < NCH(n); i += 2) { - alias_ty import_alias = alias_for_import_name(c, CHILD(n, i), 1); - if (!import_alias) - return NULL; - asdl_seq_SET(aliases, i / 2, import_alias); - } - } - if (mod != NULL) - modname = mod->name; - return ImportFrom(modname, aliases, ndots, lineno, col_offset, - n_copy->n_end_lineno, n_copy->n_end_col_offset, - c->c_arena); - } - PyErr_Format(PyExc_SystemError, - "unknown import statement: starts with command '%s'", - STR(CHILD(n, 0))); - return NULL; -} - -static stmt_ty -ast_for_global_stmt(struct compiling *c, const node *n) -{ - /* global_stmt: 'global' NAME (',' NAME)* */ - identifier name; - asdl_seq *s; - int i; - - REQ(n, global_stmt); - s = _Py_asdl_seq_new(NCH(n) / 2, c->c_arena); - if (!s) - return NULL; - for (i = 1; i < NCH(n); i += 2) { - name = NEW_IDENTIFIER(CHILD(n, i)); - if (!name) - return NULL; - asdl_seq_SET(s, i / 2, name); - } - return Global(s, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} - -static stmt_ty -ast_for_nonlocal_stmt(struct compiling *c, const node *n) -{ - /* nonlocal_stmt: 'nonlocal' NAME (',' NAME)* */ - identifier name; - asdl_seq *s; - int i; - - REQ(n, nonlocal_stmt); - s = _Py_asdl_seq_new(NCH(n) / 2, c->c_arena); - if (!s) - return NULL; - for (i = 1; i < NCH(n); i += 2) { - name = NEW_IDENTIFIER(CHILD(n, i)); - if (!name) - return NULL; - asdl_seq_SET(s, i / 2, name); - } - return Nonlocal(s, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} - -static stmt_ty -ast_for_assert_stmt(struct compiling *c, const node *n) -{ - /* assert_stmt: 'assert' test [',' test] */ - REQ(n, assert_stmt); - if (NCH(n) == 2) { - expr_ty expression = ast_for_expr(c, CHILD(n, 1)); - if (!expression) - return NULL; - return Assert(expression, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - else if (NCH(n) == 4) { - expr_ty expr1, expr2; - - expr1 = ast_for_expr(c, CHILD(n, 1)); - if (!expr1) - return NULL; - expr2 = ast_for_expr(c, CHILD(n, 3)); - if (!expr2) - return NULL; - - return Assert(expr1, expr2, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - PyErr_Format(PyExc_SystemError, - "improper number of parts to 'assert' statement: %d", - NCH(n)); - return NULL; -} - -static asdl_seq * -ast_for_suite(struct compiling *c, const node *n) -{ - /* suite: simple_stmt | NEWLINE [TYPE_COMMENT NEWLINE] INDENT stmt+ DEDENT */ - asdl_seq *seq; - stmt_ty s; - int i, total, num, end, pos = 0; - node *ch; - - if (TYPE(n) != func_body_suite) { - REQ(n, suite); - } - - total = num_stmts(n); - seq = _Py_asdl_seq_new(total, c->c_arena); - if (!seq) - return NULL; - if (TYPE(CHILD(n, 0)) == simple_stmt) { - n = CHILD(n, 0); - /* simple_stmt always ends with a NEWLINE, - and may have a trailing SEMI - */ - end = NCH(n) - 1; - if (TYPE(CHILD(n, end - 1)) == SEMI) - end--; - /* loop by 2 to skip semi-colons */ - for (i = 0; i < end; i += 2) { - ch = CHILD(n, i); - s = ast_for_stmt(c, ch); - if (!s) - return NULL; - asdl_seq_SET(seq, pos++, s); - } - } - else { - i = 2; - if (TYPE(CHILD(n, 1)) == TYPE_COMMENT) { - i += 2; - REQ(CHILD(n, 2), NEWLINE); - } - - for (; i < (NCH(n) - 1); i++) { - ch = CHILD(n, i); - REQ(ch, stmt); - num = num_stmts(ch); - if (num == 1) { - /* small_stmt or compound_stmt with only one child */ - s = ast_for_stmt(c, ch); - if (!s) - return NULL; - asdl_seq_SET(seq, pos++, s); - } - else { - int j; - ch = CHILD(ch, 0); - REQ(ch, simple_stmt); - for (j = 0; j < NCH(ch); j += 2) { - /* statement terminates with a semi-colon ';' */ - if (NCH(CHILD(ch, j)) == 0) { - assert((j + 1) == NCH(ch)); - break; - } - s = ast_for_stmt(c, CHILD(ch, j)); - if (!s) - return NULL; - asdl_seq_SET(seq, pos++, s); - } - } - } - } - assert(pos == seq->size); - return seq; -} - -static void -get_last_end_pos(asdl_seq *s, int *end_lineno, int *end_col_offset) -{ - Py_ssize_t tot = asdl_seq_LEN(s); - // There must be no empty suites. - assert(tot > 0); - stmt_ty last = asdl_seq_GET(s, tot - 1); - *end_lineno = last->end_lineno; - *end_col_offset = last->end_col_offset; -} - -static stmt_ty -ast_for_if_stmt(struct compiling *c, const node *n) -{ - /* if_stmt: 'if' test ':' suite ('elif' test ':' suite)* - ['else' ':' suite] - */ - char *s; - int end_lineno, end_col_offset; - - REQ(n, if_stmt); - - if (NCH(n) == 4) { - expr_ty expression; - asdl_seq *suite_seq; - - expression = ast_for_expr(c, CHILD(n, 1)); - if (!expression) - return NULL; - suite_seq = ast_for_suite(c, CHILD(n, 3)); - if (!suite_seq) - return NULL; - get_last_end_pos(suite_seq, &end_lineno, &end_col_offset); - - return If(expression, suite_seq, NULL, LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - - s = STR(CHILD(n, 4)); - /* s[2], the third character in the string, will be - 's' for el_s_e, or - 'i' for el_i_f - */ - if (s[2] == 's') { - expr_ty expression; - asdl_seq *seq1, *seq2; - - expression = ast_for_expr(c, CHILD(n, 1)); - if (!expression) - return NULL; - seq1 = ast_for_suite(c, CHILD(n, 3)); - if (!seq1) - return NULL; - seq2 = ast_for_suite(c, CHILD(n, 6)); - if (!seq2) - return NULL; - get_last_end_pos(seq2, &end_lineno, &end_col_offset); - - return If(expression, seq1, seq2, LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - else if (s[2] == 'i') { - int i, n_elif, has_else = 0; - expr_ty expression; - asdl_seq *suite_seq; - asdl_seq *orelse = NULL; - n_elif = NCH(n) - 4; - /* must reference the child n_elif+1 since 'else' token is third, - not fourth, child from the end. */ - if (TYPE(CHILD(n, (n_elif + 1))) == NAME - && STR(CHILD(n, (n_elif + 1)))[2] == 's') { - has_else = 1; - n_elif -= 3; - } - n_elif /= 4; - - if (has_else) { - asdl_seq *suite_seq2; - - orelse = _Py_asdl_seq_new(1, c->c_arena); - if (!orelse) - return NULL; - expression = ast_for_expr(c, CHILD(n, NCH(n) - 6)); - if (!expression) - return NULL; - suite_seq = ast_for_suite(c, CHILD(n, NCH(n) - 4)); - if (!suite_seq) - return NULL; - suite_seq2 = ast_for_suite(c, CHILD(n, NCH(n) - 1)); - if (!suite_seq2) - return NULL; - get_last_end_pos(suite_seq2, &end_lineno, &end_col_offset); - - asdl_seq_SET(orelse, 0, - If(expression, suite_seq, suite_seq2, - LINENO(CHILD(n, NCH(n) - 7)), - CHILD(n, NCH(n) - 7)->n_col_offset, - end_lineno, end_col_offset, c->c_arena)); - /* the just-created orelse handled the last elif */ - n_elif--; - } - - for (i = 0; i < n_elif; i++) { - int off = 5 + (n_elif - i - 1) * 4; - asdl_seq *newobj = _Py_asdl_seq_new(1, c->c_arena); - if (!newobj) - return NULL; - expression = ast_for_expr(c, CHILD(n, off)); - if (!expression) - return NULL; - suite_seq = ast_for_suite(c, CHILD(n, off + 2)); - if (!suite_seq) - return NULL; - - if (orelse != NULL) { - get_last_end_pos(orelse, &end_lineno, &end_col_offset); - } else { - get_last_end_pos(suite_seq, &end_lineno, &end_col_offset); - } - asdl_seq_SET(newobj, 0, - If(expression, suite_seq, orelse, - LINENO(CHILD(n, off - 1)), - CHILD(n, off - 1)->n_col_offset, - end_lineno, end_col_offset, c->c_arena)); - orelse = newobj; - } - expression = ast_for_expr(c, CHILD(n, 1)); - if (!expression) - return NULL; - suite_seq = ast_for_suite(c, CHILD(n, 3)); - if (!suite_seq) - return NULL; - get_last_end_pos(orelse, &end_lineno, &end_col_offset); - return If(expression, suite_seq, orelse, - LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - - PyErr_Format(PyExc_SystemError, - "unexpected token in 'if' statement: %s", s); - return NULL; -} - -static stmt_ty -ast_for_while_stmt(struct compiling *c, const node *n) -{ - /* while_stmt: 'while' test ':' suite ['else' ':' suite] */ - REQ(n, while_stmt); - int end_lineno, end_col_offset; - - if (NCH(n) == 4) { - expr_ty expression; - asdl_seq *suite_seq; - - expression = ast_for_expr(c, CHILD(n, 1)); - if (!expression) - return NULL; - suite_seq = ast_for_suite(c, CHILD(n, 3)); - if (!suite_seq) - return NULL; - get_last_end_pos(suite_seq, &end_lineno, &end_col_offset); - return While(expression, suite_seq, NULL, LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - else if (NCH(n) == 7) { - expr_ty expression; - asdl_seq *seq1, *seq2; - - expression = ast_for_expr(c, CHILD(n, 1)); - if (!expression) - return NULL; - seq1 = ast_for_suite(c, CHILD(n, 3)); - if (!seq1) - return NULL; - seq2 = ast_for_suite(c, CHILD(n, 6)); - if (!seq2) - return NULL; - get_last_end_pos(seq2, &end_lineno, &end_col_offset); - - return While(expression, seq1, seq2, LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - - PyErr_Format(PyExc_SystemError, - "wrong number of tokens for 'while' statement: %d", - NCH(n)); - return NULL; -} - -static stmt_ty -ast_for_for_stmt(struct compiling *c, const node *n0, bool is_async) -{ - const node * const n = is_async ? CHILD(n0, 1) : n0; - asdl_seq *_target, *seq = NULL, *suite_seq; - expr_ty expression; - expr_ty target, first; - const node *node_target; - int end_lineno, end_col_offset; - int has_type_comment; - string type_comment; - - if (is_async && c->c_feature_version < 5) { - ast_error(c, n, - "Async for loops are only supported in Python 3.5 and greater"); - return NULL; - } - - /* for_stmt: 'for' exprlist 'in' testlist ':' [TYPE_COMMENT] suite ['else' ':' suite] */ - REQ(n, for_stmt); - - has_type_comment = TYPE(CHILD(n, 5)) == TYPE_COMMENT; - - if (NCH(n) == 9 + has_type_comment) { - seq = ast_for_suite(c, CHILD(n, 8 + has_type_comment)); - if (!seq) - return NULL; - } - - node_target = CHILD(n, 1); - _target = ast_for_exprlist(c, node_target, Store); - if (!_target) - return NULL; - /* Check the # of children rather than the length of _target, since - for x, in ... has 1 element in _target, but still requires a Tuple. */ - first = (expr_ty)asdl_seq_GET(_target, 0); - if (NCH(node_target) == 1) - target = first; - else - target = Tuple(_target, Store, first->lineno, first->col_offset, - node_target->n_end_lineno, node_target->n_end_col_offset, - c->c_arena); - - expression = ast_for_testlist(c, CHILD(n, 3)); - if (!expression) - return NULL; - suite_seq = ast_for_suite(c, CHILD(n, 5 + has_type_comment)); - if (!suite_seq) - return NULL; - - if (seq != NULL) { - get_last_end_pos(seq, &end_lineno, &end_col_offset); - } else { - get_last_end_pos(suite_seq, &end_lineno, &end_col_offset); - } - - if (has_type_comment) { - type_comment = NEW_TYPE_COMMENT(CHILD(n, 5)); - if (!type_comment) - return NULL; - } - else - type_comment = NULL; - - if (is_async) - return AsyncFor(target, expression, suite_seq, seq, type_comment, - LINENO(n0), n0->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - else - return For(target, expression, suite_seq, seq, type_comment, - LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); -} - -static excepthandler_ty -ast_for_except_clause(struct compiling *c, const node *exc, node *body) -{ - /* except_clause: 'except' [test ['as' test]] */ - int end_lineno, end_col_offset; - REQ(exc, except_clause); - REQ(body, suite); - - if (NCH(exc) == 1) { - asdl_seq *suite_seq = ast_for_suite(c, body); - if (!suite_seq) - return NULL; - get_last_end_pos(suite_seq, &end_lineno, &end_col_offset); - - return ExceptHandler(NULL, NULL, suite_seq, LINENO(exc), - exc->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - else if (NCH(exc) == 2) { - expr_ty expression; - asdl_seq *suite_seq; - - expression = ast_for_expr(c, CHILD(exc, 1)); - if (!expression) - return NULL; - suite_seq = ast_for_suite(c, body); - if (!suite_seq) - return NULL; - get_last_end_pos(suite_seq, &end_lineno, &end_col_offset); - - return ExceptHandler(expression, NULL, suite_seq, LINENO(exc), - exc->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - else if (NCH(exc) == 4) { - asdl_seq *suite_seq; - expr_ty expression; - identifier e = NEW_IDENTIFIER(CHILD(exc, 3)); - if (!e) - return NULL; - if (forbidden_name(c, e, CHILD(exc, 3), 0)) - return NULL; - expression = ast_for_expr(c, CHILD(exc, 1)); - if (!expression) - return NULL; - suite_seq = ast_for_suite(c, body); - if (!suite_seq) - return NULL; - get_last_end_pos(suite_seq, &end_lineno, &end_col_offset); - - return ExceptHandler(expression, e, suite_seq, LINENO(exc), - exc->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - - PyErr_Format(PyExc_SystemError, - "wrong number of children for 'except' clause: %d", - NCH(exc)); - return NULL; -} - -static stmt_ty -ast_for_try_stmt(struct compiling *c, const node *n) -{ - const int nch = NCH(n); - int end_lineno, end_col_offset, n_except = (nch - 3)/3; - asdl_seq *body, *handlers = NULL, *orelse = NULL, *finally = NULL; - excepthandler_ty last_handler; - - REQ(n, try_stmt); - - body = ast_for_suite(c, CHILD(n, 2)); - if (body == NULL) - return NULL; - - if (TYPE(CHILD(n, nch - 3)) == NAME) { - if (strcmp(STR(CHILD(n, nch - 3)), "finally") == 0) { - if (nch >= 9 && TYPE(CHILD(n, nch - 6)) == NAME) { - /* we can assume it's an "else", - because nch >= 9 for try-else-finally and - it would otherwise have a type of except_clause */ - orelse = ast_for_suite(c, CHILD(n, nch - 4)); - if (orelse == NULL) - return NULL; - n_except--; - } - - finally = ast_for_suite(c, CHILD(n, nch - 1)); - if (finally == NULL) - return NULL; - n_except--; - } - else { - /* we can assume it's an "else", - otherwise it would have a type of except_clause */ - orelse = ast_for_suite(c, CHILD(n, nch - 1)); - if (orelse == NULL) - return NULL; - n_except--; - } - } - else if (TYPE(CHILD(n, nch - 3)) != except_clause) { - ast_error(c, n, "malformed 'try' statement"); - return NULL; - } - - if (n_except > 0) { - int i; - /* process except statements to create a try ... except */ - handlers = _Py_asdl_seq_new(n_except, c->c_arena); - if (handlers == NULL) - return NULL; - - for (i = 0; i < n_except; i++) { - excepthandler_ty e = ast_for_except_clause(c, CHILD(n, 3 + i * 3), - CHILD(n, 5 + i * 3)); - if (!e) - return NULL; - asdl_seq_SET(handlers, i, e); - } - } - - assert(finally != NULL || asdl_seq_LEN(handlers)); - if (finally != NULL) { - // finally is always last - get_last_end_pos(finally, &end_lineno, &end_col_offset); - } else if (orelse != NULL) { - // otherwise else is last - get_last_end_pos(orelse, &end_lineno, &end_col_offset); - } else { - // inline the get_last_end_pos logic due to layout mismatch - last_handler = (excepthandler_ty) asdl_seq_GET(handlers, n_except - 1); - end_lineno = last_handler->end_lineno; - end_col_offset = last_handler->end_col_offset; - } - return Try(body, handlers, orelse, finally, LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); -} - -/* with_item: test ['as' expr] */ -static withitem_ty -ast_for_with_item(struct compiling *c, const node *n) -{ - expr_ty context_expr, optional_vars = NULL; - - REQ(n, with_item); - context_expr = ast_for_expr(c, CHILD(n, 0)); - if (!context_expr) - return NULL; - if (NCH(n) == 3) { - optional_vars = ast_for_expr(c, CHILD(n, 2)); - - if (!optional_vars) { - return NULL; - } - if (!set_context(c, optional_vars, Store, n)) { - return NULL; - } - } - - return withitem(context_expr, optional_vars, c->c_arena); -} - -/* with_stmt: 'with' with_item (',' with_item)* ':' [TYPE_COMMENT] suite */ -static stmt_ty -ast_for_with_stmt(struct compiling *c, const node *n0, bool is_async) -{ - const node * const n = is_async ? CHILD(n0, 1) : n0; - int i, n_items, nch_minus_type, has_type_comment, end_lineno, end_col_offset; - asdl_seq *items, *body; - string type_comment; - - if (is_async && c->c_feature_version < 5) { - ast_error(c, n, - "Async with statements are only supported in Python 3.5 and greater"); - return NULL; - } - - REQ(n, with_stmt); - - has_type_comment = TYPE(CHILD(n, NCH(n) - 2)) == TYPE_COMMENT; - nch_minus_type = NCH(n) - has_type_comment; - - n_items = (nch_minus_type - 2) / 2; - items = _Py_asdl_seq_new(n_items, c->c_arena); - if (!items) - return NULL; - for (i = 1; i < nch_minus_type - 2; i += 2) { - withitem_ty item = ast_for_with_item(c, CHILD(n, i)); - if (!item) - return NULL; - asdl_seq_SET(items, (i - 1) / 2, item); - } - - body = ast_for_suite(c, CHILD(n, NCH(n) - 1)); - if (!body) - return NULL; - get_last_end_pos(body, &end_lineno, &end_col_offset); - - if (has_type_comment) { - type_comment = NEW_TYPE_COMMENT(CHILD(n, NCH(n) - 2)); - if (!type_comment) - return NULL; - } - else - type_comment = NULL; - - if (is_async) - return AsyncWith(items, body, type_comment, LINENO(n0), n0->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - else - return With(items, body, type_comment, LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); -} - -static stmt_ty -ast_for_classdef(struct compiling *c, const node *n, asdl_seq *decorator_seq) -{ - /* classdef: 'class' NAME ['(' arglist ')'] ':' suite */ - PyObject *classname; - asdl_seq *s; - expr_ty call; - int end_lineno, end_col_offset; - - REQ(n, classdef); - - if (NCH(n) == 4) { /* class NAME ':' suite */ - s = ast_for_suite(c, CHILD(n, 3)); - if (!s) - return NULL; - get_last_end_pos(s, &end_lineno, &end_col_offset); - - classname = NEW_IDENTIFIER(CHILD(n, 1)); - if (!classname) - return NULL; - if (forbidden_name(c, classname, CHILD(n, 3), 0)) - return NULL; - return ClassDef(classname, NULL, NULL, s, decorator_seq, - LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - - if (TYPE(CHILD(n, 3)) == RPAR) { /* class NAME '(' ')' ':' suite */ - s = ast_for_suite(c, CHILD(n, 5)); - if (!s) - return NULL; - get_last_end_pos(s, &end_lineno, &end_col_offset); - - classname = NEW_IDENTIFIER(CHILD(n, 1)); - if (!classname) - return NULL; - if (forbidden_name(c, classname, CHILD(n, 3), 0)) - return NULL; - return ClassDef(classname, NULL, NULL, s, decorator_seq, - LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); - } - - /* class NAME '(' arglist ')' ':' suite */ - /* build up a fake Call node so we can extract its pieces */ - { - PyObject *dummy_name; - expr_ty dummy; - dummy_name = NEW_IDENTIFIER(CHILD(n, 1)); - if (!dummy_name) - return NULL; - dummy = Name(dummy_name, Load, LINENO(n), n->n_col_offset, - CHILD(n, 1)->n_end_lineno, CHILD(n, 1)->n_end_col_offset, - c->c_arena); - call = ast_for_call(c, CHILD(n, 3), dummy, - CHILD(n, 1), NULL, CHILD(n, 4)); - if (!call) - return NULL; - } - s = ast_for_suite(c, CHILD(n, 6)); - if (!s) - return NULL; - get_last_end_pos(s, &end_lineno, &end_col_offset); - - classname = NEW_IDENTIFIER(CHILD(n, 1)); - if (!classname) - return NULL; - if (forbidden_name(c, classname, CHILD(n, 1), 0)) - return NULL; - - return ClassDef(classname, call->v.Call.args, call->v.Call.keywords, s, - decorator_seq, LINENO(n), n->n_col_offset, - end_lineno, end_col_offset, c->c_arena); -} - -static stmt_ty -ast_for_stmt(struct compiling *c, const node *n) -{ - if (TYPE(n) == stmt) { - assert(NCH(n) == 1); - n = CHILD(n, 0); - } - if (TYPE(n) == simple_stmt) { - assert(num_stmts(n) == 1); - n = CHILD(n, 0); - } - if (TYPE(n) == small_stmt) { - n = CHILD(n, 0); - /* small_stmt: expr_stmt | del_stmt | pass_stmt | flow_stmt - | import_stmt | global_stmt | nonlocal_stmt | assert_stmt - */ - switch (TYPE(n)) { - case expr_stmt: - return ast_for_expr_stmt(c, n); - case del_stmt: - return ast_for_del_stmt(c, n); - case pass_stmt: - return Pass(LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - case flow_stmt: - return ast_for_flow_stmt(c, n); - case import_stmt: - return ast_for_import_stmt(c, n); - case global_stmt: - return ast_for_global_stmt(c, n); - case nonlocal_stmt: - return ast_for_nonlocal_stmt(c, n); - case assert_stmt: - return ast_for_assert_stmt(c, n); - default: - PyErr_Format(PyExc_SystemError, - "unhandled small_stmt: TYPE=%d NCH=%d\n", - TYPE(n), NCH(n)); - return NULL; - } - } - else { - /* compound_stmt: if_stmt | while_stmt | for_stmt | try_stmt - | funcdef | classdef | decorated | async_stmt - */ - node *ch = CHILD(n, 0); - REQ(n, compound_stmt); - switch (TYPE(ch)) { - case if_stmt: - return ast_for_if_stmt(c, ch); - case while_stmt: - return ast_for_while_stmt(c, ch); - case for_stmt: - return ast_for_for_stmt(c, ch, 0); - case try_stmt: - return ast_for_try_stmt(c, ch); - case with_stmt: - return ast_for_with_stmt(c, ch, 0); - case funcdef: - return ast_for_funcdef(c, ch, NULL); - case classdef: - return ast_for_classdef(c, ch, NULL); - case decorated: - return ast_for_decorated(c, ch); - case async_stmt: - return ast_for_async_stmt(c, ch); - default: - PyErr_Format(PyExc_SystemError, - "unhandled compound_stmt: TYPE=%d NCH=%d\n", - TYPE(n), NCH(n)); - return NULL; - } - } -} - -static PyObject * -parsenumber_raw(struct compiling *c, const char *s) -{ - const char *end; - long x; - double dx; - Py_complex compl; - int imflag; - - assert(s != NULL); - errno = 0; - end = s + strlen(s) - 1; - imflag = *end == 'j' || *end == 'J'; - if (s[0] == '0') { - x = (long) PyOS_strtoul(s, (char **)&end, 0); - if (x < 0 && errno == 0) { - return PyLong_FromString(s, (char **)0, 0); - } - } - else - x = PyOS_strtol(s, (char **)&end, 0); - if (*end == '\0') { - if (errno != 0) - return PyLong_FromString(s, (char **)0, 0); - return PyLong_FromLong(x); - } - /* XXX Huge floats may silently fail */ - if (imflag) { - compl.real = 0.; - compl.imag = PyOS_string_to_double(s, (char **)&end, NULL); - if (compl.imag == -1.0 && PyErr_Occurred()) - return NULL; - return PyComplex_FromCComplex(compl); - } - else - { - dx = PyOS_string_to_double(s, NULL, NULL); - if (dx == -1.0 && PyErr_Occurred()) - return NULL; - return PyFloat_FromDouble(dx); - } -} - -static PyObject * -parsenumber(struct compiling *c, const char *s) -{ - char *dup, *end; - PyObject *res = NULL; - - assert(s != NULL); - - if (strchr(s, '_') == NULL) { - return parsenumber_raw(c, s); - } - /* Create a duplicate without underscores. */ - dup = PyMem_Malloc(strlen(s) + 1); - if (dup == NULL) { - return PyErr_NoMemory(); - } - end = dup; - for (; *s; s++) { - if (*s != '_') { - *end++ = *s; - } - } - *end = '\0'; - res = parsenumber_raw(c, dup); - PyMem_Free(dup); - return res; -} - -static PyObject * -decode_utf8(struct compiling *c, const char **sPtr, const char *end) -{ - const char *s, *t; - t = s = *sPtr; - /* while (s < end && *s != '\\') s++; */ /* inefficient for u".." */ - while (s < end && (*s & 0x80)) s++; - *sPtr = s; - return PyUnicode_DecodeUTF8(t, s - t, NULL); -} - -static int -warn_invalid_escape_sequence(struct compiling *c, const node *n, - unsigned char first_invalid_escape_char) -{ - PyObject *msg = PyUnicode_FromFormat("invalid escape sequence \\%c", - first_invalid_escape_char); - if (msg == NULL) { - return -1; - } - if (PyErr_WarnExplicitObject(PyExc_DeprecationWarning, msg, - c->c_filename, LINENO(n), - NULL, NULL) < 0) - { - if (PyErr_ExceptionMatches(PyExc_DeprecationWarning)) { - /* Replace the DeprecationWarning exception with a SyntaxError - to get a more accurate error report */ - PyErr_Clear(); - ast_error(c, n, "%U", msg); - } - Py_DECREF(msg); - return -1; - } - Py_DECREF(msg); - return 0; -} - -static PyObject * -decode_unicode_with_escapes(struct compiling *c, const node *n, const char *s, - size_t len) -{ - PyObject *v, *u; - char *buf; - char *p; - const char *end; - - /* check for integer overflow */ - if (len > SIZE_MAX / 6) - return NULL; - /* "ä" (2 bytes) may become "\U000000E4" (10 bytes), or 1:5 - "\ä" (3 bytes) may become "\u005c\U000000E4" (16 bytes), or ~1:6 */ - u = PyBytes_FromStringAndSize((char *)NULL, len * 6); - if (u == NULL) - return NULL; - p = buf = PyBytes_AsString(u); - end = s + len; - while (s < end) { - if (*s == '\\') { - *p++ = *s++; - if (s >= end || *s & 0x80) { - strcpy(p, "u005c"); - p += 5; - if (s >= end) - break; - } - } - if (*s & 0x80) { /* XXX inefficient */ - PyObject *w; - int kind; - const void *data; - Py_ssize_t len, i; - w = decode_utf8(c, &s, end); - if (w == NULL) { - Py_DECREF(u); - return NULL; - } - kind = PyUnicode_KIND(w); - data = PyUnicode_DATA(w); - len = PyUnicode_GET_LENGTH(w); - for (i = 0; i < len; i++) { - Py_UCS4 chr = PyUnicode_READ(kind, data, i); - sprintf(p, "\\U%08x", chr); - p += 10; - } - /* Should be impossible to overflow */ - assert(p - buf <= PyBytes_GET_SIZE(u)); - Py_DECREF(w); - } else { - *p++ = *s++; - } - } - len = p - buf; - s = buf; - - const char *first_invalid_escape; - v = _PyUnicode_DecodeUnicodeEscapeInternal(s, len, NULL, NULL, &first_invalid_escape); - - if (v != NULL && first_invalid_escape != NULL) { - if (warn_invalid_escape_sequence(c, n, *first_invalid_escape) < 0) { - /* We have not decref u before because first_invalid_escape points - inside u. */ - Py_XDECREF(u); - Py_DECREF(v); - return NULL; - } - } - Py_XDECREF(u); - return v; -} - -static PyObject * -decode_bytes_with_escapes(struct compiling *c, const node *n, const char *s, - size_t len) -{ - const char *first_invalid_escape; - PyObject *result = _PyBytes_DecodeEscape(s, len, NULL, - &first_invalid_escape); - if (result == NULL) - return NULL; - - if (first_invalid_escape != NULL) { - if (warn_invalid_escape_sequence(c, n, *first_invalid_escape) < 0) { - Py_DECREF(result); - return NULL; - } - } - return result; -} - -/* Shift locations for the given node and all its children by adding `lineno` - and `col_offset` to existing locations. */ -static void fstring_shift_node_locations(node *n, int lineno, int col_offset) -{ - n->n_col_offset = n->n_col_offset + col_offset; - n->n_end_col_offset = n->n_end_col_offset + col_offset; - for (int i = 0; i < NCH(n); ++i) { - if (n->n_lineno && n->n_lineno < CHILD(n, i)->n_lineno) { - /* Shifting column offsets unnecessary if there's been newlines. */ - col_offset = 0; - } - fstring_shift_node_locations(CHILD(n, i), lineno, col_offset); - } - n->n_lineno = n->n_lineno + lineno; - n->n_end_lineno = n->n_end_lineno + lineno; -} - -/* Fix locations for the given node and its children. - - `parent` is the enclosing node. - `n` is the node which locations are going to be fixed relative to parent. - `expr_str` is the child node's string representation, including braces. -*/ -static void -fstring_fix_node_location(const node *parent, node *n, char *expr_str) -{ - char *substr = NULL; - char *start; - int lines = LINENO(parent) - 1; - int cols = parent->n_col_offset; - /* Find the full fstring to fix location information in `n`. */ - while (parent && parent->n_type != STRING) - parent = parent->n_child; - if (parent && parent->n_str) { - substr = strstr(parent->n_str, expr_str); - if (substr) { - start = substr; - while (start > parent->n_str) { - if (start[0] == '\n') - break; - start--; - } - cols += (int)(substr - start); - /* adjust the start based on the number of newlines encountered - before the f-string expression */ - for (char* p = parent->n_str; p < substr; p++) { - if (*p == '\n') { - lines++; - } - } - } - } - fstring_shift_node_locations(n, lines, cols); -} - -/* Compile this expression in to an expr_ty. Add parens around the - expression, in order to allow leading spaces in the expression. */ -static expr_ty -fstring_compile_expr(const char *expr_start, const char *expr_end, - struct compiling *c, const node *n) - -{ - node *mod_n; - mod_ty mod; - char *str; - Py_ssize_t len; - const char *s; - - assert(expr_end >= expr_start); - assert(*(expr_start-1) == '{'); - assert(*expr_end == '}' || *expr_end == '!' || *expr_end == ':' || - *expr_end == '='); - - /* If the substring is all whitespace, it's an error. We need to catch this - here, and not when we call PyParser_SimpleParseStringFlagsFilename, - because turning the expression '' in to '()' would go from being invalid - to valid. */ - for (s = expr_start; s != expr_end; s++) { - char c = *s; - /* The Python parser ignores only the following whitespace - characters (\r already is converted to \n). */ - if (!(c == ' ' || c == '\t' || c == '\n' || c == '\f')) { - break; - } - } - if (s == expr_end) { - ast_error(c, n, "f-string: empty expression not allowed"); - return NULL; - } - - len = expr_end - expr_start; - /* Allocate 3 extra bytes: open paren, close paren, null byte. */ - str = PyMem_Malloc(len + 3); - if (str == NULL) { - PyErr_NoMemory(); - return NULL; - } - - str[0] = '('; - memcpy(str+1, expr_start, len); - str[len+1] = ')'; - str[len+2] = 0; - - PyCompilerFlags cf = _PyCompilerFlags_INIT; - cf.cf_flags = PyCF_ONLY_AST; - mod_n = PyParser_SimpleParseStringFlagsFilename(str, "<fstring>", - Py_eval_input, 0); - if (!mod_n) { - PyMem_Free(str); - return NULL; - } - /* Reuse str to find the correct column offset. */ - str[0] = '{'; - str[len+1] = '}'; - fstring_fix_node_location(n, mod_n, str); - mod = PyAST_FromNode(mod_n, &cf, "<fstring>", c->c_arena); - PyMem_Free(str); - PyNode_Free(mod_n); - if (!mod) - return NULL; - return mod->v.Expression.body; -} - -/* Return -1 on error. - - Return 0 if we reached the end of the literal. - - Return 1 if we haven't reached the end of the literal, but we want - the caller to process the literal up to this point. Used for - doubled braces. -*/ -static int -fstring_find_literal(const char **str, const char *end, int raw, - PyObject **literal, int recurse_lvl, - struct compiling *c, const node *n) -{ - /* Get any literal string. It ends when we hit an un-doubled left - brace (which isn't part of a unicode name escape such as - "\N{EULER CONSTANT}"), or the end of the string. */ - - const char *s = *str; - const char *literal_start = s; - int result = 0; - - assert(*literal == NULL); - while (s < end) { - char ch = *s++; - if (!raw && ch == '\\' && s < end) { - ch = *s++; - if (ch == 'N') { - if (s < end && *s++ == '{') { - while (s < end && *s++ != '}') { - } - continue; - } - break; - } - if (ch == '{' && warn_invalid_escape_sequence(c, n, ch) < 0) { - return -1; - } - } - if (ch == '{' || ch == '}') { - /* Check for doubled braces, but only at the top level. If - we checked at every level, then f'{0:{3}}' would fail - with the two closing braces. */ - if (recurse_lvl == 0) { - if (s < end && *s == ch) { - /* We're going to tell the caller that the literal ends - here, but that they should continue scanning. But also - skip over the second brace when we resume scanning. */ - *str = s + 1; - result = 1; - goto done; - } - - /* Where a single '{' is the start of a new expression, a - single '}' is not allowed. */ - if (ch == '}') { - *str = s - 1; - ast_error(c, n, "f-string: single '}' is not allowed"); - return -1; - } - } - /* We're either at a '{', which means we're starting another - expression; or a '}', which means we're at the end of this - f-string (for a nested format_spec). */ - s--; - break; - } - } - *str = s; - assert(s <= end); - assert(s == end || *s == '{' || *s == '}'); -done: - if (literal_start != s) { - if (raw) - *literal = PyUnicode_DecodeUTF8Stateful(literal_start, - s - literal_start, - NULL, NULL); - else - *literal = decode_unicode_with_escapes(c, n, literal_start, - s - literal_start); - if (!*literal) - return -1; - } - return result; -} - -/* Forward declaration because parsing is recursive. */ -static expr_ty -fstring_parse(const char **str, const char *end, int raw, int recurse_lvl, - struct compiling *c, const node *n); - -/* Parse the f-string at *str, ending at end. We know *str starts an - expression (so it must be a '{'). Returns the FormattedValue node, which - includes the expression, conversion character, format_spec expression, and - optionally the text of the expression (if = is used). - - Note that I don't do a perfect job here: I don't make sure that a - closing brace doesn't match an opening paren, for example. It - doesn't need to error on all invalid expressions, just correctly - find the end of all valid ones. Any errors inside the expression - will be caught when we parse it later. - - *expression is set to the expression. For an '=' "debug" expression, - *expr_text is set to the debug text (the original text of the expression, - including the '=' and any whitespace around it, as a string object). If - not a debug expression, *expr_text set to NULL. */ -static int -fstring_find_expr(const char **str, const char *end, int raw, int recurse_lvl, - PyObject **expr_text, expr_ty *expression, - struct compiling *c, const node *n) -{ - /* Return -1 on error, else 0. */ - - const char *expr_start; - const char *expr_end; - expr_ty simple_expression; - expr_ty format_spec = NULL; /* Optional format specifier. */ - int conversion = -1; /* The conversion char. Use default if not - specified, or !r if using = and no format - spec. */ - - /* 0 if we're not in a string, else the quote char we're trying to - match (single or double quote). */ - char quote_char = 0; - - /* If we're inside a string, 1=normal, 3=triple-quoted. */ - int string_type = 0; - - /* Keep track of nesting level for braces/parens/brackets in - expressions. */ - Py_ssize_t nested_depth = 0; - char parenstack[MAXLEVEL]; - - *expr_text = NULL; - - /* Can only nest one level deep. */ - if (recurse_lvl >= 2) { - ast_error(c, n, "f-string: expressions nested too deeply"); - goto error; - } - /* The first char must be a left brace, or we wouldn't have gotten - here. Skip over it. */ - assert(**str == '{'); - *str += 1; +/* See comments in symtable.c. */ +#define COMPILER_STACK_FRAME_SCALE 3 - expr_start = *str; - for (; *str < end; (*str)++) { - char ch; - - /* Loop invariants. */ - assert(nested_depth >= 0); - assert(*str >= expr_start && *str < end); - if (quote_char) - assert(string_type == 1 || string_type == 3); - else - assert(string_type == 0); - - ch = **str; - /* Nowhere inside an expression is a backslash allowed. */ - if (ch == '\\') { - /* Error: can't include a backslash character, inside - parens or strings or not. */ - ast_error(c, n, - "f-string expression part " - "cannot include a backslash"); - goto error; - } - if (quote_char) { - /* We're inside a string. See if we're at the end. */ - /* This code needs to implement the same non-error logic - as tok_get from tokenizer.c, at the letter_quote - label. To actually share that code would be a - nightmare. But, it's unlikely to change and is small, - so duplicate it here. Note we don't need to catch all - of the errors, since they'll be caught when parsing the - expression. We just need to match the non-error - cases. Thus we can ignore \n in single-quoted strings, - for example. Or non-terminated strings. */ - if (ch == quote_char) { - /* Does this match the string_type (single or triple - quoted)? */ - if (string_type == 3) { - if (*str+2 < end && *(*str+1) == ch && *(*str+2) == ch) { - /* We're at the end of a triple quoted string. */ - *str += 2; - string_type = 0; - quote_char = 0; - continue; - } - } else { - /* We're at the end of a normal string. */ - quote_char = 0; - string_type = 0; - continue; - } - } - } else if (ch == '\'' || ch == '"') { - /* Is this a triple quoted string? */ - if (*str+2 < end && *(*str+1) == ch && *(*str+2) == ch) { - string_type = 3; - *str += 2; - } else { - /* Start of a normal string. */ - string_type = 1; - } - /* Start looking for the end of the string. */ - quote_char = ch; - } else if (ch == '[' || ch == '{' || ch == '(') { - if (nested_depth >= MAXLEVEL) { - ast_error(c, n, "f-string: too many nested parenthesis"); - goto error; - } - parenstack[nested_depth] = ch; - nested_depth++; - } else if (ch == '#') { - /* Error: can't include a comment character, inside parens - or not. */ - ast_error(c, n, "f-string expression part cannot include '#'"); - goto error; - } else if (nested_depth == 0 && - (ch == '!' || ch == ':' || ch == '}' || - ch == '=' || ch == '>' || ch == '<')) { - /* See if there's a next character. */ - if (*str+1 < end) { - char next = *(*str+1); - - /* For "!=". since '=' is not an allowed conversion character, - nothing is lost in this test. */ - if ((ch == '!' && next == '=') || /* != */ - (ch == '=' && next == '=') || /* == */ - (ch == '<' && next == '=') || /* <= */ - (ch == '>' && next == '=') /* >= */ - ) { - *str += 1; - continue; - } - /* Don't get out of the loop for these, if they're single - chars (not part of 2-char tokens). If by themselves, they - don't end an expression (unlike say '!'). */ - if (ch == '>' || ch == '<') { - continue; - } - } - - /* Normal way out of this loop. */ - break; - } else if (ch == ']' || ch == '}' || ch == ')') { - if (!nested_depth) { - ast_error(c, n, "f-string: unmatched '%c'", ch); - goto error; - } - nested_depth--; - int opening = parenstack[nested_depth]; - if (!((opening == '(' && ch == ')') || - (opening == '[' && ch == ']') || - (opening == '{' && ch == '}'))) - { - ast_error(c, n, - "f-string: closing parenthesis '%c' " - "does not match opening parenthesis '%c'", - ch, opening); - goto error; - } - } else { - /* Just consume this char and loop around. */ - } - } - expr_end = *str; - /* If we leave this loop in a string or with mismatched parens, we - don't care. We'll get a syntax error when compiling the - expression. But, we can produce a better error message, so - let's just do that.*/ - if (quote_char) { - ast_error(c, n, "f-string: unterminated string"); - goto error; - } - if (nested_depth) { - int opening = parenstack[nested_depth - 1]; - ast_error(c, n, "f-string: unmatched '%c'", opening); - goto error; - } - - if (*str >= end) - goto unexpected_end_of_string; - - /* Compile the expression as soon as possible, so we show errors - related to the expression before errors related to the - conversion or format_spec. */ - simple_expression = fstring_compile_expr(expr_start, expr_end, c, n); - if (!simple_expression) - goto error; - - /* Check for =, which puts the text value of the expression in - expr_text. */ - if (**str == '=') { - if (c->c_feature_version < 8) { - ast_error(c, n, - "f-string: self documenting expressions are " - "only supported in Python 3.8 and greater"); - goto error; - } - *str += 1; - - /* Skip over ASCII whitespace. No need to test for end of string - here, since we know there's at least a trailing quote somewhere - ahead. */ - while (Py_ISSPACE(**str)) { - *str += 1; - } - - /* Set *expr_text to the text of the expression. */ - *expr_text = PyUnicode_FromStringAndSize(expr_start, *str-expr_start); - if (!*expr_text) { - goto error; - } - } - - /* Check for a conversion char, if present. */ - if (**str == '!') { - *str += 1; - if (*str >= end) - goto unexpected_end_of_string; - - conversion = **str; - *str += 1; - - /* Validate the conversion. */ - if (!(conversion == 's' || conversion == 'r' || conversion == 'a')) { - ast_error(c, n, - "f-string: invalid conversion character: " - "expected 's', 'r', or 'a'"); - goto error; - } - - } - - /* Check for the format spec, if present. */ - if (*str >= end) - goto unexpected_end_of_string; - if (**str == ':') { - *str += 1; - if (*str >= end) - goto unexpected_end_of_string; - - /* Parse the format spec. */ - format_spec = fstring_parse(str, end, raw, recurse_lvl+1, c, n); - if (!format_spec) - goto error; - } - - if (*str >= end || **str != '}') - goto unexpected_end_of_string; - - /* We're at a right brace. Consume it. */ - assert(*str < end); - assert(**str == '}'); - *str += 1; - - /* If we're in = mode (detected by non-NULL expr_text), and have no format - spec and no explicit conversion, set the conversion to 'r'. */ - if (*expr_text && format_spec == NULL && conversion == -1) { - conversion = 'r'; - } - - /* And now create the FormattedValue node that represents this - entire expression with the conversion and format spec. */ - *expression = FormattedValue(simple_expression, conversion, - format_spec, LINENO(n), - n->n_col_offset, n->n_end_lineno, - n->n_end_col_offset, c->c_arena); - if (!*expression) - goto error; - - return 0; - -unexpected_end_of_string: - ast_error(c, n, "f-string: expecting '}'"); - /* Falls through to error. */ - -error: - Py_XDECREF(*expr_text); - return -1; - -} - -/* Return -1 on error. - - Return 0 if we have a literal (possible zero length) and an - expression (zero length if at the end of the string. - - Return 1 if we have a literal, but no expression, and we want the - caller to call us again. This is used to deal with doubled - braces. - - When called multiple times on the string 'a{{b{0}c', this function - will return: - - 1. the literal 'a{' with no expression, and a return value - of 1. Despite the fact that there's no expression, the return - value of 1 means we're not finished yet. - - 2. the literal 'b' and the expression '0', with a return value of - 0. The fact that there's an expression means we're not finished. - - 3. literal 'c' with no expression and a return value of 0. The - combination of the return value of 0 with no expression means - we're finished. -*/ -static int -fstring_find_literal_and_expr(const char **str, const char *end, int raw, - int recurse_lvl, PyObject **literal, - PyObject **expr_text, expr_ty *expression, - struct compiling *c, const node *n) +int +_PyAST_Validate(mod_ty mod) { - int result; - - assert(*literal == NULL && *expression == NULL); - - /* Get any literal string. */ - result = fstring_find_literal(str, end, raw, literal, recurse_lvl, c, n); - if (result < 0) - goto error; - - assert(result == 0 || result == 1); - - if (result == 1) - /* We have a literal, but don't look at the expression. */ - return 1; + int res = -1; + struct validator state; + PyThreadState *tstate; + int recursion_limit = Py_GetRecursionLimit(); + int starting_recursion_depth; - if (*str >= end || **str == '}') - /* We're at the end of the string or the end of a nested - f-string: no expression. The top-level error case where we - expect to be at the end of the string but we're at a '}' is - handled later. */ + /* Setup recursion depth check counters */ + tstate = _PyThreadState_GET(); + if (!tstate) { return 0; - - /* We must now be the start of an expression, on a '{'. */ - assert(**str == '{'); - - if (fstring_find_expr(str, end, raw, recurse_lvl, expr_text, - expression, c, n) < 0) - goto error; - - return 0; - -error: - Py_CLEAR(*literal); - return -1; -} - -#define EXPRLIST_N_CACHED 64 - -typedef struct { - /* Incrementally build an array of expr_ty, so be used in an - asdl_seq. Cache some small but reasonably sized number of - expr_ty's, and then after that start dynamically allocating, - doubling the number allocated each time. Note that the f-string - f'{0}a{1}' contains 3 expr_ty's: 2 FormattedValue's, and one - Constant for the literal 'a'. So you add expr_ty's about twice as - fast as you add expressions in an f-string. */ - - Py_ssize_t allocated; /* Number we've allocated. */ - Py_ssize_t size; /* Number we've used. */ - expr_ty *p; /* Pointer to the memory we're actually - using. Will point to 'data' until we - start dynamically allocating. */ - expr_ty data[EXPRLIST_N_CACHED]; -} ExprList; - -#ifdef NDEBUG -#define ExprList_check_invariants(l) -#else -static void -ExprList_check_invariants(ExprList *l) -{ - /* Check our invariants. Make sure this object is "live", and - hasn't been deallocated. */ - assert(l->size >= 0); - assert(l->p != NULL); - if (l->size <= EXPRLIST_N_CACHED) - assert(l->data == l->p); -} -#endif - -static void -ExprList_Init(ExprList *l) -{ - l->allocated = EXPRLIST_N_CACHED; - l->size = 0; - - /* Until we start allocating dynamically, p points to data. */ - l->p = l->data; - - ExprList_check_invariants(l); -} - -static int -ExprList_Append(ExprList *l, expr_ty exp) -{ - ExprList_check_invariants(l); - if (l->size >= l->allocated) { - /* We need to alloc (or realloc) the memory. */ - Py_ssize_t new_size = l->allocated * 2; - - /* See if we've ever allocated anything dynamically. */ - if (l->p == l->data) { - Py_ssize_t i; - /* We're still using the cached data. Switch to - alloc-ing. */ - l->p = PyMem_Malloc(sizeof(expr_ty) * new_size); - if (!l->p) - return -1; - /* Copy the cached data into the new buffer. */ - for (i = 0; i < l->size; i++) - l->p[i] = l->data[i]; - } else { - /* Just realloc. */ - expr_ty *tmp = PyMem_Realloc(l->p, sizeof(expr_ty) * new_size); - if (!tmp) { - PyMem_Free(l->p); - l->p = NULL; - return -1; - } - l->p = tmp; - } - - l->allocated = new_size; - assert(l->allocated == 2 * l->size); } + /* Be careful here to prevent overflow. */ + starting_recursion_depth = (tstate->recursion_depth < INT_MAX / COMPILER_STACK_FRAME_SCALE) ? + tstate->recursion_depth * COMPILER_STACK_FRAME_SCALE : tstate->recursion_depth; + state.recursion_depth = starting_recursion_depth; + state.recursion_limit = (recursion_limit < INT_MAX / COMPILER_STACK_FRAME_SCALE) ? + recursion_limit * COMPILER_STACK_FRAME_SCALE : recursion_limit; - l->p[l->size++] = exp; - - ExprList_check_invariants(l); - return 0; -} - -static void -ExprList_Dealloc(ExprList *l) -{ - ExprList_check_invariants(l); - - /* If there's been an error, or we've never dynamically allocated, - do nothing. */ - if (!l->p || l->p == l->data) { - /* Do nothing. */ - } else { - /* We have dynamically allocated. Free the memory. */ - PyMem_Free(l->p); - } - l->p = NULL; - l->size = -1; -} - -static asdl_seq * -ExprList_Finish(ExprList *l, PyArena *arena) -{ - asdl_seq *seq; - - ExprList_check_invariants(l); - - /* Allocate the asdl_seq and copy the expressions in to it. */ - seq = _Py_asdl_seq_new(l->size, arena); - if (seq) { - Py_ssize_t i; - for (i = 0; i < l->size; i++) - asdl_seq_SET(seq, i, l->p[i]); - } - ExprList_Dealloc(l); - return seq; -} - -/* The FstringParser is designed to add a mix of strings and - f-strings, and concat them together as needed. Ultimately, it - generates an expr_ty. */ -typedef struct { - PyObject *last_str; - ExprList expr_list; - int fmode; -} FstringParser; - -#ifdef NDEBUG -#define FstringParser_check_invariants(state) -#else -static void -FstringParser_check_invariants(FstringParser *state) -{ - if (state->last_str) - assert(PyUnicode_CheckExact(state->last_str)); - ExprList_check_invariants(&state->expr_list); -} -#endif - -static void -FstringParser_Init(FstringParser *state) -{ - state->last_str = NULL; - state->fmode = 0; - ExprList_Init(&state->expr_list); - FstringParser_check_invariants(state); -} - -static void -FstringParser_Dealloc(FstringParser *state) -{ - FstringParser_check_invariants(state); - - Py_XDECREF(state->last_str); - ExprList_Dealloc(&state->expr_list); -} - -/* Constants for the following */ -static PyObject *u_kind; - -/* Compute 'kind' field for string Constant (either 'u' or None) */ -static PyObject * -make_kind(struct compiling *c, const node *n) -{ - char *s = NULL; - PyObject *kind = NULL; - - /* Find the first string literal, if any */ - while (TYPE(n) != STRING) { - if (NCH(n) == 0) - return NULL; - n = CHILD(n, 0); - } - REQ(n, STRING); - - /* If it starts with 'u', return a PyUnicode "u" string */ - s = STR(n); - if (s && *s == 'u') { - if (!u_kind) { - u_kind = PyUnicode_InternFromString("u"); - if (!u_kind) - return NULL; - } - kind = u_kind; - if (PyArena_AddPyObject(c->c_arena, kind) < 0) { - return NULL; - } - Py_INCREF(kind); - } - return kind; -} - -/* Make a Constant node, but decref the PyUnicode object being added. */ -static expr_ty -make_str_node_and_del(PyObject **str, struct compiling *c, const node* n) -{ - PyObject *s = *str; - PyObject *kind = NULL; - *str = NULL; - assert(PyUnicode_CheckExact(s)); - if (PyArena_AddPyObject(c->c_arena, s) < 0) { - Py_DECREF(s); - return NULL; + switch (mod->kind) { + case Module_kind: + res = validate_stmts(&state, mod->v.Module.body); + break; + case Interactive_kind: + res = validate_stmts(&state, mod->v.Interactive.body); + break; + case Expression_kind: + res = validate_expr(&state, mod->v.Expression.body, Load); + break; + case FunctionType_kind: + res = validate_exprs(&state, mod->v.FunctionType.argtypes, Load, /*null_ok=*/0) && + validate_expr(&state, mod->v.FunctionType.returns, Load); + break; + // No default case so compiler emits warning for unhandled cases } - kind = make_kind(c, n); - if (kind == NULL && PyErr_Occurred()) - return NULL; - return Constant(s, kind, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); -} -/* Add a non-f-string (that is, a regular literal string). str is - decref'd. */ -static int -FstringParser_ConcatAndDel(FstringParser *state, PyObject *str) -{ - FstringParser_check_invariants(state); - - assert(PyUnicode_CheckExact(str)); - - if (PyUnicode_GET_LENGTH(str) == 0) { - Py_DECREF(str); + if (res < 0) { + PyErr_SetString(PyExc_SystemError, "impossible module node"); return 0; } - if (!state->last_str) { - /* We didn't have a string before, so just remember this one. */ - state->last_str = str; - } else { - /* Concatenate this with the previous string. */ - PyUnicode_AppendAndDel(&state->last_str, str); - if (!state->last_str) - return -1; - } - FstringParser_check_invariants(state); - return 0; -} - -/* Parse an f-string. The f-string is in *str to end, with no - 'f' or quotes. */ -static int -FstringParser_ConcatFstring(FstringParser *state, const char **str, - const char *end, int raw, int recurse_lvl, - struct compiling *c, const node *n) -{ - FstringParser_check_invariants(state); - state->fmode = 1; - - /* Parse the f-string. */ - while (1) { - PyObject *literal = NULL; - PyObject *expr_text = NULL; - expr_ty expression = NULL; - - /* If there's a zero length literal in front of the - expression, literal will be NULL. If we're at the end of - the f-string, expression will be NULL (unless result == 1, - see below). */ - int result = fstring_find_literal_and_expr(str, end, raw, recurse_lvl, - &literal, &expr_text, - &expression, c, n); - if (result < 0) - return -1; - - /* Add the literal, if any. */ - if (literal && FstringParser_ConcatAndDel(state, literal) < 0) { - Py_XDECREF(expr_text); - return -1; - } - /* Add the expr_text, if any. */ - if (expr_text && FstringParser_ConcatAndDel(state, expr_text) < 0) { - return -1; - } - - /* We've dealt with the literal and expr_text, their ownership has - been transferred to the state object. Don't look at them again. */ - - /* See if we should just loop around to get the next literal - and expression, while ignoring the expression this - time. This is used for un-doubling braces, as an - optimization. */ - if (result == 1) - continue; - - if (!expression) - /* We're done with this f-string. */ - break; - - /* We know we have an expression. Convert any existing string - to a Constant node. */ - if (!state->last_str) { - /* Do nothing. No previous literal. */ - } else { - /* Convert the existing last_str literal to a Constant node. */ - expr_ty str = make_str_node_and_del(&state->last_str, c, n); - if (!str || ExprList_Append(&state->expr_list, str) < 0) - return -1; - } - - if (ExprList_Append(&state->expr_list, expression) < 0) - return -1; - } - - /* If recurse_lvl is zero, then we must be at the end of the - string. Otherwise, we must be at a right brace. */ - - if (recurse_lvl == 0 && *str < end-1) { - ast_error(c, n, "f-string: unexpected end of string"); - return -1; - } - if (recurse_lvl != 0 && **str != '}') { - ast_error(c, n, "f-string: expecting '}'"); - return -1; - } - - FstringParser_check_invariants(state); - return 0; -} - -/* Convert the partial state reflected in last_str and expr_list to an - expr_ty. The expr_ty can be a Constant, or a JoinedStr. */ -static expr_ty -FstringParser_Finish(FstringParser *state, struct compiling *c, - const node *n) -{ - asdl_seq *seq; - - FstringParser_check_invariants(state); - - /* If we're just a constant string with no expressions, return - that. */ - if (!state->fmode) { - assert(!state->expr_list.size); - if (!state->last_str) { - /* Create a zero length string. */ - state->last_str = PyUnicode_FromStringAndSize(NULL, 0); - if (!state->last_str) - goto error; - } - return make_str_node_and_del(&state->last_str, c, n); - } - - /* Create a Constant node out of last_str, if needed. It will be the - last node in our expression list. */ - if (state->last_str) { - expr_ty str = make_str_node_and_del(&state->last_str, c, n); - if (!str || ExprList_Append(&state->expr_list, str) < 0) - goto error; - } - /* This has already been freed. */ - assert(state->last_str == NULL); - - seq = ExprList_Finish(&state->expr_list, c->c_arena); - if (!seq) - goto error; - - return JoinedStr(seq, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - -error: - FstringParser_Dealloc(state); - return NULL; -} - -/* Given an f-string (with no 'f' or quotes) that's in *str and ends - at end, parse it into an expr_ty. Return NULL on error. Adjust - str to point past the parsed portion. */ -static expr_ty -fstring_parse(const char **str, const char *end, int raw, int recurse_lvl, - struct compiling *c, const node *n) -{ - FstringParser state; - - FstringParser_Init(&state); - if (FstringParser_ConcatFstring(&state, str, end, raw, recurse_lvl, - c, n) < 0) { - FstringParser_Dealloc(&state); - return NULL; - } - - return FstringParser_Finish(&state, c, n); -} - -/* n is a Python string literal, including the bracketing quote - characters, and r, b, u, &/or f prefixes (if any), and embedded - escape sequences (if any). parsestr parses it, and sets *result to - decoded Python string object. If the string is an f-string, set - *fstr and *fstrlen to the unparsed string object. Return 0 if no - errors occurred. -*/ -static int -parsestr(struct compiling *c, const node *n, int *bytesmode, int *rawmode, - PyObject **result, const char **fstr, Py_ssize_t *fstrlen) -{ - size_t len; - const char *s = STR(n); - int quote = Py_CHARMASK(*s); - int fmode = 0; - *bytesmode = 0; - *rawmode = 0; - *result = NULL; - *fstr = NULL; - if (Py_ISALPHA(quote)) { - while (!*bytesmode || !*rawmode) { - if (quote == 'b' || quote == 'B') { - quote = *++s; - *bytesmode = 1; - } - else if (quote == 'u' || quote == 'U') { - quote = *++s; - } - else if (quote == 'r' || quote == 'R') { - quote = *++s; - *rawmode = 1; - } - else if (quote == 'f' || quote == 'F') { - quote = *++s; - fmode = 1; - } - else { - break; - } - } - } - - /* fstrings are only allowed in Python 3.6 and greater */ - if (fmode && c->c_feature_version < 6) { - ast_error(c, n, "Format strings are only supported in Python 3.6 and greater"); - return -1; - } - - if (fmode && *bytesmode) { - PyErr_BadInternalCall(); - return -1; - } - if (quote != '\'' && quote != '\"') { - PyErr_BadInternalCall(); - return -1; - } - /* Skip the leading quote char. */ - s++; - len = strlen(s); - if (len > INT_MAX) { - PyErr_SetString(PyExc_OverflowError, - "string to parse is too long"); - return -1; - } - if (s[--len] != quote) { - /* Last quote char must match the first. */ - PyErr_BadInternalCall(); - return -1; - } - if (len >= 4 && s[0] == quote && s[1] == quote) { - /* A triple quoted string. We've already skipped one quote at - the start and one at the end of the string. Now skip the - two at the start. */ - s += 2; - len -= 2; - /* And check that the last two match. */ - if (s[--len] != quote || s[--len] != quote) { - PyErr_BadInternalCall(); - return -1; - } - } - - if (fmode) { - /* Just return the bytes. The caller will parse the resulting - string. */ - *fstr = s; - *fstrlen = len; + /* Check that the recursion depth counting balanced correctly */ + if (res && state.recursion_depth != starting_recursion_depth) { + PyErr_Format(PyExc_SystemError, + "AST validator recursion depth mismatch (before=%d, after=%d)", + starting_recursion_depth, state.recursion_depth); return 0; } - - /* Not an f-string. */ - /* Avoid invoking escape decoding routines if possible. */ - *rawmode = *rawmode || strchr(s, '\\') == NULL; - if (*bytesmode) { - /* Disallow non-ASCII characters. */ - const char *ch; - for (ch = s; *ch; ch++) { - if (Py_CHARMASK(*ch) >= 0x80) { - ast_error(c, n, - "bytes can only contain ASCII " - "literal characters."); - return -1; - } - } - if (*rawmode) - *result = PyBytes_FromStringAndSize(s, len); - else - *result = decode_bytes_with_escapes(c, n, s, len); - } else { - if (*rawmode) - *result = PyUnicode_DecodeUTF8Stateful(s, len, NULL, NULL); - else - *result = decode_unicode_with_escapes(c, n, s, len); - } - return *result == NULL ? -1 : 0; -} - -/* Accepts a STRING+ atom, and produces an expr_ty node. Run through - each STRING atom, and process it as needed. For bytes, just - concatenate them together, and the result will be a Constant node. For - normal strings and f-strings, concatenate them together. The result - will be a Constant node if there were no f-strings; a FormattedValue - node if there's just an f-string (with no leading or trailing - literals), or a JoinedStr node if there are multiple f-strings or - any literals involved. */ -static expr_ty -parsestrplus(struct compiling *c, const node *n) -{ - int bytesmode = 0; - PyObject *bytes_str = NULL; - int i; - - FstringParser state; - FstringParser_Init(&state); - - for (i = 0; i < NCH(n); i++) { - int this_bytesmode; - int this_rawmode; - PyObject *s; - const char *fstr; - Py_ssize_t fstrlen = -1; /* Silence a compiler warning. */ - - REQ(CHILD(n, i), STRING); - if (parsestr(c, CHILD(n, i), &this_bytesmode, &this_rawmode, &s, - &fstr, &fstrlen) != 0) - goto error; - - /* Check that we're not mixing bytes with unicode. */ - if (i != 0 && bytesmode != this_bytesmode) { - ast_error(c, n, "cannot mix bytes and nonbytes literals"); - /* s is NULL if the current string part is an f-string. */ - Py_XDECREF(s); - goto error; - } - bytesmode = this_bytesmode; - - if (fstr != NULL) { - int result; - assert(s == NULL && !bytesmode); - /* This is an f-string. Parse and concatenate it. */ - result = FstringParser_ConcatFstring(&state, &fstr, fstr+fstrlen, - this_rawmode, 0, c, n); - if (result < 0) - goto error; - } else { - /* A string or byte string. */ - assert(s != NULL && fstr == NULL); - - assert(bytesmode ? PyBytes_CheckExact(s) : - PyUnicode_CheckExact(s)); - - if (bytesmode) { - /* For bytes, concat as we go. */ - if (i == 0) { - /* First time, just remember this value. */ - bytes_str = s; - } else { - PyBytes_ConcatAndDel(&bytes_str, s); - if (!bytes_str) - goto error; - } - } else { - /* This is a regular string. Concatenate it. */ - if (FstringParser_ConcatAndDel(&state, s) < 0) - goto error; - } - } - } - if (bytesmode) { - /* Just return the bytes object and we're done. */ - if (PyArena_AddPyObject(c->c_arena, bytes_str) < 0) - goto error; - return Constant(bytes_str, NULL, LINENO(n), n->n_col_offset, - n->n_end_lineno, n->n_end_col_offset, c->c_arena); - } - - /* We're not a bytes string, bytes_str should never have been set. */ - assert(bytes_str == NULL); - - return FstringParser_Finish(&state, c, n); - -error: - Py_XDECREF(bytes_str); - FstringParser_Dealloc(&state); - return NULL; + return res; } PyObject * -_PyAST_GetDocString(asdl_seq *body) +_PyAST_GetDocString(asdl_stmt_seq *body) { if (!asdl_seq_LEN(body)) { return NULL; } - stmt_ty st = (stmt_ty)asdl_seq_GET(body, 0); + stmt_ty st = asdl_seq_GET(body, 0); if (st->kind != Expr_kind) { return NULL; } diff --git a/contrib/tools/python3/src/Python/ast_opt.c b/contrib/tools/python3/src/Python/ast_opt.c index ff786d6f8d6..c1fdea3a88c 100644 --- a/contrib/tools/python3/src/Python/ast_opt.c +++ b/contrib/tools/python3/src/Python/ast_opt.c @@ -1,12 +1,15 @@ /* AST Optimizer */ #include "Python.h" -#include "Python-ast.h" -#include "ast.h" +#include "pycore_ast.h" // _PyAST_GetDocString() +#include "pycore_compile.h" // _PyASTOptimizeState +#include "pycore_pystate.h" // _PyThreadState_GET() static int make_const(expr_ty node, PyObject *val, PyArena *arena) { + // Even if no new value was calculated, make_const may still + // need to clear an error (e.g. for division by zero) if (val == NULL) { if (PyErr_ExceptionMatches(PyExc_KeyboardInterrupt)) { return 0; @@ -14,7 +17,7 @@ make_const(expr_ty node, PyObject *val, PyArena *arena) PyErr_Clear(); return 1; } - if (PyArena_AddPyObject(arena, val) < 0) { + if (_PyArena_AddPyObject(arena, val) < 0) { Py_DECREF(val); return 0; } @@ -49,7 +52,7 @@ fold_unaryop(expr_ty node, PyArena *arena, _PyASTOptimizeState *state) of !=. Detecting such cases doesn't seem worthwhile. Python uses </> for 'is subset'/'is superset' operations on sets. They don't satisfy not folding laws. */ - int op = asdl_seq_GET(arg->v.Compare.ops, 0); + cmpop_ty op = asdl_seq_GET(arg->v.Compare.ops, 0); switch (op) { case Is: op = IsNot; @@ -63,8 +66,17 @@ fold_unaryop(expr_ty node, PyArena *arena, _PyASTOptimizeState *state) case NotIn: op = In; break; - default: - op = 0; + // The remaining comparison operators can't be safely inverted + case Eq: + case NotEq: + case Lt: + case LtE: + case Gt: + case GtE: + op = 0; // The AST enums leave "0" free as an "unused" marker + break; + // No default case, so the compiler will emit a warning if new + // comparison operators are added without being handled here } if (op) { asdl_seq_SET(arg->v.Compare.ops, 0, op); @@ -224,7 +236,7 @@ fold_binop(expr_ty node, PyArena *arena, _PyASTOptimizeState *state) PyObject *lv = lhs->v.Constant.value; PyObject *rv = rhs->v.Constant.value; - PyObject *newval; + PyObject *newval = NULL; switch (node->v.BinOp.op) { case Add: @@ -263,15 +275,18 @@ fold_binop(expr_ty node, PyArena *arena, _PyASTOptimizeState *state) case BitAnd: newval = PyNumber_And(lv, rv); break; - default: // Unknown operator + // No builtin constants implement the following operators + case MatMult: return 1; + // No default case, so the compiler will emit a warning if new binary + // operators are added without being handled here } return make_const(node, newval, arena); } static PyObject* -make_const_tuple(asdl_seq *elts) +make_const_tuple(asdl_expr_seq *elts) { for (int i = 0; i < asdl_seq_LEN(elts); i++) { expr_ty e = (expr_ty)asdl_seq_GET(elts, i); @@ -337,7 +352,7 @@ fold_iter(expr_ty arg, PyArena *arena, _PyASTOptimizeState *state) PyObject *newval; if (arg->kind == List_kind) { /* First change a list into tuple. */ - asdl_seq *elts = arg->v.List.elts; + asdl_expr_seq *elts = arg->v.List.elts; Py_ssize_t n = asdl_seq_LEN(elts); for (Py_ssize_t i = 0; i < n; i++) { expr_ty e = (expr_ty)asdl_seq_GET(elts, i); @@ -368,7 +383,7 @@ static int fold_compare(expr_ty node, PyArena *arena, _PyASTOptimizeState *state) { asdl_int_seq *ops; - asdl_seq *args; + asdl_expr_seq *args; Py_ssize_t i; ops = node->v.Compare.ops; @@ -395,6 +410,9 @@ static int astfold_keyword(keyword_ty node_, PyArena *ctx_, _PyASTOptimizeState static int astfold_arg(arg_ty node_, PyArena *ctx_, _PyASTOptimizeState *state); static int astfold_withitem(withitem_ty node_, PyArena *ctx_, _PyASTOptimizeState *state); static int astfold_excepthandler(excepthandler_ty node_, PyArena *ctx_, _PyASTOptimizeState *state); +static int astfold_match_case(match_case_ty node_, PyArena *ctx_, _PyASTOptimizeState *state); +static int astfold_pattern(pattern_ty node_, PyArena *ctx_, _PyASTOptimizeState *state); + #define CALL(FUNC, TYPE, ARG) \ if (!FUNC((ARG), ctx_, state)) \ return 0; @@ -405,9 +423,9 @@ static int astfold_excepthandler(excepthandler_ty node_, PyArena *ctx_, _PyASTOp #define CALL_SEQ(FUNC, TYPE, ARG) { \ int i; \ - asdl_seq *seq = (ARG); /* avoid variable capture */ \ + asdl_ ## TYPE ## _seq *seq = (ARG); /* avoid variable capture */ \ for (i = 0; i < asdl_seq_LEN(seq); i++) { \ - TYPE elt = (TYPE)asdl_seq_GET(seq, i); \ + TYPE ## _ty elt = (TYPE ## _ty)asdl_seq_GET(seq, i); \ if (elt != NULL && !FUNC(elt, ctx_, state)) \ return 0; \ } \ @@ -424,19 +442,20 @@ static int astfold_excepthandler(excepthandler_ty node_, PyArena *ctx_, _PyASTOp } static int -astfold_body(asdl_seq *stmts, PyArena *ctx_, _PyASTOptimizeState *state) +astfold_body(asdl_stmt_seq *stmts, PyArena *ctx_, _PyASTOptimizeState *state) { int docstring = _PyAST_GetDocString(stmts) != NULL; - CALL_SEQ(astfold_stmt, stmt_ty, stmts); + CALL_SEQ(astfold_stmt, stmt, stmts); if (!docstring && _PyAST_GetDocString(stmts) != NULL) { stmt_ty st = (stmt_ty)asdl_seq_GET(stmts, 0); - asdl_seq *values = _Py_asdl_seq_new(1, ctx_); + asdl_expr_seq *values = _Py_asdl_expr_seq_new(1, ctx_); if (!values) { return 0; } asdl_seq_SET(values, 0, st->v.Expr.value); - expr_ty expr = JoinedStr(values, st->lineno, st->col_offset, - st->end_lineno, st->end_col_offset, ctx_); + expr_ty expr = _PyAST_JoinedStr(values, st->lineno, st->col_offset, + st->end_lineno, st->end_col_offset, + ctx_); if (!expr) { return 0; } @@ -453,13 +472,16 @@ astfold_mod(mod_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) CALL(astfold_body, asdl_seq, node_->v.Module.body); break; case Interactive_kind: - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.Interactive.body); + CALL_SEQ(astfold_stmt, stmt, node_->v.Interactive.body); break; case Expression_kind: CALL(astfold_expr, expr_ty, node_->v.Expression.body); break; - default: + // The following top level nodes don't participate in constant folding + case FunctionType_kind: break; + // No default case, so the compiler will emit a warning if new top level + // compilation nodes are added without being handled here } return 1; } @@ -467,9 +489,14 @@ astfold_mod(mod_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) static int astfold_expr(expr_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) { + if (++state->recursion_depth > state->recursion_limit) { + PyErr_SetString(PyExc_RecursionError, + "maximum recursion depth exceeded during compilation"); + return 0; + } switch (node_->kind) { case BoolOp_kind: - CALL_SEQ(astfold_expr, expr_ty, node_->v.BoolOp.values); + CALL_SEQ(astfold_expr, expr, node_->v.BoolOp.values); break; case BinOp_kind: CALL(astfold_expr, expr_ty, node_->v.BinOp.left); @@ -490,28 +517,28 @@ astfold_expr(expr_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) CALL(astfold_expr, expr_ty, node_->v.IfExp.orelse); break; case Dict_kind: - CALL_SEQ(astfold_expr, expr_ty, node_->v.Dict.keys); - CALL_SEQ(astfold_expr, expr_ty, node_->v.Dict.values); + CALL_SEQ(astfold_expr, expr, node_->v.Dict.keys); + CALL_SEQ(astfold_expr, expr, node_->v.Dict.values); break; case Set_kind: - CALL_SEQ(astfold_expr, expr_ty, node_->v.Set.elts); + CALL_SEQ(astfold_expr, expr, node_->v.Set.elts); break; case ListComp_kind: CALL(astfold_expr, expr_ty, node_->v.ListComp.elt); - CALL_SEQ(astfold_comprehension, comprehension_ty, node_->v.ListComp.generators); + CALL_SEQ(astfold_comprehension, comprehension, node_->v.ListComp.generators); break; case SetComp_kind: CALL(astfold_expr, expr_ty, node_->v.SetComp.elt); - CALL_SEQ(astfold_comprehension, comprehension_ty, node_->v.SetComp.generators); + CALL_SEQ(astfold_comprehension, comprehension, node_->v.SetComp.generators); break; case DictComp_kind: CALL(astfold_expr, expr_ty, node_->v.DictComp.key); CALL(astfold_expr, expr_ty, node_->v.DictComp.value); - CALL_SEQ(astfold_comprehension, comprehension_ty, node_->v.DictComp.generators); + CALL_SEQ(astfold_comprehension, comprehension, node_->v.DictComp.generators); break; case GeneratorExp_kind: CALL(astfold_expr, expr_ty, node_->v.GeneratorExp.elt); - CALL_SEQ(astfold_comprehension, comprehension_ty, node_->v.GeneratorExp.generators); + CALL_SEQ(astfold_comprehension, comprehension, node_->v.GeneratorExp.generators); break; case Await_kind: CALL(astfold_expr, expr_ty, node_->v.Await.value); @@ -524,20 +551,20 @@ astfold_expr(expr_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) break; case Compare_kind: CALL(astfold_expr, expr_ty, node_->v.Compare.left); - CALL_SEQ(astfold_expr, expr_ty, node_->v.Compare.comparators); + CALL_SEQ(astfold_expr, expr, node_->v.Compare.comparators); CALL(fold_compare, expr_ty, node_); break; case Call_kind: CALL(astfold_expr, expr_ty, node_->v.Call.func); - CALL_SEQ(astfold_expr, expr_ty, node_->v.Call.args); - CALL_SEQ(astfold_keyword, keyword_ty, node_->v.Call.keywords); + CALL_SEQ(astfold_expr, expr, node_->v.Call.args); + CALL_SEQ(astfold_keyword, keyword, node_->v.Call.keywords); break; case FormattedValue_kind: CALL(astfold_expr, expr_ty, node_->v.FormattedValue.value); CALL_OPT(astfold_expr, expr_ty, node_->v.FormattedValue.format_spec); break; case JoinedStr_kind: - CALL_SEQ(astfold_expr, expr_ty, node_->v.JoinedStr.values); + CALL_SEQ(astfold_expr, expr, node_->v.JoinedStr.values); break; case Attribute_kind: CALL(astfold_expr, expr_ty, node_->v.Attribute.value); @@ -556,21 +583,29 @@ astfold_expr(expr_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) CALL_OPT(astfold_expr, expr_ty, node_->v.Slice.step); break; case List_kind: - CALL_SEQ(astfold_expr, expr_ty, node_->v.List.elts); + CALL_SEQ(astfold_expr, expr, node_->v.List.elts); break; case Tuple_kind: - CALL_SEQ(astfold_expr, expr_ty, node_->v.Tuple.elts); + CALL_SEQ(astfold_expr, expr, node_->v.Tuple.elts); CALL(fold_tuple, expr_ty, node_); break; case Name_kind: if (node_->v.Name.ctx == Load && _PyUnicode_EqualToASCIIString(node_->v.Name.id, "__debug__")) { + state->recursion_depth--; return make_const(node_, PyBool_FromLong(!state->optimize), ctx_); } break; - default: + case NamedExpr_kind: + CALL(astfold_expr, expr_ty, node_->v.NamedExpr.value); + break; + case Constant_kind: + // Already a constant, nothing further to do break; + // No default case, so the compiler will emit a warning if new expression + // kinds are added without being handled here } + state->recursion_depth--; return 1; } @@ -586,7 +621,7 @@ astfold_comprehension(comprehension_ty node_, PyArena *ctx_, _PyASTOptimizeState { CALL(astfold_expr, expr_ty, node_->target); CALL(astfold_expr, expr_ty, node_->iter); - CALL_SEQ(astfold_expr, expr_ty, node_->ifs); + CALL_SEQ(astfold_expr, expr, node_->ifs); CALL(fold_iter, expr_ty, node_->iter); return 1; @@ -595,13 +630,13 @@ astfold_comprehension(comprehension_ty node_, PyArena *ctx_, _PyASTOptimizeState static int astfold_arguments(arguments_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) { - CALL_SEQ(astfold_arg, arg_ty, node_->posonlyargs); - CALL_SEQ(astfold_arg, arg_ty, node_->args); + CALL_SEQ(astfold_arg, arg, node_->posonlyargs); + CALL_SEQ(astfold_arg, arg, node_->args); CALL_OPT(astfold_arg, arg_ty, node_->vararg); - CALL_SEQ(astfold_arg, arg_ty, node_->kwonlyargs); - CALL_SEQ(astfold_expr, expr_ty, node_->kw_defaults); + CALL_SEQ(astfold_arg, arg, node_->kwonlyargs); + CALL_SEQ(astfold_expr, expr, node_->kw_defaults); CALL_OPT(astfold_arg, arg_ty, node_->kwarg); - CALL_SEQ(astfold_expr, expr_ty, node_->defaults); + CALL_SEQ(astfold_expr, expr, node_->defaults); return 1; } @@ -617,11 +652,16 @@ astfold_arg(arg_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) static int astfold_stmt(stmt_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) { + if (++state->recursion_depth > state->recursion_limit) { + PyErr_SetString(PyExc_RecursionError, + "maximum recursion depth exceeded during compilation"); + return 0; + } switch (node_->kind) { case FunctionDef_kind: CALL(astfold_arguments, arguments_ty, node_->v.FunctionDef.args); CALL(astfold_body, asdl_seq, node_->v.FunctionDef.body); - CALL_SEQ(astfold_expr, expr_ty, node_->v.FunctionDef.decorator_list); + CALL_SEQ(astfold_expr, expr, node_->v.FunctionDef.decorator_list); if (!(state->ff_features & CO_FUTURE_ANNOTATIONS)) { CALL_OPT(astfold_expr, expr_ty, node_->v.FunctionDef.returns); } @@ -629,25 +669,25 @@ astfold_stmt(stmt_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) case AsyncFunctionDef_kind: CALL(astfold_arguments, arguments_ty, node_->v.AsyncFunctionDef.args); CALL(astfold_body, asdl_seq, node_->v.AsyncFunctionDef.body); - CALL_SEQ(astfold_expr, expr_ty, node_->v.AsyncFunctionDef.decorator_list); + CALL_SEQ(astfold_expr, expr, node_->v.AsyncFunctionDef.decorator_list); if (!(state->ff_features & CO_FUTURE_ANNOTATIONS)) { CALL_OPT(astfold_expr, expr_ty, node_->v.AsyncFunctionDef.returns); } break; case ClassDef_kind: - CALL_SEQ(astfold_expr, expr_ty, node_->v.ClassDef.bases); - CALL_SEQ(astfold_keyword, keyword_ty, node_->v.ClassDef.keywords); + CALL_SEQ(astfold_expr, expr, node_->v.ClassDef.bases); + CALL_SEQ(astfold_keyword, keyword, node_->v.ClassDef.keywords); CALL(astfold_body, asdl_seq, node_->v.ClassDef.body); - CALL_SEQ(astfold_expr, expr_ty, node_->v.ClassDef.decorator_list); + CALL_SEQ(astfold_expr, expr, node_->v.ClassDef.decorator_list); break; case Return_kind: CALL_OPT(astfold_expr, expr_ty, node_->v.Return.value); break; case Delete_kind: - CALL_SEQ(astfold_expr, expr_ty, node_->v.Delete.targets); + CALL_SEQ(astfold_expr, expr, node_->v.Delete.targets); break; case Assign_kind: - CALL_SEQ(astfold_expr, expr_ty, node_->v.Assign.targets); + CALL_SEQ(astfold_expr, expr, node_->v.Assign.targets); CALL(astfold_expr, expr_ty, node_->v.Assign.value); break; case AugAssign_kind: @@ -664,44 +704,44 @@ astfold_stmt(stmt_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) case For_kind: CALL(astfold_expr, expr_ty, node_->v.For.target); CALL(astfold_expr, expr_ty, node_->v.For.iter); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.For.body); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.For.orelse); + CALL_SEQ(astfold_stmt, stmt, node_->v.For.body); + CALL_SEQ(astfold_stmt, stmt, node_->v.For.orelse); CALL(fold_iter, expr_ty, node_->v.For.iter); break; case AsyncFor_kind: CALL(astfold_expr, expr_ty, node_->v.AsyncFor.target); CALL(astfold_expr, expr_ty, node_->v.AsyncFor.iter); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.AsyncFor.body); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.AsyncFor.orelse); + CALL_SEQ(astfold_stmt, stmt, node_->v.AsyncFor.body); + CALL_SEQ(astfold_stmt, stmt, node_->v.AsyncFor.orelse); break; case While_kind: CALL(astfold_expr, expr_ty, node_->v.While.test); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.While.body); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.While.orelse); + CALL_SEQ(astfold_stmt, stmt, node_->v.While.body); + CALL_SEQ(astfold_stmt, stmt, node_->v.While.orelse); break; case If_kind: CALL(astfold_expr, expr_ty, node_->v.If.test); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.If.body); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.If.orelse); + CALL_SEQ(astfold_stmt, stmt, node_->v.If.body); + CALL_SEQ(astfold_stmt, stmt, node_->v.If.orelse); break; case With_kind: - CALL_SEQ(astfold_withitem, withitem_ty, node_->v.With.items); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.With.body); + CALL_SEQ(astfold_withitem, withitem, node_->v.With.items); + CALL_SEQ(astfold_stmt, stmt, node_->v.With.body); break; case AsyncWith_kind: - CALL_SEQ(astfold_withitem, withitem_ty, node_->v.AsyncWith.items); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.AsyncWith.body); + CALL_SEQ(astfold_withitem, withitem, node_->v.AsyncWith.items); + CALL_SEQ(astfold_stmt, stmt, node_->v.AsyncWith.body); break; case Raise_kind: CALL_OPT(astfold_expr, expr_ty, node_->v.Raise.exc); CALL_OPT(astfold_expr, expr_ty, node_->v.Raise.cause); break; case Try_kind: - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.Try.body); - CALL_SEQ(astfold_excepthandler, excepthandler_ty, node_->v.Try.handlers); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.Try.orelse); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.Try.finalbody); + CALL_SEQ(astfold_stmt, stmt, node_->v.Try.body); + CALL_SEQ(astfold_excepthandler, excepthandler, node_->v.Try.handlers); + CALL_SEQ(astfold_stmt, stmt, node_->v.Try.orelse); + CALL_SEQ(astfold_stmt, stmt, node_->v.Try.finalbody); break; case Assert_kind: CALL(astfold_expr, expr_ty, node_->v.Assert.test); @@ -710,9 +750,23 @@ astfold_stmt(stmt_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) case Expr_kind: CALL(astfold_expr, expr_ty, node_->v.Expr.value); break; - default: - break; + case Match_kind: + CALL(astfold_expr, expr_ty, node_->v.Match.subject); + CALL_SEQ(astfold_match_case, match_case, node_->v.Match.cases); + break; + // The following statements don't contain any subexpressions to be folded + case Import_kind: + case ImportFrom_kind: + case Global_kind: + case Nonlocal_kind: + case Pass_kind: + case Break_kind: + case Continue_kind: + break; + // No default case, so the compiler will emit a warning if new statement + // kinds are added without being handled here } + state->recursion_depth--; return 1; } @@ -722,10 +776,10 @@ astfold_excepthandler(excepthandler_ty node_, PyArena *ctx_, _PyASTOptimizeState switch (node_->kind) { case ExceptHandler_kind: CALL_OPT(astfold_expr, expr_ty, node_->v.ExceptHandler.type); - CALL_SEQ(astfold_stmt, stmt_ty, node_->v.ExceptHandler.body); - break; - default: + CALL_SEQ(astfold_stmt, stmt, node_->v.ExceptHandler.body); break; + // No default case, so the compiler will emit a warning if new handler + // kinds are added without being handled here } return 1; } @@ -738,15 +792,98 @@ astfold_withitem(withitem_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) return 1; } +static int +astfold_pattern(pattern_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) +{ + // Currently, this is really only used to form complex/negative numeric + // constants in MatchValue and MatchMapping nodes + // We still recurse into all subexpressions and subpatterns anyway + if (++state->recursion_depth > state->recursion_limit) { + PyErr_SetString(PyExc_RecursionError, + "maximum recursion depth exceeded during compilation"); + return 0; + } + switch (node_->kind) { + case MatchValue_kind: + CALL(astfold_expr, expr_ty, node_->v.MatchValue.value); + break; + case MatchSingleton_kind: + break; + case MatchSequence_kind: + CALL_SEQ(astfold_pattern, pattern, node_->v.MatchSequence.patterns); + break; + case MatchMapping_kind: + CALL_SEQ(astfold_expr, expr, node_->v.MatchMapping.keys); + CALL_SEQ(astfold_pattern, pattern, node_->v.MatchMapping.patterns); + break; + case MatchClass_kind: + CALL(astfold_expr, expr_ty, node_->v.MatchClass.cls); + CALL_SEQ(astfold_pattern, pattern, node_->v.MatchClass.patterns); + CALL_SEQ(astfold_pattern, pattern, node_->v.MatchClass.kwd_patterns); + break; + case MatchStar_kind: + break; + case MatchAs_kind: + if (node_->v.MatchAs.pattern) { + CALL(astfold_pattern, pattern_ty, node_->v.MatchAs.pattern); + } + break; + case MatchOr_kind: + CALL_SEQ(astfold_pattern, pattern, node_->v.MatchOr.patterns); + break; + // No default case, so the compiler will emit a warning if new pattern + // kinds are added without being handled here + } + state->recursion_depth--; + return 1; +} + +static int +astfold_match_case(match_case_ty node_, PyArena *ctx_, _PyASTOptimizeState *state) +{ + CALL(astfold_pattern, expr_ty, node_->pattern); + CALL_OPT(astfold_expr, expr_ty, node_->guard); + CALL_SEQ(astfold_stmt, stmt, node_->body); + return 1; +} + #undef CALL #undef CALL_OPT #undef CALL_SEQ #undef CALL_INT_SEQ +/* See comments in symtable.c. */ +#define COMPILER_STACK_FRAME_SCALE 3 + int _PyAST_Optimize(mod_ty mod, PyArena *arena, _PyASTOptimizeState *state) { + PyThreadState *tstate; + int recursion_limit = Py_GetRecursionLimit(); + int starting_recursion_depth; + + /* Setup recursion depth check counters */ + tstate = _PyThreadState_GET(); + if (!tstate) { + return 0; + } + /* Be careful here to prevent overflow. */ + starting_recursion_depth = (tstate->recursion_depth < INT_MAX / COMPILER_STACK_FRAME_SCALE) ? + tstate->recursion_depth * COMPILER_STACK_FRAME_SCALE : tstate->recursion_depth; + state->recursion_depth = starting_recursion_depth; + state->recursion_limit = (recursion_limit < INT_MAX / COMPILER_STACK_FRAME_SCALE) ? + recursion_limit * COMPILER_STACK_FRAME_SCALE : recursion_limit; + int ret = astfold_mod(mod, arena, state); assert(ret || PyErr_Occurred()); + + /* Check that the recursion depth counting balanced correctly */ + if (ret && state->recursion_depth != starting_recursion_depth) { + PyErr_Format(PyExc_SystemError, + "AST optimizer recursion depth mismatch (before=%d, after=%d)", + starting_recursion_depth, state->recursion_depth); + return 0; + } + return ret; } diff --git a/contrib/tools/python3/src/Python/ast_unparse.c b/contrib/tools/python3/src/Python/ast_unparse.c index e699751a05a..126e9047d58 100644 --- a/contrib/tools/python3/src/Python/ast_unparse.c +++ b/contrib/tools/python3/src/Python/ast_unparse.c @@ -1,7 +1,12 @@ -#include <float.h> /* DBL_MAX_10_EXP */ -#include <stdbool.h> #include "Python.h" -#include "Python-ast.h" +#include "pycore_ast.h" // expr_ty +#include <float.h> // DBL_MAX_10_EXP +#include <stdbool.h> + +/* This limited unparser is used to convert annotations back to strings + * during compilation rather than being a full AST unparser. + * See ast.unparse for a full unparser (written in Python) + */ static PyObject *_str_open_br; static PyObject *_str_dbl_open_br; @@ -117,7 +122,7 @@ static int append_ast_boolop(_PyUnicodeWriter *writer, expr_ty e, int level) { Py_ssize_t i, value_count; - asdl_seq *values; + asdl_expr_seq *values; const char *op = (e->v.BoolOp.op == And) ? " and " : " or "; int pr = (e->v.BoolOp.op == And) ? PR_AND : PR_OR; @@ -398,7 +403,7 @@ append_ast_comprehension(_PyUnicodeWriter *writer, comprehension_ty gen) } static int -append_ast_comprehensions(_PyUnicodeWriter *writer, asdl_seq *comprehensions) +append_ast_comprehensions(_PyUnicodeWriter *writer, asdl_comprehension_seq *comprehensions) { Py_ssize_t i, gen_count; gen_count = asdl_seq_LEN(comprehensions); @@ -453,7 +458,7 @@ append_ast_compare(_PyUnicodeWriter *writer, expr_ty e, int level) { const char *op; Py_ssize_t i, comparator_count; - asdl_seq *comparators; + asdl_expr_seq *comparators; asdl_int_seq *ops; APPEND_STR_IF(level > PR_CMP, "("); @@ -612,7 +617,7 @@ append_fstring_element(_PyUnicodeWriter *writer, expr_ty e, bool is_format_spec) /* Build body separately to enable wrapping the entire stream of Strs, Constants and FormattedValues in one opening and one closing quote. */ static PyObject * -build_fstring_body(asdl_seq *values, bool is_format_spec) +build_fstring_body(asdl_expr_seq *values, bool is_format_spec) { Py_ssize_t i, value_count; _PyUnicodeWriter body_writer; @@ -912,11 +917,11 @@ append_ast_expr(_PyUnicodeWriter *writer, expr_ty e, int level) return append_ast_tuple(writer, e, level); case NamedExpr_kind: return append_named_expr(writer, e, level); - default: - PyErr_SetString(PyExc_SystemError, - "unknown expression kind"); - return -1; + // No default so compiler emits a warning for unhandled cases } + PyErr_SetString(PyExc_SystemError, + "unknown expression kind"); + return -1; } static int diff --git a/contrib/tools/python3/src/Python/bltinmodule.c b/contrib/tools/python3/src/Python/bltinmodule.c index 21c70f9a6c7..b0162e5e872 100644 --- a/contrib/tools/python3/src/Python/bltinmodule.c +++ b/contrib/tools/python3/src/Python/bltinmodule.c @@ -2,12 +2,13 @@ #include "Python.h" #include <ctype.h> -#include "ast.h" -#undef Yield /* undefine macro conflicting with <winbase.h> */ -#include "pycore_object.h" -#include "pycore_pyerrors.h" -#include "pycore_pystate.h" // _PyThreadState_GET() -#include "pycore_tupleobject.h" +#include "pycore_ast.h" // _PyAST_Validate() +#include "pycore_compile.h" // _PyAST_Compile() +#include "pycore_object.h" // _Py_AddToAllObjects() +#include "pycore_pyerrors.h" // _PyErr_NoMemory() +#include "pycore_pystate.h" // _PyThreadState_GET() +#include "pycore_tuple.h" // _PyTuple_FromArray() +#include "pycore_ceval.h" // _PyEval_Vector() _Py_IDENTIFIER(__builtins__); _Py_IDENTIFIER(__dict__); @@ -210,9 +211,9 @@ builtin___build_class__(PyObject *self, PyObject *const *args, Py_ssize_t nargs, Py_TYPE(ns)->tp_name); goto error; } - cell = PyEval_EvalCodeEx(PyFunction_GET_CODE(func), PyFunction_GET_GLOBALS(func), ns, - NULL, 0, NULL, 0, NULL, 0, NULL, - PyFunction_GET_CLOSURE(func)); + PyFrameConstructor *f = PyFunction_AS_FRAME_CONSTRUCTOR(func); + PyThreadState *tstate = PyThreadState_GET(); + cell = _PyEval_Vector(tstate, f, ns, NULL, 0, NULL); if (cell != NULL) { if (bases != orig_bases) { if (PyMapping_SetItemString(ns, "__orig_bases__", orig_bases) < 0) { @@ -523,8 +524,40 @@ filter_new(PyTypeObject *type, PyObject *args, PyObject *kwds) Py_DECREF(it); return NULL; } - Py_INCREF(func); - lz->func = func; + + lz->func = Py_NewRef(func); + lz->it = it; + + return (PyObject *)lz; +} + +static PyObject * +filter_vectorcall(PyObject *type, PyObject * const*args, + size_t nargsf, PyObject *kwnames) +{ + PyTypeObject *tp = (PyTypeObject *)type; + if (tp == &PyFilter_Type && !_PyArg_NoKwnames("filter", kwnames)) { + return NULL; + } + + Py_ssize_t nargs = PyVectorcall_NARGS(nargsf); + if (!_PyArg_CheckPositional("filter", nargs, 2, 2)) { + return NULL; + } + + PyObject *it = PyObject_GetIter(args[1]); + if (it == NULL) { + return NULL; + } + + filterobject *lz = (filterobject *)tp->tp_alloc(tp, 0); + + if (lz == NULL) { + Py_DECREF(it); + return NULL; + } + + lz->func = Py_NewRef(args[0]); lz->it = it; return (PyObject *)lz; @@ -643,6 +676,7 @@ PyTypeObject PyFilter_Type = { PyType_GenericAlloc, /* tp_alloc */ filter_new, /* tp_new */ PyObject_GC_Del, /* tp_free */ + .tp_vectorcall = (vectorcallfunc)filter_vectorcall }; @@ -784,21 +818,17 @@ builtin_compile_impl(PyObject *module, PyObject *source, PyObject *filename, PyArena *arena; mod_ty mod; - arena = PyArena_New(); + arena = _PyArena_New(); if (arena == NULL) goto error; mod = PyAST_obj2mod(source, arena, compile_mode); - if (mod == NULL) { - PyArena_Free(arena); + if (mod == NULL || !_PyAST_Validate(mod)) { + _PyArena_Free(arena); goto error; } - if (!PyAST_Validate(mod)) { - PyArena_Free(arena); - goto error; - } - result = (PyObject*)PyAST_CompileObject(mod, filename, - &cf, optimize, arena); - PyArena_Free(arena); + result = (PyObject*)_PyAST_Compile(mod, filename, + &cf, optimize, arena); + _PyArena_Free(arena); } goto finally; } @@ -915,12 +945,12 @@ builtin_eval_impl(PyObject *module, PyObject *source, PyObject *globals, return NULL; } - if (_PyDict_GetItemIdWithError(globals, &PyId___builtins__) == NULL) { - if (_PyDict_SetItemId(globals, &PyId___builtins__, - PyEval_GetBuiltins()) != 0) - return NULL; + int r = _PyDict_ContainsId(globals, &PyId___builtins__); + if (r == 0) { + r = _PyDict_SetItemId(globals, &PyId___builtins__, + PyEval_GetBuiltins()); } - else if (PyErr_Occurred()) { + if (r < 0) { return NULL; } @@ -1003,12 +1033,12 @@ builtin_exec_impl(PyObject *module, PyObject *source, PyObject *globals, Py_TYPE(locals)->tp_name); return NULL; } - if (_PyDict_GetItemIdWithError(globals, &PyId___builtins__) == NULL) { - if (_PyDict_SetItemId(globals, &PyId___builtins__, - PyEval_GetBuiltins()) != 0) - return NULL; + int r = _PyDict_ContainsId(globals, &PyId___builtins__); + if (r == 0) { + r = _PyDict_SetItemId(globals, &PyId___builtins__, + PyEval_GetBuiltins()); } - else if (PyErr_Occurred()) { + if (r < 0) { return NULL; } @@ -1220,8 +1250,48 @@ map_new(PyTypeObject *type, PyObject *args, PyObject *kwds) } lz->iters = iters; func = PyTuple_GET_ITEM(args, 0); - Py_INCREF(func); - lz->func = func; + lz->func = Py_NewRef(func); + + return (PyObject *)lz; +} + +static PyObject * +map_vectorcall(PyObject *type, PyObject * const*args, + size_t nargsf, PyObject *kwnames) +{ + PyTypeObject *tp = (PyTypeObject *)type; + if (tp == &PyMap_Type && !_PyArg_NoKwnames("map", kwnames)) { + return NULL; + } + + Py_ssize_t nargs = PyVectorcall_NARGS(nargsf); + if (nargs < 2) { + PyErr_SetString(PyExc_TypeError, + "map() must have at least two arguments."); + return NULL; + } + + PyObject *iters = PyTuple_New(nargs-1); + if (iters == NULL) { + return NULL; + } + + for (int i=1; i<nargs; i++) { + PyObject *it = PyObject_GetIter(args[i]); + if (it == NULL) { + Py_DECREF(iters); + return NULL; + } + PyTuple_SET_ITEM(iters, i-1, it); + } + + mapobject *lz = (mapobject *)tp->tp_alloc(tp, 0); + if (lz == NULL) { + Py_DECREF(iters); + return NULL; + } + lz->iters = iters; + lz->func = Py_NewRef(args[0]); return (PyObject *)lz; } @@ -1359,6 +1429,7 @@ PyTypeObject PyMap_Type = { PyType_GenericAlloc, /* tp_alloc */ map_new, /* tp_new */ PyObject_GC_Del, /* tp_free */ + .tp_vectorcall = (vectorcallfunc)map_vectorcall }; @@ -1527,6 +1598,62 @@ In the second form, the callable is called until it returns the sentinel."); /*[clinic input] +aiter as builtin_aiter + + async_iterable: object + / + +Return an AsyncIterator for an AsyncIterable object. +[clinic start generated code]*/ + +static PyObject * +builtin_aiter(PyObject *module, PyObject *async_iterable) +/*[clinic end generated code: output=1bae108d86f7960e input=473993d0cacc7d23]*/ +{ + return PyObject_GetAIter(async_iterable); +} + +PyObject *PyAnextAwaitable_New(PyObject *, PyObject *); + +/*[clinic input] +anext as builtin_anext + + aiterator: object + default: object = NULL + / + +Return the next item from the async iterator. +[clinic start generated code]*/ + +static PyObject * +builtin_anext_impl(PyObject *module, PyObject *aiterator, + PyObject *default_value) +/*[clinic end generated code: output=f02c060c163a81fa input=699d11f4e38eca24]*/ +{ + PyTypeObject *t; + PyObject *awaitable; + + t = Py_TYPE(aiterator); + if (t->tp_as_async == NULL || t->tp_as_async->am_anext == NULL) { + PyErr_Format(PyExc_TypeError, + "'%.200s' object is not an async iterator", + t->tp_name); + return NULL; + } + + awaitable = (*t->tp_as_async->am_anext)(aiterator); + if (default_value == NULL) { + return awaitable; + } + + PyObject* new_awaitable = PyAnextAwaitable_New( + awaitable, default_value); + Py_DECREF(awaitable); + return new_awaitable; +} + + +/*[clinic input] len as builtin_len obj: object @@ -2080,7 +2207,7 @@ builtin_input_impl(PyObject *module, PyObject *prompt) Py_DECREF(stdin_encoding); Py_DECREF(stdin_errors); Py_XDECREF(po); - PyMem_FREE(s); + PyMem_Free(s); if (result != NULL) { if (PySys_Audit("builtins.input/result", "O", result) < 0) { @@ -2485,17 +2612,17 @@ issubclass as builtin_issubclass class_or_tuple: object / -Return whether 'cls' is a derived from another class or is the same class. +Return whether 'cls' is derived from another class or is the same class. A tuple, as in ``issubclass(x, (A, B, ...))``, may be given as the target to check against. This is equivalent to ``issubclass(x, A) or issubclass(x, B) -or ...`` etc. +or ...``. [clinic start generated code]*/ static PyObject * builtin_issubclass_impl(PyObject *module, PyObject *cls, PyObject *class_or_tuple) -/*[clinic end generated code: output=358412410cd7a250 input=af5f35e9ceaddaf6]*/ +/*[clinic end generated code: output=358412410cd7a250 input=a24b9f3d58c370d6]*/ { int retval; @@ -2508,9 +2635,10 @@ builtin_issubclass_impl(PyObject *module, PyObject *cls, typedef struct { PyObject_HEAD - Py_ssize_t tuplesize; - PyObject *ittuple; /* tuple of iterators */ + Py_ssize_t tuplesize; + PyObject *ittuple; /* tuple of iterators */ PyObject *result; + int strict; } zipobject; static PyObject * @@ -2521,9 +2649,21 @@ zip_new(PyTypeObject *type, PyObject *args, PyObject *kwds) PyObject *ittuple; /* tuple of iterators */ PyObject *result; Py_ssize_t tuplesize; + int strict = 0; - if (type == &PyZip_Type && !_PyArg_NoKeywords("zip", kwds)) - return NULL; + if (kwds) { + PyObject *empty = PyTuple_New(0); + if (empty == NULL) { + return NULL; + } + static char *kwlist[] = {"strict", NULL}; + int parsed = PyArg_ParseTupleAndKeywords( + empty, kwds, "|$p:zip", kwlist, &strict); + Py_DECREF(empty); + if (!parsed) { + return NULL; + } + } /* args must be a tuple */ assert(PyTuple_Check(args)); @@ -2564,6 +2704,7 @@ zip_new(PyTypeObject *type, PyObject *args, PyObject *kwds) lz->ittuple = ittuple; lz->tuplesize = tuplesize; lz->result = result; + lz->strict = strict; return (PyObject *)lz; } @@ -2604,6 +2745,9 @@ zip_next(zipobject *lz) item = (*Py_TYPE(it)->tp_iternext)(it); if (item == NULL) { Py_DECREF(result); + if (lz->strict) { + goto check; + } return NULL; } olditem = PyTuple_GET_ITEM(result, i); @@ -2624,28 +2768,85 @@ zip_next(zipobject *lz) item = (*Py_TYPE(it)->tp_iternext)(it); if (item == NULL) { Py_DECREF(result); + if (lz->strict) { + goto check; + } return NULL; } PyTuple_SET_ITEM(result, i, item); } } return result; +check: + if (PyErr_Occurred()) { + if (!PyErr_ExceptionMatches(PyExc_StopIteration)) { + // next() on argument i raised an exception (not StopIteration) + return NULL; + } + PyErr_Clear(); + } + if (i) { + // ValueError: zip() argument 2 is shorter than argument 1 + // ValueError: zip() argument 3 is shorter than arguments 1-2 + const char* plural = i == 1 ? " " : "s 1-"; + return PyErr_Format(PyExc_ValueError, + "zip() argument %d is shorter than argument%s%d", + i + 1, plural, i); + } + for (i = 1; i < tuplesize; i++) { + it = PyTuple_GET_ITEM(lz->ittuple, i); + item = (*Py_TYPE(it)->tp_iternext)(it); + if (item) { + Py_DECREF(item); + const char* plural = i == 1 ? " " : "s 1-"; + return PyErr_Format(PyExc_ValueError, + "zip() argument %d is longer than argument%s%d", + i + 1, plural, i); + } + if (PyErr_Occurred()) { + if (!PyErr_ExceptionMatches(PyExc_StopIteration)) { + // next() on argument i raised an exception (not StopIteration) + return NULL; + } + PyErr_Clear(); + } + // Argument i is exhausted. So far so good... + } + // All arguments are exhausted. Success! + return NULL; } static PyObject * zip_reduce(zipobject *lz, PyObject *Py_UNUSED(ignored)) { /* Just recreate the zip with the internal iterator tuple */ - return Py_BuildValue("OO", Py_TYPE(lz), lz->ittuple); + if (lz->strict) { + return PyTuple_Pack(3, Py_TYPE(lz), lz->ittuple, Py_True); + } + return PyTuple_Pack(2, Py_TYPE(lz), lz->ittuple); +} + +PyDoc_STRVAR(setstate_doc, "Set state information for unpickling."); + +static PyObject * +zip_setstate(zipobject *lz, PyObject *state) +{ + int strict = PyObject_IsTrue(state); + if (strict < 0) { + return NULL; + } + lz->strict = strict; + Py_RETURN_NONE; } static PyMethodDef zip_methods[] = { {"__reduce__", (PyCFunction)zip_reduce, METH_NOARGS, reduce_doc}, - {NULL, NULL} /* sentinel */ + {"__setstate__", (PyCFunction)zip_setstate, METH_O, setstate_doc}, + {NULL} /* sentinel */ }; PyDoc_STRVAR(zip_doc, -"zip(*iterables) --> A zip object yielding tuples until an input is exhausted.\n\ +"zip(*iterables, strict=False) --> Yield tuples until an input is exhausted.\n\ \n\ >>> list(zip('abcdefg', range(3), range(4)))\n\ [('a', 0, 0), ('b', 1, 1), ('c', 2, 2)]\n\ @@ -2653,7 +2854,10 @@ PyDoc_STRVAR(zip_doc, The zip object yields n-length tuples, where n is the number of iterables\n\ passed as positional arguments to zip(). The i-th element in every tuple\n\ comes from the i-th iterable argument to zip(). This continues until the\n\ -shortest argument is exhausted."); +shortest argument is exhausted.\n\ +\n\ +If strict is true and one of the arguments is exhausted before the others,\n\ +raise a ValueError."); PyTypeObject PyZip_Type = { PyVarObject_HEAD_INIT(&PyType_Type, 0) @@ -2729,11 +2933,13 @@ static PyMethodDef builtin_methods[] = { BUILTIN_ISINSTANCE_METHODDEF BUILTIN_ISSUBCLASS_METHODDEF {"iter", (PyCFunction)(void(*)(void))builtin_iter, METH_FASTCALL, iter_doc}, + BUILTIN_AITER_METHODDEF BUILTIN_LEN_METHODDEF BUILTIN_LOCALS_METHODDEF {"max", (PyCFunction)(void(*)(void))builtin_max, METH_VARARGS | METH_KEYWORDS, max_doc}, {"min", (PyCFunction)(void(*)(void))builtin_min, METH_VARARGS | METH_KEYWORDS, min_doc}, {"next", (PyCFunction)(void(*)(void))builtin_next, METH_FASTCALL, next_doc}, + BUILTIN_ANEXT_METHODDEF BUILTIN_OCT_METHODDEF BUILTIN_ORD_METHODDEF BUILTIN_POW_METHODDEF @@ -2766,11 +2972,11 @@ static struct PyModuleDef builtinsmodule = { PyObject * -_PyBuiltin_Init(PyThreadState *tstate) +_PyBuiltin_Init(PyInterpreterState *interp) { PyObject *mod, *dict, *debug; - const PyConfig *config = _PyInterpreterState_GetConfig(tstate->interp); + const PyConfig *config = _PyInterpreterState_GetConfig(interp); if (PyType_Ready(&PyFilter_Type) < 0 || PyType_Ready(&PyMap_Type) < 0 || diff --git a/contrib/tools/python3/src/Python/bootstrap_hash.c b/contrib/tools/python3/src/Python/bootstrap_hash.c index e189ce0d901..77ccbee18d4 100644 --- a/contrib/tools/python3/src/Python/bootstrap_hash.c +++ b/contrib/tools/python3/src/Python/bootstrap_hash.c @@ -144,6 +144,11 @@ py_getrandom(void *buffer, Py_ssize_t size, int blocking, int raise) else { n = getrandom(dest, n, flags); } +# ifdef _Py_MEMORY_SANITIZER + if (n > 0) { + __msan_unpoison(dest, n); + } +# endif #else /* On Linux, use the syscall() function because the GNU libc doesn't expose the Linux getrandom() syscall yet. See: diff --git a/contrib/tools/python3/src/Python/ceval.c b/contrib/tools/python3/src/Python/ceval.c index 9a61f8a3c3c..21674e0be13 100644 --- a/contrib/tools/python3/src/Python/ceval.c +++ b/contrib/tools/python3/src/Python/ceval.c @@ -1,4 +1,3 @@ - /* Execute compiled code */ /* XXX TO DO: @@ -7,21 +6,22 @@ */ /* enable more aggressive intra-module optimizations, where available */ +/* affects both release and debug builds - see bpo-43271 */ #define PY_LOCAL_AGGRESSIVE #include "Python.h" #include "pycore_abstract.h" // _PyIndex_Check() -#include "pycore_call.h" -#include "pycore_ceval.h" -#include "pycore_code.h" -#include "pycore_initconfig.h" -#include "pycore_object.h" -#include "pycore_pyerrors.h" -#include "pycore_pylifecycle.h" +#include "pycore_call.h" // _PyObject_FastCallDictTstate() +#include "pycore_ceval.h" // _PyEval_SignalAsyncExc() +#include "pycore_code.h" // _PyCode_InitOpcache() +#include "pycore_initconfig.h" // _PyStatus_OK() +#include "pycore_object.h" // _PyObject_GC_TRACK() +#include "pycore_pyerrors.h" // _PyErr_Fetch() +#include "pycore_pylifecycle.h" // _PyErr_Print() #include "pycore_pymem.h" // _PyMem_IsPtrFreed() #include "pycore_pystate.h" // _PyInterpreterState_GET() -#include "pycore_sysmodule.h" -#include "pycore_tupleobject.h" +#include "pycore_sysmodule.h" // _PySys_Audit() +#include "pycore_tuple.h" // _PyTuple_ITEMS() #include "code.h" #include "dictobject.h" @@ -29,9 +29,17 @@ #include "opcode.h" #include "pydtrace.h" #include "setobject.h" +#include "structmember.h" // struct PyMemberDef, T_OFFSET_EX #include <ctype.h> +typedef struct { + PyCodeObject *code; // The code object for the bounds. May be NULL. + PyCodeAddressRange bounds; // Only valid if code != NULL. + CFrame cframe; +} PyTraceInfo; + + #ifdef Py_DEBUG /* For debugging the interpreter: */ #define LLTRACE 1 /* Low-level trace feature */ @@ -46,10 +54,10 @@ _Py_IDENTIFIER(__name__); /* Forward declarations */ Py_LOCAL_INLINE(PyObject *) call_function( - PyThreadState *tstate, PyObject ***pp_stack, + PyThreadState *tstate, PyTraceInfo *, PyObject ***pp_stack, Py_ssize_t oparg, PyObject *kwnames); static PyObject * do_call_core( - PyThreadState *tstate, PyObject *func, + PyThreadState *tstate, PyTraceInfo *, PyObject *func, PyObject *callargs, PyObject *kwdict); #ifdef LLTRACE @@ -58,16 +66,19 @@ static int prtrace(PyThreadState *, PyObject *, const char *); #endif static int call_trace(Py_tracefunc, PyObject *, PyThreadState *, PyFrameObject *, + PyTraceInfo *, int, PyObject *); static int call_trace_protected(Py_tracefunc, PyObject *, PyThreadState *, PyFrameObject *, + PyTraceInfo *, int, PyObject *); static void call_exc_trace(Py_tracefunc, PyObject *, - PyThreadState *, PyFrameObject *); + PyThreadState *, PyFrameObject *, + PyTraceInfo *trace_info); static int maybe_call_line_trace(Py_tracefunc, PyObject *, PyThreadState *, PyFrameObject *, - int *, int *, int *); -static void maybe_dtrace_line(PyFrameObject *, int *, int *, int *); + PyTraceInfo *, int); +static void maybe_dtrace_line(PyFrameObject *, PyTraceInfo *, int); static void dtrace_function_entry(PyFrameObject *); static void dtrace_function_return(PyFrameObject *); @@ -103,16 +114,19 @@ static long dxp[256]; #endif /* per opcode cache */ -#ifdef Py_DEBUG -// --with-pydebug is used to find memory leak. opcache makes it harder. -// So we disable opcache when Py_DEBUG is defined. -// See bpo-37146 -#define OPCACHE_MIN_RUNS 0 /* disable opcache */ -#else -#define OPCACHE_MIN_RUNS 1024 /* create opcache when code executed this time */ -#endif +static int opcache_min_runs = 1024; /* create opcache when code executed this many times */ +#define OPCODE_CACHE_MAX_TRIES 20 #define OPCACHE_STATS 0 /* Enable stats */ +// This function allows to deactivate the opcode cache. As different cache mechanisms may hold +// references, this can mess with the reference leak detector functionality so the cache needs +// to be deactivated in such scenarios to avoid false positives. See bpo-3714 for more information. +void +_PyEval_DeactivateOpCache(void) +{ + opcache_min_runs = 0; +} + #if OPCACHE_STATS static size_t opcache_code_objects = 0; static size_t opcache_code_objects_extra_mem = 0; @@ -120,6 +134,12 @@ static size_t opcache_code_objects_extra_mem = 0; static size_t opcache_global_opts = 0; static size_t opcache_global_hits = 0; static size_t opcache_global_misses = 0; + +static size_t opcache_attr_opts = 0; +static size_t opcache_attr_hits = 0; +static size_t opcache_attr_misses = 0; +static size_t opcache_attr_deopts = 0; +static size_t opcache_attr_total = 0; #endif @@ -254,8 +274,22 @@ _Py_FatalError_TstateNULL(const char *func) "(the current Python thread state is NULL)"); } +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS +int +_PyEval_ThreadsInitialized(PyInterpreterState *interp) +{ + return gil_created(&interp->ceval.gil); +} int +PyEval_ThreadsInitialized(void) +{ + // Fatal error if there is no current interpreter + PyInterpreterState *interp = PyInterpreterState_Get(); + return _PyEval_ThreadsInitialized(interp); +} +#else +int _PyEval_ThreadsInitialized(_PyRuntimeState *runtime) { return gil_created(&runtime->ceval.gil); @@ -267,18 +301,25 @@ PyEval_ThreadsInitialized(void) _PyRuntimeState *runtime = &_PyRuntime; return _PyEval_ThreadsInitialized(runtime); } +#endif PyStatus _PyEval_InitGIL(PyThreadState *tstate) { - if (!_Py_IsMainInterpreter(tstate)) { +#ifndef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + if (!_Py_IsMainInterpreter(tstate->interp)) { /* Currently, the GIL is shared by all interpreters, and only the main interpreter is responsible to create and destroy it. */ return _PyStatus_OK(); } +#endif +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + struct _gil_runtime_state *gil = &tstate->interp->ceval.gil; +#else struct _gil_runtime_state *gil = &tstate->interp->runtime->ceval.gil; +#endif assert(!gil_created(gil)); PyThread_init_thread(); @@ -291,16 +332,22 @@ _PyEval_InitGIL(PyThreadState *tstate) } void -_PyEval_FiniGIL(PyThreadState *tstate) +_PyEval_FiniGIL(PyInterpreterState *interp) { - if (!_Py_IsMainInterpreter(tstate)) { +#ifndef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + if (!_Py_IsMainInterpreter(interp)) { /* Currently, the GIL is shared by all interpreters, and only the main interpreter is responsible to create and destroy it. */ return; } +#endif - struct _gil_runtime_state *gil = &tstate->interp->runtime->ceval.gil; +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + struct _gil_runtime_state *gil = &interp->ceval.gil; +#else + struct _gil_runtime_state *gil = &interp->runtime->ceval.gil; +#endif if (!gil_created(gil)) { /* First Py_InitializeFromConfig() call: the GIL doesn't exist yet: do nothing. */ @@ -343,6 +390,25 @@ _PyEval_Fini(void) opcache_global_opts); fprintf(stderr, "\n"); + + fprintf(stderr, "-- Opcode cache LOAD_ATTR hits = %zd (%d%%)\n", + opcache_attr_hits, + (int) (100.0 * opcache_attr_hits / + opcache_attr_total)); + + fprintf(stderr, "-- Opcode cache LOAD_ATTR misses = %zd (%d%%)\n", + opcache_attr_misses, + (int) (100.0 * opcache_attr_misses / + opcache_attr_total)); + + fprintf(stderr, "-- Opcode cache LOAD_ATTR opts = %zd\n", + opcache_attr_opts); + + fprintf(stderr, "-- Opcode cache LOAD_ATTR deopts = %zd\n", + opcache_attr_deopts); + + fprintf(stderr, "-- Opcode cache LOAD_ATTR total = %zd\n", + opcache_attr_total); #endif } @@ -385,9 +451,13 @@ PyEval_AcquireThread(PyThreadState *tstate) take_gil(tstate); struct _gilstate_runtime_state *gilstate = &tstate->interp->runtime->gilstate; +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + (void)_PyThreadState_Swap(gilstate, tstate); +#else if (_PyThreadState_Swap(gilstate, tstate) != NULL) { Py_FatalError("non-NULL old thread state"); } +#endif } void @@ -407,19 +477,20 @@ PyEval_ReleaseThread(PyThreadState *tstate) #ifdef HAVE_FORK /* This function is called from PyOS_AfterFork_Child to destroy all threads - * which are not running in the child process, and clear internal locks - * which might be held by those threads. - */ - -void -_PyEval_ReInitThreads(_PyRuntimeState *runtime) + which are not running in the child process, and clear internal locks + which might be held by those threads. */ +PyStatus +_PyEval_ReInitThreads(PyThreadState *tstate) { - PyThreadState *tstate = _PyRuntimeState_GetThreadState(runtime); - _Py_EnsureTstateNotNULL(tstate); + _PyRuntimeState *runtime = tstate->interp->runtime; +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + struct _gil_runtime_state *gil = &tstate->interp->ceval.gil; +#else struct _gil_runtime_state *gil = &runtime->ceval.gil; +#endif if (!gil_created(gil)) { - return; + return _PyStatus_OK(); } recreate_gil(gil); @@ -427,11 +498,12 @@ _PyEval_ReInitThreads(_PyRuntimeState *runtime) struct _pending_calls *pending = &tstate->interp->ceval.pending; if (_PyThread_at_fork_reinit(&pending->lock) < 0) { - Py_FatalError("Can't initialize threads for pending calls"); + return _PyStatus_ERR("Can't reinitialize pending calls lock"); } /* Destroy all threads except the current one */ _PyThreadState_DeleteExcept(runtime, tstate); + return _PyStatus_OK(); } #endif @@ -439,22 +511,30 @@ _PyEval_ReInitThreads(_PyRuntimeState *runtime) raised. */ void -_PyEval_SignalAsyncExc(PyThreadState *tstate) +_PyEval_SignalAsyncExc(PyInterpreterState *interp) { - assert(is_tstate_valid(tstate)); - SIGNAL_ASYNC_EXC(tstate->interp); + SIGNAL_ASYNC_EXC(interp); } PyThreadState * PyEval_SaveThread(void) { _PyRuntimeState *runtime = &_PyRuntime; +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + PyThreadState *old_tstate = _PyThreadState_GET(); + PyThreadState *tstate = _PyThreadState_Swap(&runtime->gilstate, old_tstate); +#else PyThreadState *tstate = _PyThreadState_Swap(&runtime->gilstate, NULL); +#endif _Py_EnsureTstateNotNULL(tstate); struct _ceval_runtime_state *ceval = &runtime->ceval; struct _ceval_state *ceval2 = &tstate->interp->ceval; +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + assert(gil_created(&ceval2->gil)); +#else assert(gil_created(&ceval->gil)); +#endif drop_gil(ceval, ceval2, tstate); return tstate; } @@ -618,10 +698,8 @@ handle_signals(PyThreadState *tstate) } static int -make_pending_calls(PyThreadState *tstate) +make_pending_calls(PyInterpreterState *interp) { - assert(is_tstate_valid(tstate)); - /* only execute pending calls on main thread */ if (!_Py_ThreadCanHandlePendingCalls()) { return 0; @@ -636,11 +714,11 @@ make_pending_calls(PyThreadState *tstate) /* unsignal before starting to call callbacks, so that any callback added in-between re-signals */ - UNSIGNAL_PENDING_CALLS(tstate->interp); + UNSIGNAL_PENDING_CALLS(interp); int res = 0; /* perform a bounded number of calls, in case of recursion */ - struct _pending_calls *pending = &tstate->interp->ceval.pending; + struct _pending_calls *pending = &interp->ceval.pending; for (int i=0; i<NPENDINGCALLS; i++) { int (*func)(void *) = NULL; void *arg = NULL; @@ -665,7 +743,7 @@ make_pending_calls(PyThreadState *tstate) error: busy = 0; - SIGNAL_PENDING_CALLS(tstate->interp); + SIGNAL_PENDING_CALLS(interp); return res; } @@ -673,6 +751,7 @@ void _Py_FinishPendingCalls(PyThreadState *tstate) { assert(PyGILState_Check()); + assert(is_tstate_valid(tstate)); struct _pending_calls *pending = &tstate->interp->ceval.pending; @@ -680,7 +759,7 @@ _Py_FinishPendingCalls(PyThreadState *tstate) return; } - if (make_pending_calls(tstate) < 0) { + if (make_pending_calls(tstate->interp) < 0) { PyObject *exc, *val, *tb; _PyErr_Fetch(tstate, &exc, &val, &tb); PyErr_BadInternalCall(); @@ -697,6 +776,7 @@ Py_MakePendingCalls(void) assert(PyGILState_Check()); PyThreadState *tstate = _PyThreadState_GET(); + assert(is_tstate_valid(tstate)); /* Python signal handler doesn't really queue a callback: it only signals that a signal was received, see _PyEval_SignalReceived(). */ @@ -705,7 +785,7 @@ Py_MakePendingCalls(void) return res; } - res = make_pending_calls(tstate); + res = make_pending_calls(tstate->interp); if (res != 0) { return res; } @@ -716,16 +796,15 @@ Py_MakePendingCalls(void) /* The interpreter's recursion limit */ #ifndef Py_DEFAULT_RECURSION_LIMIT -#define Py_DEFAULT_RECURSION_LIMIT 1000 +# define Py_DEFAULT_RECURSION_LIMIT 1000 #endif -int _Py_CheckRecursionLimit = Py_DEFAULT_RECURSION_LIMIT; - void _PyEval_InitRuntimeState(struct _ceval_runtime_state *ceval) { - _Py_CheckRecursionLimit = Py_DEFAULT_RECURSION_LIMIT; +#ifndef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS _gil_initialize(&ceval->gil); +#endif } int @@ -741,6 +820,10 @@ _PyEval_InitState(struct _ceval_state *ceval) return -1; } +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + _gil_initialize(&ceval->gil); +#endif + return 0; } @@ -757,8 +840,8 @@ _PyEval_FiniState(struct _ceval_state *ceval) int Py_GetRecursionLimit(void) { - PyThreadState *tstate = _PyThreadState_GET(); - return tstate->interp->ceval.recursion_limit; + PyInterpreterState *interp = _PyInterpreterState_GET(); + return interp->ceval.recursion_limit; } void @@ -766,14 +849,11 @@ Py_SetRecursionLimit(int new_limit) { PyThreadState *tstate = _PyThreadState_GET(); tstate->interp->ceval.recursion_limit = new_limit; - if (_Py_IsMainInterpreter(tstate)) { - _Py_CheckRecursionLimit = new_limit; - } } /* The function _Py_EnterRecursiveCall() only calls _Py_CheckRecursiveCall() - if the recursion_depth reaches _Py_CheckRecursionLimit. - If USE_STACKCHECK, the macro decrements _Py_CheckRecursionLimit + if the recursion_depth reaches recursion_limit. + If USE_STACKCHECK, the macro decrements recursion_limit to guarantee that _Py_CheckRecursiveCall() is regularly called. Without USE_STACKCHECK, there is no need for this. */ int @@ -788,27 +868,20 @@ _Py_CheckRecursiveCall(PyThreadState *tstate, const char *where) _PyErr_SetString(tstate, PyExc_MemoryError, "Stack overflow"); return -1; } - if (_Py_IsMainInterpreter(tstate)) { - /* Needed for ABI backwards-compatibility (see bpo-31857) */ - _Py_CheckRecursionLimit = recursion_limit; - } #endif - if (tstate->recursion_critical) - /* Somebody asked that we don't check for recursion. */ - return 0; - if (tstate->overflowed) { - if (tstate->recursion_depth > recursion_limit + 50 || tstate->overflowed > 50) { + if (tstate->recursion_headroom) { + if (tstate->recursion_depth > recursion_limit + 50) { /* Overflowing while handling an overflow. Give up. */ Py_FatalError("Cannot recover from stack overflow."); } } else { if (tstate->recursion_depth > recursion_limit) { - tstate->overflowed++; + tstate->recursion_headroom++; _PyErr_Format(tstate, PyExc_RecursionError, "maximum recursion depth exceeded%s", where); - tstate->overflowed--; + tstate->recursion_headroom--; --tstate->recursion_depth; return -1; } @@ -816,21 +889,249 @@ _Py_CheckRecursiveCall(PyThreadState *tstate, const char *where) return 0; } + +// PEP 634: Structural Pattern Matching + + +// Return a tuple of values corresponding to keys, with error checks for +// duplicate/missing keys. +static PyObject* +match_keys(PyThreadState *tstate, PyObject *map, PyObject *keys) +{ + assert(PyTuple_CheckExact(keys)); + Py_ssize_t nkeys = PyTuple_GET_SIZE(keys); + if (!nkeys) { + // No keys means no items. + return PyTuple_New(0); + } + PyObject *seen = NULL; + PyObject *dummy = NULL; + PyObject *values = NULL; + // We use the two argument form of map.get(key, default) for two reasons: + // - Atomically check for a key and get its value without error handling. + // - Don't cause key creation or resizing in dict subclasses like + // collections.defaultdict that define __missing__ (or similar). + _Py_IDENTIFIER(get); + PyObject *get = _PyObject_GetAttrId(map, &PyId_get); + if (get == NULL) { + goto fail; + } + seen = PySet_New(NULL); + if (seen == NULL) { + goto fail; + } + // dummy = object() + dummy = _PyObject_CallNoArg((PyObject *)&PyBaseObject_Type); + if (dummy == NULL) { + goto fail; + } + values = PyList_New(0); + if (values == NULL) { + goto fail; + } + for (Py_ssize_t i = 0; i < nkeys; i++) { + PyObject *key = PyTuple_GET_ITEM(keys, i); + if (PySet_Contains(seen, key) || PySet_Add(seen, key)) { + if (!_PyErr_Occurred(tstate)) { + // Seen it before! + _PyErr_Format(tstate, PyExc_ValueError, + "mapping pattern checks duplicate key (%R)", key); + } + goto fail; + } + PyObject *value = PyObject_CallFunctionObjArgs(get, key, dummy, NULL); + if (value == NULL) { + goto fail; + } + if (value == dummy) { + // key not in map! + Py_DECREF(value); + Py_DECREF(values); + // Return None: + Py_INCREF(Py_None); + values = Py_None; + goto done; + } + PyList_Append(values, value); + Py_DECREF(value); + } + Py_SETREF(values, PyList_AsTuple(values)); + // Success: +done: + Py_DECREF(get); + Py_DECREF(seen); + Py_DECREF(dummy); + return values; +fail: + Py_XDECREF(get); + Py_XDECREF(seen); + Py_XDECREF(dummy); + Py_XDECREF(values); + return NULL; +} + +// Extract a named attribute from the subject, with additional bookkeeping to +// raise TypeErrors for repeated lookups. On failure, return NULL (with no +// error set). Use _PyErr_Occurred(tstate) to disambiguate. +static PyObject* +match_class_attr(PyThreadState *tstate, PyObject *subject, PyObject *type, + PyObject *name, PyObject *seen) +{ + assert(PyUnicode_CheckExact(name)); + assert(PySet_CheckExact(seen)); + if (PySet_Contains(seen, name) || PySet_Add(seen, name)) { + if (!_PyErr_Occurred(tstate)) { + // Seen it before! + _PyErr_Format(tstate, PyExc_TypeError, + "%s() got multiple sub-patterns for attribute %R", + ((PyTypeObject*)type)->tp_name, name); + } + return NULL; + } + PyObject *attr = PyObject_GetAttr(subject, name); + if (attr == NULL && _PyErr_ExceptionMatches(tstate, PyExc_AttributeError)) { + _PyErr_Clear(tstate); + } + return attr; +} + +// On success (match), return a tuple of extracted attributes. On failure (no +// match), return NULL. Use _PyErr_Occurred(tstate) to disambiguate. +static PyObject* +match_class(PyThreadState *tstate, PyObject *subject, PyObject *type, + Py_ssize_t nargs, PyObject *kwargs) +{ + if (!PyType_Check(type)) { + const char *e = "called match pattern must be a type"; + _PyErr_Format(tstate, PyExc_TypeError, e); + return NULL; + } + assert(PyTuple_CheckExact(kwargs)); + // First, an isinstance check: + if (PyObject_IsInstance(subject, type) <= 0) { + return NULL; + } + // So far so good: + PyObject *seen = PySet_New(NULL); + if (seen == NULL) { + return NULL; + } + PyObject *attrs = PyList_New(0); + if (attrs == NULL) { + Py_DECREF(seen); + return NULL; + } + // NOTE: From this point on, goto fail on failure: + PyObject *match_args = NULL; + // First, the positional subpatterns: + if (nargs) { + int match_self = 0; + match_args = PyObject_GetAttrString(type, "__match_args__"); + if (match_args) { + if (!PyTuple_CheckExact(match_args)) { + const char *e = "%s.__match_args__ must be a tuple (got %s)"; + _PyErr_Format(tstate, PyExc_TypeError, e, + ((PyTypeObject *)type)->tp_name, + Py_TYPE(match_args)->tp_name); + goto fail; + } + } + else if (_PyErr_ExceptionMatches(tstate, PyExc_AttributeError)) { + _PyErr_Clear(tstate); + // _Py_TPFLAGS_MATCH_SELF is only acknowledged if the type does not + // define __match_args__. This is natural behavior for subclasses: + // it's as if __match_args__ is some "magic" value that is lost as + // soon as they redefine it. + match_args = PyTuple_New(0); + match_self = PyType_HasFeature((PyTypeObject*)type, + _Py_TPFLAGS_MATCH_SELF); + } + else { + goto fail; + } + assert(PyTuple_CheckExact(match_args)); + Py_ssize_t allowed = match_self ? 1 : PyTuple_GET_SIZE(match_args); + if (allowed < nargs) { + const char *plural = (allowed == 1) ? "" : "s"; + _PyErr_Format(tstate, PyExc_TypeError, + "%s() accepts %d positional sub-pattern%s (%d given)", + ((PyTypeObject*)type)->tp_name, + allowed, plural, nargs); + goto fail; + } + if (match_self) { + // Easy. Copy the subject itself, and move on to kwargs. + PyList_Append(attrs, subject); + } + else { + for (Py_ssize_t i = 0; i < nargs; i++) { + PyObject *name = PyTuple_GET_ITEM(match_args, i); + if (!PyUnicode_CheckExact(name)) { + _PyErr_Format(tstate, PyExc_TypeError, + "__match_args__ elements must be strings " + "(got %s)", Py_TYPE(name)->tp_name); + goto fail; + } + PyObject *attr = match_class_attr(tstate, subject, type, name, + seen); + if (attr == NULL) { + goto fail; + } + PyList_Append(attrs, attr); + Py_DECREF(attr); + } + } + Py_CLEAR(match_args); + } + // Finally, the keyword subpatterns: + for (Py_ssize_t i = 0; i < PyTuple_GET_SIZE(kwargs); i++) { + PyObject *name = PyTuple_GET_ITEM(kwargs, i); + PyObject *attr = match_class_attr(tstate, subject, type, name, seen); + if (attr == NULL) { + goto fail; + } + PyList_Append(attrs, attr); + Py_DECREF(attr); + } + Py_SETREF(attrs, PyList_AsTuple(attrs)); + Py_DECREF(seen); + return attrs; +fail: + // We really don't care whether an error was raised or not... that's our + // caller's problem. All we know is that the match failed. + Py_XDECREF(match_args); + Py_DECREF(seen); + Py_DECREF(attrs); + return NULL; +} + + static int do_raise(PyThreadState *tstate, PyObject *exc, PyObject *cause); static int unpack_iterable(PyThreadState *, PyObject *, int, int, PyObject **); -#define _Py_TracingPossible(ceval) ((ceval)->tracing_possible) - PyObject * PyEval_EvalCode(PyObject *co, PyObject *globals, PyObject *locals) { - return PyEval_EvalCodeEx(co, - globals, locals, - (PyObject **)NULL, 0, - (PyObject **)NULL, 0, - (PyObject **)NULL, 0, - NULL, NULL); + PyThreadState *tstate = PyThreadState_GET(); + if (locals == NULL) { + locals = globals; + } + PyObject *builtins = _PyEval_BuiltinsFromGlobals(tstate, globals); // borrowed ref + if (builtins == NULL) { + return NULL; + } + PyFrameConstructor desc = { + .fc_globals = globals, + .fc_builtins = builtins, + .fc_name = ((PyCodeObject *)co)->co_name, + .fc_qualname = ((PyCodeObject *)co)->co_name, + .fc_code = co, + .fc_defaults = NULL, + .fc_kwdefaults = NULL, + .fc_closure = NULL + }; + return _PyEval_Vector(tstate, &desc, locals, NULL, 0, NULL); } @@ -870,7 +1171,7 @@ eval_frame_handle_pending(PyThreadState *tstate) /* Pending calls */ struct _ceval_state *ceval2 = &tstate->interp->ceval; if (_Py_atomic_load_relaxed(&ceval2->pending.calls_to_do)) { - if (make_pending_calls(tstate) != 0) { + if (make_pending_calls(tstate->interp) != 0) { return -1; } } @@ -887,9 +1188,13 @@ eval_frame_handle_pending(PyThreadState *tstate) take_gil(tstate); +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + (void)_PyThreadState_Swap(&runtime->gilstate, tstate); +#else if (_PyThreadState_Swap(&runtime->gilstate, tstate) != NULL) { Py_FatalError("orphan tstate"); } +#endif } /* Check for asynchronous exception. */ @@ -916,41 +1221,6 @@ eval_frame_handle_pending(PyThreadState *tstate) return 0; } -PyObject* _Py_HOT_FUNCTION -_PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) -{ - _Py_EnsureTstateNotNULL(tstate); - -#ifdef DXPAIRS - int lastopcode = 0; -#endif - PyObject **stack_pointer; /* Next free slot in value stack */ - const _Py_CODEUNIT *next_instr; - int opcode; /* Current opcode */ - int oparg; /* Current opcode argument, if any */ - PyObject **fastlocals, **freevars; - PyObject *retval = NULL; /* Return value */ - struct _ceval_state * const ceval2 = &tstate->interp->ceval; - _Py_atomic_int * const eval_breaker = &ceval2->eval_breaker; - PyCodeObject *co; - - /* when tracing we set things up so that - - not (instr_lb <= current_bytecode_offset < instr_ub) - - is true when the line being executed has changed. The - initial values are such as to make this false the first - time it is tested. */ - int instr_ub = -1, instr_lb = 0, instr_prev = -1; - - const _Py_CODEUNIT *first_instr; - PyObject *names; - PyObject *consts; - _PyOpcache *co_opcache; - -#ifdef LLTRACE - _Py_IDENTIFIER(__ltrace__); -#endif /* Computed GOTOs, or the-optimization-commonly-but-improperly-known-as-"threaded code" @@ -991,6 +1261,23 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) -fno-crossjumping). */ +/* Use macros rather than inline functions, to make it as clear as possible + * to the C compiler that the tracing check is a simple test then branch. + * We want to be sure that the compiler knows this before it generates + * the CFG. + */ +#ifdef LLTRACE +#define OR_LLTRACE || lltrace +#else +#define OR_LLTRACE +#endif + +#ifdef WITH_DTRACE +#define OR_DTRACE_LINE || PyDTrace_LINE_ENABLED() +#else +#define OR_DTRACE_LINE +#endif + #ifdef DYNAMIC_EXECUTION_PROFILE #undef USE_COMPUTED_GOTOS #define USE_COMPUTED_GOTOS 0 @@ -1009,49 +1296,27 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) #endif #if USE_COMPUTED_GOTOS -/* Import the static jump table */ -#include "opcode_targets.h" - -#define TARGET(op) \ - op: \ - TARGET_##op - -#ifdef LLTRACE -#define FAST_DISPATCH() \ +#define TARGET(op) op: TARGET_##op +#define DISPATCH() \ { \ - if (!lltrace && !_Py_TracingPossible(ceval2) && !PyDTrace_LINE_ENABLED()) { \ - f->f_lasti = INSTR_OFFSET(); \ - NEXTOPARG(); \ - goto *opcode_targets[opcode]; \ + if (trace_info.cframe.use_tracing OR_DTRACE_LINE OR_LLTRACE) { \ + goto tracing_dispatch; \ } \ - goto fast_next_opcode; \ + f->f_lasti = INSTR_OFFSET(); \ + NEXTOPARG(); \ + goto *opcode_targets[opcode]; \ } #else -#define FAST_DISPATCH() \ - { \ - if (!_Py_TracingPossible(ceval2) && !PyDTrace_LINE_ENABLED()) { \ - f->f_lasti = INSTR_OFFSET(); \ - NEXTOPARG(); \ - goto *opcode_targets[opcode]; \ - } \ - goto fast_next_opcode; \ - } +#define TARGET(op) op +#define DISPATCH() goto predispatch; #endif -#define DISPATCH() \ - { \ - if (!_Py_atomic_load_relaxed(eval_breaker)) { \ - FAST_DISPATCH(); \ - } \ + +#define CHECK_EVAL_BREAKER() \ + if (_Py_atomic_load_relaxed(eval_breaker)) { \ continue; \ } -#else -#define TARGET(op) op -#define FAST_DISPATCH() goto fast_next_opcode -#define DISPATCH() continue -#endif - /* Tuple access macros */ @@ -1064,16 +1329,15 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) /* Code access macros */ /* The integer overflow is checked by an assertion below. */ -#define INSTR_OFFSET() \ - (sizeof(_Py_CODEUNIT) * (int)(next_instr - first_instr)) +#define INSTR_OFFSET() ((int)(next_instr - first_instr)) #define NEXTOPARG() do { \ _Py_CODEUNIT word = *next_instr; \ opcode = _Py_OPCODE(word); \ oparg = _Py_OPARG(word); \ next_instr++; \ } while (0) -#define JUMPTO(x) (next_instr = first_instr + (x) / sizeof(_Py_CODEUNIT)) -#define JUMPBY(x) (next_instr += (x) / sizeof(_Py_CODEUNIT)) +#define JUMPTO(x) (next_instr = first_instr + (x)) +#define JUMPBY(x) (next_instr += (x)) /* OpCode prediction macros Some opcodes tend to come in pairs thus making it possible to @@ -1135,7 +1399,6 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) #define SET_SECOND(v) (stack_pointer[-2] = (v)) #define SET_THIRD(v) (stack_pointer[-3] = (v)) #define SET_FOURTH(v) (stack_pointer[-4] = (v)) -#define SET_VALUE(n, v) (stack_pointer[-(n)] = (v)) #define BASIC_STACKADJ(n) (stack_pointer += n) #define BASIC_PUSH(v) (*stack_pointer++ = (v)) #define BASIC_POP() (*--stack_pointer) @@ -1216,16 +1479,43 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) do { \ co_opcache = NULL; \ if (co->co_opcache != NULL) { \ - unsigned char co_opt_offset = \ + unsigned char co_opcache_offset = \ co->co_opcache_map[next_instr - first_instr]; \ - if (co_opt_offset > 0) { \ - assert(co_opt_offset <= co->co_opcache_size); \ - co_opcache = &co->co_opcache[co_opt_offset - 1]; \ + if (co_opcache_offset > 0) { \ + assert(co_opcache_offset <= co->co_opcache_size); \ + co_opcache = &co->co_opcache[co_opcache_offset - 1]; \ assert(co_opcache != NULL); \ } \ } \ } while (0) +#define OPCACHE_DEOPT() \ + do { \ + if (co_opcache != NULL) { \ + co_opcache->optimized = -1; \ + unsigned char co_opcache_offset = \ + co->co_opcache_map[next_instr - first_instr]; \ + assert(co_opcache_offset <= co->co_opcache_size); \ + co->co_opcache_map[co_opcache_offset] = 0; \ + co_opcache = NULL; \ + } \ + } while (0) + +#define OPCACHE_DEOPT_LOAD_ATTR() \ + do { \ + if (co_opcache != NULL) { \ + OPCACHE_STAT_ATTR_DEOPT(); \ + OPCACHE_DEOPT(); \ + } \ + } while (0) + +#define OPCACHE_MAYBE_DEOPT_LOAD_ATTR() \ + do { \ + if (co_opcache != NULL && --co_opcache->optimized <= 0) { \ + OPCACHE_DEOPT_LOAD_ATTR(); \ + } \ + } while (0) + #if OPCACHE_STATS #define OPCACHE_STAT_GLOBAL_HIT() \ @@ -1243,24 +1533,99 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) if (co->co_opcache != NULL) opcache_global_opts++; \ } while (0) +#define OPCACHE_STAT_ATTR_HIT() \ + do { \ + if (co->co_opcache != NULL) opcache_attr_hits++; \ + } while (0) + +#define OPCACHE_STAT_ATTR_MISS() \ + do { \ + if (co->co_opcache != NULL) opcache_attr_misses++; \ + } while (0) + +#define OPCACHE_STAT_ATTR_OPT() \ + do { \ + if (co->co_opcache!= NULL) opcache_attr_opts++; \ + } while (0) + +#define OPCACHE_STAT_ATTR_DEOPT() \ + do { \ + if (co->co_opcache != NULL) opcache_attr_deopts++; \ + } while (0) + +#define OPCACHE_STAT_ATTR_TOTAL() \ + do { \ + if (co->co_opcache != NULL) opcache_attr_total++; \ + } while (0) + #else /* OPCACHE_STATS */ #define OPCACHE_STAT_GLOBAL_HIT() #define OPCACHE_STAT_GLOBAL_MISS() #define OPCACHE_STAT_GLOBAL_OPT() +#define OPCACHE_STAT_ATTR_HIT() +#define OPCACHE_STAT_ATTR_MISS() +#define OPCACHE_STAT_ATTR_OPT() +#define OPCACHE_STAT_ATTR_DEOPT() +#define OPCACHE_STAT_ATTR_TOTAL() + #endif -/* Start of code */ - /* push frame */ +PyObject* _Py_HOT_FUNCTION +_PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) +{ + _Py_EnsureTstateNotNULL(tstate); + +#if USE_COMPUTED_GOTOS +/* Import the static jump table */ +#include "opcode_targets.h" +#endif + +#ifdef DXPAIRS + int lastopcode = 0; +#endif + PyObject **stack_pointer; /* Next free slot in value stack */ + const _Py_CODEUNIT *next_instr; + int opcode; /* Current opcode */ + int oparg; /* Current opcode argument, if any */ + PyObject **fastlocals, **freevars; + PyObject *retval = NULL; /* Return value */ + _Py_atomic_int * const eval_breaker = &tstate->interp->ceval.eval_breaker; + PyCodeObject *co; + + const _Py_CODEUNIT *first_instr; + PyObject *names; + PyObject *consts; + _PyOpcache *co_opcache; + +#ifdef LLTRACE + _Py_IDENTIFIER(__ltrace__); +#endif + if (_Py_EnterRecursiveCall(tstate, "")) { return NULL; } + PyTraceInfo trace_info; + /* Mark trace_info as uninitialized */ + trace_info.code = NULL; + + /* WARNING: Because the CFrame lives on the C stack, + * but can be accessed from a heap allocated object (tstate) + * strict stack discipline must be maintained. + */ + CFrame *prev_cframe = tstate->cframe; + trace_info.cframe.use_tracing = prev_cframe->use_tracing; + trace_info.cframe.previous = prev_cframe; + tstate->cframe = &trace_info.cframe; + + /* push frame */ tstate->frame = f; + co = f->f_code; - if (tstate->use_tracing) { + if (trace_info.cframe.use_tracing) { if (tstate->c_tracefunc != NULL) { /* tstate->c_tracefunc, if defined, is a function that will be called on *every* entry @@ -1277,7 +1642,8 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) whenever an exception is detected. */ if (call_trace_protected(tstate->c_tracefunc, tstate->c_traceobj, - tstate, f, PyTrace_CALL, Py_None)) { + tstate, f, &trace_info, + PyTrace_CALL, Py_None)) { /* Trace function raised an error */ goto exit_eval_frame; } @@ -1287,7 +1653,8 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) return itself and isn't called for "line" events */ if (call_trace_protected(tstate->c_profilefunc, tstate->c_profileobj, - tstate, f, PyTrace_CALL, Py_None)) { + tstate, f, &trace_info, + PyTrace_CALL, Py_None)) { /* Profile function raised an error */ goto exit_eval_frame; } @@ -1297,7 +1664,6 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) if (PyDTrace_FUNCTION_ENTRY_ENABLED()) dtrace_function_entry(f); - co = f->f_code; names = co->co_names; consts = co->co_consts; fastlocals = f->f_localsplus; @@ -1323,19 +1689,20 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) to the beginning of the combined pair.) */ assert(f->f_lasti >= -1); - next_instr = first_instr; - if (f->f_lasti >= 0) { - assert(f->f_lasti % sizeof(_Py_CODEUNIT) == 0); - next_instr += f->f_lasti / sizeof(_Py_CODEUNIT) + 1; - } - stack_pointer = f->f_stacktop; - assert(stack_pointer != NULL); - f->f_stacktop = NULL; /* remains NULL unless yield suspends frame */ - f->f_executing = 1; + next_instr = first_instr + f->f_lasti + 1; + stack_pointer = f->f_valuestack + f->f_stackdepth; + /* Set f->f_stackdepth to -1. + * Update when returning or calling trace function. + Having f_stackdepth <= 0 ensures that invalid + values are not visible to the cycle GC. + We choose -1 rather than 0 to assist debugging. + */ + f->f_stackdepth = -1; + f->f_state = FRAME_EXECUTING; - if (co->co_opcache_flag < OPCACHE_MIN_RUNS) { + if (co->co_opcache_flag < opcache_min_runs) { co->co_opcache_flag++; - if (co->co_opcache_flag == OPCACHE_MIN_RUNS) { + if (co->co_opcache_flag == opcache_min_runs) { if (_PyCode_InitOpcache(co) < 0) { goto exit_eval_frame; } @@ -1349,11 +1716,18 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, PyFrameObject *f, int throwflag) } #ifdef LLTRACE - lltrace = _PyDict_GetItemId(f->f_globals, &PyId___ltrace__) != NULL; + { + int r = _PyDict_ContainsId(f->f_globals, &PyId___ltrace__); + if (r < 0) { + goto exit_eval_frame; + } + lltrace = r; + } #endif - if (throwflag) /* support for generator.throw() */ + if (throwflag) { /* support for generator.throw() */ goto error; + } #ifdef Py_DEBUG /* _PyEval_EvalFrameDefault() must not be called with an exception set, @@ -1378,10 +1752,10 @@ main_loop: if (_Py_atomic_load_relaxed(eval_breaker)) { opcode = _Py_OPCODE(*next_instr); - if (opcode == SETUP_FINALLY || - opcode == SETUP_WITH || - opcode == BEFORE_ASYNC_WITH || - opcode == YIELD_FROM) { + if (opcode != SETUP_FINALLY && + opcode != SETUP_WITH && + opcode != BEFORE_ASYNC_WITH && + opcode != YIELD_FROM) { /* Few cases where we skip running signal handlers and other pending calls: - If we're about to enter the 'with:'. It will prevent @@ -1398,55 +1772,45 @@ main_loop: running the signal handler and raising KeyboardInterrupt (see bpo-30039). */ - goto fast_next_opcode; - } - - if (eval_frame_handle_pending(tstate) != 0) { - goto error; - } + if (eval_frame_handle_pending(tstate) != 0) { + goto error; + } + } } - fast_next_opcode: + tracing_dispatch: + { + int instr_prev = f->f_lasti; f->f_lasti = INSTR_OFFSET(); + NEXTOPARG(); if (PyDTrace_LINE_ENABLED()) - maybe_dtrace_line(f, &instr_lb, &instr_ub, &instr_prev); + maybe_dtrace_line(f, &trace_info, instr_prev); /* line-by-line tracing support */ - if (_Py_TracingPossible(ceval2) && + if (trace_info.cframe.use_tracing && tstate->c_tracefunc != NULL && !tstate->tracing) { int err; - /* see maybe_call_line_trace + /* see maybe_call_line_trace() for expository comments */ - f->f_stacktop = stack_pointer; + f->f_stackdepth = (int)(stack_pointer - f->f_valuestack); err = maybe_call_line_trace(tstate->c_tracefunc, tstate->c_traceobj, tstate, f, - &instr_lb, &instr_ub, &instr_prev); + &trace_info, instr_prev); /* Reload possibly changed frame fields */ JUMPTO(f->f_lasti); - if (f->f_stacktop != NULL) { - stack_pointer = f->f_stacktop; - f->f_stacktop = NULL; - } - if (err) + stack_pointer = f->f_valuestack+f->f_stackdepth; + f->f_stackdepth = -1; + if (err) { /* trace function raised an exception */ goto error; + } + NEXTOPARG(); } - - /* Extract opcode and argument */ - - NEXTOPARG(); - dispatch_opcode: -#ifdef DYNAMIC_EXECUTION_PROFILE -#ifdef DXPAIRS - dxpairs[lastopcode][opcode]++; - lastopcode = opcode; -#endif - dxp[opcode]++; -#endif + } #ifdef LLTRACE /* Instruction tracing */ @@ -1462,15 +1826,33 @@ main_loop: } } #endif +#if USE_COMPUTED_GOTOS == 0 + goto dispatch_opcode; + + predispatch: + if (trace_info.cframe.use_tracing OR_DTRACE_LINE OR_LLTRACE) { + goto tracing_dispatch; + } + f->f_lasti = INSTR_OFFSET(); + NEXTOPARG(); +#endif + dispatch_opcode: +#ifdef DYNAMIC_EXECUTION_PROFILE +#ifdef DXPAIRS + dxpairs[lastopcode][opcode]++; + lastopcode = opcode; +#endif + dxp[opcode]++; +#endif switch (opcode) { /* BEWARE! It is essential that any operation that fails must goto error - and that all operation that succeed call [FAST_]DISPATCH() ! */ + and that all operation that succeed call DISPATCH() ! */ case TARGET(NOP): { - FAST_DISPATCH(); + DISPATCH(); } case TARGET(LOAD_FAST): { @@ -1483,7 +1865,7 @@ main_loop: } Py_INCREF(value); PUSH(value); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(LOAD_CONST): { @@ -1491,20 +1873,20 @@ main_loop: PyObject *value = GETITEM(consts, oparg); Py_INCREF(value); PUSH(value); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(STORE_FAST): { PREDICTED(STORE_FAST); PyObject *value = POP(); SETLOCAL(oparg, value); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(POP_TOP): { PyObject *value = POP(); Py_DECREF(value); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(ROT_TWO): { @@ -1512,7 +1894,7 @@ main_loop: PyObject *second = SECOND(); SET_TOP(second); SET_SECOND(top); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(ROT_THREE): { @@ -1522,7 +1904,7 @@ main_loop: SET_TOP(second); SET_SECOND(third); SET_THIRD(top); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(ROT_FOUR): { @@ -1534,14 +1916,14 @@ main_loop: SET_SECOND(third); SET_THIRD(fourth); SET_FOURTH(top); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(DUP_TOP): { PyObject *top = TOP(); Py_INCREF(top); PUSH(top); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(DUP_TOP_TWO): { @@ -1552,7 +1934,7 @@ main_loop: STACK_GROW(2); SET_TOP(top); SET_SECOND(second); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(UNARY_POSITIVE): { @@ -1687,7 +2069,7 @@ main_loop: PyObject *right = POP(); PyObject *left = TOP(); PyObject *sum; - /* NOTE(haypo): Please don't try to micro-optimize int+int on + /* NOTE(vstinner): Please don't try to micro-optimize int+int on CPython using bytecode, it is simply worthless. See http://bugs.python.org/issue21955 and http://bugs.python.org/issue10044 for the discussion. In short, @@ -2055,6 +2437,8 @@ main_loop: retval = POP(); assert(f->f_iblock == 0); assert(EMPTY()); + f->f_state = FRAME_RETURNED; + f->f_stackdepth = 0; goto exiting; } @@ -2197,34 +2581,52 @@ main_loop: case TARGET(YIELD_FROM): { PyObject *v = POP(); PyObject *receiver = TOP(); - int err; - if (PyGen_CheckExact(receiver) || PyCoro_CheckExact(receiver)) { - retval = _PyGen_Send((PyGenObject *)receiver, v); + PySendResult gen_status; + if (tstate->c_tracefunc == NULL) { + gen_status = PyIter_Send(receiver, v, &retval); } else { _Py_IDENTIFIER(send); - if (v == Py_None) + if (Py_IsNone(v) && PyIter_Check(receiver)) { retval = Py_TYPE(receiver)->tp_iternext(receiver); - else + } + else { retval = _PyObject_CallMethodIdOneArg(receiver, &PyId_send, v); + } + if (retval == NULL) { + if (tstate->c_tracefunc != NULL + && _PyErr_ExceptionMatches(tstate, PyExc_StopIteration)) + call_exc_trace(tstate->c_tracefunc, tstate->c_traceobj, tstate, f, &trace_info); + if (_PyGen_FetchStopIterationValue(&retval) == 0) { + gen_status = PYGEN_RETURN; + } + else { + gen_status = PYGEN_ERROR; + } + } + else { + gen_status = PYGEN_NEXT; + } } Py_DECREF(v); - if (retval == NULL) { - PyObject *val; - if (tstate->c_tracefunc != NULL - && _PyErr_ExceptionMatches(tstate, PyExc_StopIteration)) - call_exc_trace(tstate->c_tracefunc, tstate->c_traceobj, tstate, f); - err = _PyGen_FetchStopIterationValue(&val); - if (err < 0) - goto error; + if (gen_status == PYGEN_ERROR) { + assert (retval == NULL); + goto error; + } + if (gen_status == PYGEN_RETURN) { + assert (retval != NULL); + Py_DECREF(receiver); - SET_TOP(val); + SET_TOP(retval); + retval = NULL; DISPATCH(); } + assert (gen_status == PYGEN_NEXT); /* receiver remains on stack, retval is value to be yielded */ - f->f_stacktop = stack_pointer; /* and repeat... */ - assert(f->f_lasti >= (int)sizeof(_Py_CODEUNIT)); - f->f_lasti -= sizeof(_Py_CODEUNIT); + assert(f->f_lasti > 0); + f->f_lasti -= 1; + f->f_state = FRAME_SUSPENDED; + f->f_stackdepth = (int)(stack_pointer - f->f_valuestack); goto exiting; } @@ -2240,11 +2642,19 @@ main_loop: } retval = w; } - - f->f_stacktop = stack_pointer; + f->f_state = FRAME_SUSPENDED; + f->f_stackdepth = (int)(stack_pointer - f->f_valuestack); goto exiting; } + case TARGET(GEN_START): { + PyObject *none = POP(); + assert(none == Py_None); + assert(oparg < 3); + Py_DECREF(none); + DISPATCH(); + } + case TARGET(POP_EXCEPT): { PyObject *type, *value, *traceback; _PyErr_StackItem *exc_info; @@ -2270,12 +2680,15 @@ main_loop: } case TARGET(POP_BLOCK): { - PREDICTED(POP_BLOCK); PyFrame_BlockPop(f); DISPATCH(); } case TARGET(RERAISE): { + assert(f->f_iblock > 0); + if (oparg) { + f->f_lasti = f->f_blockstack[f->f_iblock-1].b_handler; + } PyObject *exc = POP(); PyObject *val = POP(); PyObject *tb = POP(); @@ -2294,7 +2707,7 @@ main_loop: UNWIND_EXCEPT_HANDLER(b); Py_DECREF(POP()); JUMPBY(oparg); - FAST_DISPATCH(); + DISPATCH(); } else { PyObject *val = POP(); @@ -2308,7 +2721,7 @@ main_loop: PyObject *value = PyExc_AssertionError; Py_INCREF(value); PUSH(value); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(LOAD_BUILD_CLASS): { @@ -2571,7 +2984,7 @@ main_loop: (PyDictObject *)f->f_builtins, name); if (v == NULL) { - if (!_PyErr_OCCURRED()) { + if (!_PyErr_Occurred(tstate)) { /* _PyDict_LoadGlobal() returns NULL without raising * an exception if the key doesn't exist */ format_exc_check_arg(tstate, PyExc_NameError, @@ -2993,7 +3406,190 @@ main_loop: case TARGET(LOAD_ATTR): { PyObject *name = GETITEM(names, oparg); PyObject *owner = TOP(); - PyObject *res = PyObject_GetAttr(owner, name); + + PyTypeObject *type = Py_TYPE(owner); + PyObject *res; + PyObject **dictptr; + PyObject *dict; + _PyOpCodeOpt_LoadAttr *la; + + OPCACHE_STAT_ATTR_TOTAL(); + + OPCACHE_CHECK(); + if (co_opcache != NULL && PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) + { + if (co_opcache->optimized > 0) { + // Fast path -- cache hit makes LOAD_ATTR ~30% faster. + la = &co_opcache->u.la; + if (la->type == type && la->tp_version_tag == type->tp_version_tag) + { + // Hint >= 0 is a dict index; hint == -1 is a dict miss. + // Hint < -1 is an inverted slot offset: offset is strictly > 0, + // so ~offset is strictly < -1 (assuming 2's complement). + if (la->hint < -1) { + // Even faster path -- slot hint. + Py_ssize_t offset = ~la->hint; + // fprintf(stderr, "Using hint for offset %zd\n", offset); + char *addr = (char *)owner + offset; + res = *(PyObject **)addr; + if (res != NULL) { + Py_INCREF(res); + SET_TOP(res); + Py_DECREF(owner); + DISPATCH(); + } + // Else slot is NULL. Fall through to slow path to raise AttributeError(name). + // Don't DEOPT, since the slot is still there. + } else { + // Fast path for dict. + assert(type->tp_dict != NULL); + assert(type->tp_dictoffset > 0); + + dictptr = (PyObject **) ((char *)owner + type->tp_dictoffset); + dict = *dictptr; + if (dict != NULL && PyDict_CheckExact(dict)) { + Py_ssize_t hint = la->hint; + Py_INCREF(dict); + res = NULL; + assert(!_PyErr_Occurred(tstate)); + la->hint = _PyDict_GetItemHint((PyDictObject*)dict, name, hint, &res); + if (res != NULL) { + assert(la->hint >= 0); + if (la->hint == hint && hint >= 0) { + // Our hint has helped -- cache hit. + OPCACHE_STAT_ATTR_HIT(); + } else { + // The hint we provided didn't work. + // Maybe next time? + OPCACHE_MAYBE_DEOPT_LOAD_ATTR(); + } + + Py_INCREF(res); + SET_TOP(res); + Py_DECREF(owner); + Py_DECREF(dict); + DISPATCH(); + } + else { + _PyErr_Clear(tstate); + // This attribute can be missing sometimes; + // we don't want to optimize this lookup. + OPCACHE_DEOPT_LOAD_ATTR(); + Py_DECREF(dict); + } + } + else { + // There is no dict, or __dict__ doesn't satisfy PyDict_CheckExact. + OPCACHE_DEOPT_LOAD_ATTR(); + } + } + } + else { + // The type of the object has either been updated, + // or is different. Maybe it will stabilize? + OPCACHE_MAYBE_DEOPT_LOAD_ATTR(); + } + OPCACHE_STAT_ATTR_MISS(); + } + + if (co_opcache != NULL && // co_opcache can be NULL after a DEOPT() call. + type->tp_getattro == PyObject_GenericGetAttr) + { + if (type->tp_dict == NULL) { + if (PyType_Ready(type) < 0) { + Py_DECREF(owner); + SET_TOP(NULL); + goto error; + } + } + PyObject *descr = _PyType_Lookup(type, name); + if (descr != NULL) { + // We found an attribute with a data-like descriptor. + PyTypeObject *dtype = Py_TYPE(descr); + if (dtype == &PyMemberDescr_Type) { // It's a slot + PyMemberDescrObject *member = (PyMemberDescrObject *)descr; + struct PyMemberDef *dmem = member->d_member; + if (dmem->type == T_OBJECT_EX) { + Py_ssize_t offset = dmem->offset; + assert(offset > 0); // 0 would be confused with dict hint == -1 (miss). + + if (co_opcache->optimized == 0) { + // First time we optimize this opcode. + OPCACHE_STAT_ATTR_OPT(); + co_opcache->optimized = OPCODE_CACHE_MAX_TRIES; + // fprintf(stderr, "Setting hint for %s, offset %zd\n", dmem->name, offset); + } + + la = &co_opcache->u.la; + la->type = type; + la->tp_version_tag = type->tp_version_tag; + la->hint = ~offset; + + char *addr = (char *)owner + offset; + res = *(PyObject **)addr; + if (res != NULL) { + Py_INCREF(res); + Py_DECREF(owner); + SET_TOP(res); + + DISPATCH(); + } + // Else slot is NULL. Fall through to slow path to raise AttributeError(name). + } + // Else it's a slot of a different type. We don't handle those. + } + // Else it's some other kind of descriptor that we don't handle. + OPCACHE_DEOPT_LOAD_ATTR(); + } + else if (type->tp_dictoffset > 0) { + // We found an instance with a __dict__. + dictptr = (PyObject **) ((char *)owner + type->tp_dictoffset); + dict = *dictptr; + + if (dict != NULL && PyDict_CheckExact(dict)) { + Py_INCREF(dict); + res = NULL; + assert(!_PyErr_Occurred(tstate)); + Py_ssize_t hint = _PyDict_GetItemHint((PyDictObject*)dict, name, -1, &res); + if (res != NULL) { + Py_INCREF(res); + Py_DECREF(dict); + Py_DECREF(owner); + SET_TOP(res); + + if (co_opcache->optimized == 0) { + // First time we optimize this opcode. + OPCACHE_STAT_ATTR_OPT(); + co_opcache->optimized = OPCODE_CACHE_MAX_TRIES; + } + + la = &co_opcache->u.la; + la->type = type; + la->tp_version_tag = type->tp_version_tag; + assert(hint >= 0); + la->hint = hint; + + DISPATCH(); + } + else { + _PyErr_Clear(tstate); + } + Py_DECREF(dict); + } else { + // There is no dict, or __dict__ doesn't satisfy PyDict_CheckExact. + OPCACHE_DEOPT_LOAD_ATTR(); + } + } else { + // The object's class does not have a tp_dictoffset we can use. + OPCACHE_DEOPT_LOAD_ATTR(); + } + } else if (type->tp_getattro != PyObject_GenericGetAttr) { + OPCACHE_DEOPT_LOAD_ATTR(); + } + } + + // Slow path. + res = PyObject_GetAttr(owner, name); Py_DECREF(owner); SET_TOP(res); if (res == NULL) @@ -3019,7 +3615,7 @@ main_loop: case TARGET(IS_OP): { PyObject *right = POP(); PyObject *left = TOP(); - int res = (left == right)^oparg; + int res = Py_Is(left, right) ^ oparg; PyObject *b = res ? Py_True : Py_False; Py_INCREF(b); SET_TOP(b); @@ -3027,7 +3623,7 @@ main_loop: Py_DECREF(right); PREDICT(POP_JUMP_IF_FALSE); PREDICT(POP_JUMP_IF_TRUE); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(CONTAINS_OP): { @@ -3044,7 +3640,7 @@ main_loop: PUSH(b); PREDICT(POP_JUMP_IF_FALSE); PREDICT(POP_JUMP_IF_TRUE); - FAST_DISPATCH(); + DISPATCH(); } #define CANNOT_CATCH_MSG "catching classes that do not inherit from "\ @@ -3141,28 +3737,31 @@ main_loop: case TARGET(JUMP_FORWARD): { JUMPBY(oparg); - FAST_DISPATCH(); + DISPATCH(); } case TARGET(POP_JUMP_IF_FALSE): { PREDICTED(POP_JUMP_IF_FALSE); PyObject *cond = POP(); int err; - if (cond == Py_True) { + if (Py_IsTrue(cond)) { Py_DECREF(cond); - FAST_DISPATCH(); + DISPATCH(); } - if (cond == Py_False) { + if (Py_IsFalse(cond)) { Py_DECREF(cond); JUMPTO(oparg); - FAST_DISPATCH(); + CHECK_EVAL_BREAKER(); + DISPATCH(); } err = PyObject_IsTrue(cond); Py_DECREF(cond); if (err > 0) ; - else if (err == 0) + else if (err == 0) { JUMPTO(oparg); + CHECK_EVAL_BREAKER(); + } else goto error; DISPATCH(); @@ -3172,19 +3771,21 @@ main_loop: PREDICTED(POP_JUMP_IF_TRUE); PyObject *cond = POP(); int err; - if (cond == Py_False) { + if (Py_IsFalse(cond)) { Py_DECREF(cond); - FAST_DISPATCH(); + DISPATCH(); } - if (cond == Py_True) { + if (Py_IsTrue(cond)) { Py_DECREF(cond); JUMPTO(oparg); - FAST_DISPATCH(); + CHECK_EVAL_BREAKER(); + DISPATCH(); } err = PyObject_IsTrue(cond); Py_DECREF(cond); if (err > 0) { JUMPTO(oparg); + CHECK_EVAL_BREAKER(); } else if (err == 0) ; @@ -3196,14 +3797,14 @@ main_loop: case TARGET(JUMP_IF_FALSE_OR_POP): { PyObject *cond = TOP(); int err; - if (cond == Py_True) { + if (Py_IsTrue(cond)) { STACK_SHRINK(1); Py_DECREF(cond); - FAST_DISPATCH(); + DISPATCH(); } - if (cond == Py_False) { + if (Py_IsFalse(cond)) { JUMPTO(oparg); - FAST_DISPATCH(); + DISPATCH(); } err = PyObject_IsTrue(cond); if (err > 0) { @@ -3220,14 +3821,14 @@ main_loop: case TARGET(JUMP_IF_TRUE_OR_POP): { PyObject *cond = TOP(); int err; - if (cond == Py_False) { + if (Py_IsFalse(cond)) { STACK_SHRINK(1); Py_DECREF(cond); - FAST_DISPATCH(); + DISPATCH(); } - if (cond == Py_True) { + if (Py_IsTrue(cond)) { JUMPTO(oparg); - FAST_DISPATCH(); + DISPATCH(); } err = PyObject_IsTrue(cond); if (err > 0) { @@ -3245,18 +3846,110 @@ main_loop: case TARGET(JUMP_ABSOLUTE): { PREDICTED(JUMP_ABSOLUTE); JUMPTO(oparg); -#if FAST_LOOPS - /* Enabling this path speeds-up all while and for-loops by bypassing - the per-loop checks for signals. By default, this should be turned-off - because it prevents detection of a control-break in tight loops like - "while 1: pass". Compile with this option turned-on when you need - the speed-up and do not need break checking inside tight loops (ones - that contain only instructions ending with FAST_DISPATCH). - */ - FAST_DISPATCH(); -#else + CHECK_EVAL_BREAKER(); + DISPATCH(); + } + + case TARGET(GET_LEN): { + // PUSH(len(TOS)) + Py_ssize_t len_i = PyObject_Length(TOP()); + if (len_i < 0) { + goto error; + } + PyObject *len_o = PyLong_FromSsize_t(len_i); + if (len_o == NULL) { + goto error; + } + PUSH(len_o); + DISPATCH(); + } + + case TARGET(MATCH_CLASS): { + // Pop TOS. On success, set TOS to True and TOS1 to a tuple of + // attributes. On failure, set TOS to False. + PyObject *names = POP(); + PyObject *type = TOP(); + PyObject *subject = SECOND(); + assert(PyTuple_CheckExact(names)); + PyObject *attrs = match_class(tstate, subject, type, oparg, names); + Py_DECREF(names); + if (attrs) { + // Success! + assert(PyTuple_CheckExact(attrs)); + Py_DECREF(subject); + SET_SECOND(attrs); + } + else if (_PyErr_Occurred(tstate)) { + goto error; + } + Py_DECREF(type); + SET_TOP(PyBool_FromLong(!!attrs)); + DISPATCH(); + } + + case TARGET(MATCH_MAPPING): { + PyObject *subject = TOP(); + int match = Py_TYPE(subject)->tp_flags & Py_TPFLAGS_MAPPING; + PyObject *res = match ? Py_True : Py_False; + Py_INCREF(res); + PUSH(res); + DISPATCH(); + } + + case TARGET(MATCH_SEQUENCE): { + PyObject *subject = TOP(); + int match = Py_TYPE(subject)->tp_flags & Py_TPFLAGS_SEQUENCE; + PyObject *res = match ? Py_True : Py_False; + Py_INCREF(res); + PUSH(res); + DISPATCH(); + } + + case TARGET(MATCH_KEYS): { + // On successful match for all keys, PUSH(values) and PUSH(True). + // Otherwise, PUSH(None) and PUSH(False). + PyObject *keys = TOP(); + PyObject *subject = SECOND(); + PyObject *values_or_none = match_keys(tstate, subject, keys); + if (values_or_none == NULL) { + goto error; + } + PUSH(values_or_none); + if (Py_IsNone(values_or_none)) { + Py_INCREF(Py_False); + PUSH(Py_False); + DISPATCH(); + } + assert(PyTuple_CheckExact(values_or_none)); + Py_INCREF(Py_True); + PUSH(Py_True); + DISPATCH(); + } + + case TARGET(COPY_DICT_WITHOUT_KEYS): { + // rest = dict(TOS1) + // for key in TOS: + // del rest[key] + // SET_TOP(rest) + PyObject *keys = TOP(); + PyObject *subject = SECOND(); + PyObject *rest = PyDict_New(); + if (rest == NULL || PyDict_Update(rest, subject)) { + Py_XDECREF(rest); + goto error; + } + // This may seem a bit inefficient, but keys is rarely big enough to + // actually impact runtime. + assert(PyTuple_CheckExact(keys)); + for (Py_ssize_t i = 0; i < PyTuple_GET_SIZE(keys); i++) { + if (PyDict_DelItem(rest, PyTuple_GET_ITEM(keys, i))) { + Py_DECREF(rest); + goto error; + } + } + Py_DECREF(keys); + SET_TOP(rest); DISPATCH(); -#endif } case TARGET(GET_ITER): { @@ -3317,7 +4010,7 @@ main_loop: goto error; } else if (tstate->c_tracefunc != NULL) { - call_exc_trace(tstate->c_tracefunc, tstate->c_traceobj, tstate, f); + call_exc_trace(tstate->c_tracefunc, tstate->c_traceobj, tstate, f, &trace_info); } _PyErr_Clear(tstate); } @@ -3325,7 +4018,6 @@ main_loop: STACK_SHRINK(1); Py_DECREF(iter); JUMPBY(oparg); - PREDICT(POP_BLOCK); DISPATCH(); } @@ -3414,7 +4106,7 @@ main_loop: exc = TOP(); val = SECOND(); tb = THIRD(); - assert(exc != Py_None); + assert(!Py_IsNone(exc)); assert(!PyLong_Check(exc)); exit_func = PEEK(7); PyObject *stack[4] = {NULL, exc, val, tb}; @@ -3486,7 +4178,7 @@ main_loop: `callable` will be POPed by call_function. NULL will will be POPed manually later. */ - res = call_function(tstate, &sp, oparg, NULL); + res = call_function(tstate, &trace_info, &sp, oparg, NULL); stack_pointer = sp; (void)POP(); /* POP the NULL. */ } @@ -3503,13 +4195,14 @@ main_loop: We'll be passing `oparg + 1` to call_function, to make it accept the `self` as a first argument. */ - res = call_function(tstate, &sp, oparg + 1, NULL); + res = call_function(tstate, &trace_info, &sp, oparg + 1, NULL); stack_pointer = sp; } PUSH(res); if (res == NULL) goto error; + CHECK_EVAL_BREAKER(); DISPATCH(); } @@ -3517,12 +4210,13 @@ main_loop: PREDICTED(CALL_FUNCTION); PyObject **sp, *res; sp = stack_pointer; - res = call_function(tstate, &sp, oparg, NULL); + res = call_function(tstate, &trace_info, &sp, oparg, NULL); stack_pointer = sp; PUSH(res); if (res == NULL) { goto error; } + CHECK_EVAL_BREAKER(); DISPATCH(); } @@ -3534,7 +4228,7 @@ main_loop: assert(PyTuple_GET_SIZE(names) <= oparg); /* We assume without checking that names contains only strings */ sp = stack_pointer; - res = call_function(tstate, &sp, oparg, names); + res = call_function(tstate, &trace_info, &sp, oparg, names); stack_pointer = sp; PUSH(res); Py_DECREF(names); @@ -3542,6 +4236,7 @@ main_loop: if (res == NULL) { goto error; } + CHECK_EVAL_BREAKER(); DISPATCH(); } @@ -3579,7 +4274,7 @@ main_loop: } assert(PyTuple_CheckExact(callargs)); - result = do_call_core(tstate, func, callargs, kwargs); + result = do_call_core(tstate, &trace_info, func, callargs, kwargs); Py_DECREF(func); Py_DECREF(callargs); Py_XDECREF(kwargs); @@ -3588,6 +4283,7 @@ main_loop: if (result == NULL) { goto error; } + CHECK_EVAL_BREAKER(); DISPATCH(); } @@ -3605,10 +4301,10 @@ main_loop: if (oparg & 0x08) { assert(PyTuple_CheckExact(TOP())); - func ->func_closure = POP(); + func->func_closure = POP(); } if (oparg & 0x04) { - assert(PyDict_CheckExact(TOP())); + assert(PyTuple_CheckExact(TOP())); func->func_annotations = POP(); } if (oparg & 0x02) { @@ -3702,6 +4398,14 @@ main_loop: DISPATCH(); } + case TARGET(ROT_N): { + PyObject *top = TOP(); + memmove(&PEEK(oparg - 1), &PEEK(oparg), + sizeof(PyObject*) * (oparg - 1)); + PEEK(oparg) = top; + DISPATCH(); + } + case TARGET(EXTENDED_ARG): { int oldoparg = oparg; NEXTOPARG(); @@ -3741,11 +4445,15 @@ error: /* Log traceback info. */ PyTraceBack_Here(f); - if (tstate->c_tracefunc != NULL) + if (tstate->c_tracefunc != NULL) { + /* Make sure state is set to FRAME_EXECUTING for tracing */ + assert(f->f_state == FRAME_EXECUTING); + f->f_state = FRAME_UNWINDING; call_exc_trace(tstate->c_tracefunc, tstate->c_traceobj, - tstate, f); - + tstate, f, &trace_info); + } exception_unwind: + f->f_state = FRAME_UNWINDING; /* Unwind stacks if an exception occurred */ while (f->f_iblock > 0) { /* Pop the current block. */ @@ -3761,7 +4469,7 @@ exception_unwind: int handler = b->b_handler; _PyErr_StackItem *exc_info = tstate->exc_info; /* Beware, this invalidates all b->b_* fields */ - PyFrame_BlockSetup(f, EXCEPT_HANDLER, -1, STACK_LEVEL()); + PyFrame_BlockSetup(f, EXCEPT_HANDLER, f->f_lasti, STACK_LEVEL()); PUSH(exc_info->exc_traceback); PUSH(exc_info->exc_value); if (exc_info->exc_type != NULL) { @@ -3793,17 +4501,8 @@ exception_unwind: PUSH(val); PUSH(exc); JUMPTO(handler); - if (_Py_TracingPossible(ceval2)) { - int needs_new_execution_window = (f->f_lasti < instr_lb || f->f_lasti >= instr_ub); - int needs_line_update = (f->f_lasti == instr_lb || f->f_lasti < instr_prev); - /* Make sure that we trace line after exception if we are in a new execution - * window or we don't need a line update and we are not in the first instruction - * of the line. */ - if (needs_new_execution_window || (!needs_line_update && instr_lb > 0)) { - instr_prev = INT_MAX; - } - } /* Resume normal execution */ + f->f_state = FRAME_EXECUTING; goto main_loop; } } /* unwind stack */ @@ -3820,18 +4519,19 @@ exception_unwind: PyObject *o = POP(); Py_XDECREF(o); } - + f->f_stackdepth = 0; + f->f_state = FRAME_RAISED; exiting: - if (tstate->use_tracing) { + if (trace_info.cframe.use_tracing) { if (tstate->c_tracefunc) { if (call_trace_protected(tstate->c_tracefunc, tstate->c_traceobj, - tstate, f, PyTrace_RETURN, retval)) { + tstate, f, &trace_info, PyTrace_RETURN, retval)) { Py_CLEAR(retval); } } if (tstate->c_profilefunc) { if (call_trace_protected(tstate->c_profilefunc, tstate->c_profileobj, - tstate, f, PyTrace_RETURN, retval)) { + tstate, f, &trace_info, PyTrace_RETURN, retval)) { Py_CLEAR(retval); } } @@ -3839,10 +4539,13 @@ exiting: /* pop frame */ exit_eval_frame: + /* Restore previous cframe */ + tstate->cframe = trace_info.cframe.previous; + tstate->cframe->use_tracing = trace_info.cframe.use_tracing; + if (PyDTrace_FUNCTION_RETURN_ENABLED()) dtrace_function_return(f); _Py_LeaveRecursiveCall(tstate); - f->f_executing = 0; tstate->frame = f->f_back; return _Py_CheckFunctionResult(tstate, NULL, retval, __func__); @@ -3850,7 +4553,7 @@ exit_eval_frame: static void format_missing(PyThreadState *tstate, const char *kind, - PyCodeObject *co, PyObject *names) + PyCodeObject *co, PyObject *names, PyObject *qualname) { int err; Py_ssize_t len = PyList_GET_SIZE(names); @@ -3903,7 +4606,7 @@ format_missing(PyThreadState *tstate, const char *kind, return; _PyErr_Format(tstate, PyExc_TypeError, "%U() missing %i required %s argument%s: %U", - co->co_name, + qualname, len, kind, len == 1 ? "" : "s", @@ -3914,7 +4617,7 @@ format_missing(PyThreadState *tstate, const char *kind, static void missing_arguments(PyThreadState *tstate, PyCodeObject *co, Py_ssize_t missing, Py_ssize_t defcount, - PyObject **fastlocals) + PyObject **fastlocals, PyObject *qualname) { Py_ssize_t i, j = 0; Py_ssize_t start, end; @@ -3946,14 +4649,14 @@ missing_arguments(PyThreadState *tstate, PyCodeObject *co, } } assert(j == missing); - format_missing(tstate, kind, co, missing_names); + format_missing(tstate, kind, co, missing_names, qualname); Py_DECREF(missing_names); } static void too_many_positional(PyThreadState *tstate, PyCodeObject *co, - Py_ssize_t given, Py_ssize_t defcount, - PyObject **fastlocals) + Py_ssize_t given, PyObject *defaults, + PyObject **fastlocals, PyObject *qualname) { int plural; Py_ssize_t kwonly_given = 0; @@ -3968,6 +4671,7 @@ too_many_positional(PyThreadState *tstate, PyCodeObject *co, kwonly_given++; } } + Py_ssize_t defcount = defaults == NULL ? 0 : PyTuple_GET_SIZE(defaults); if (defcount) { Py_ssize_t atleast = co_argcount - defcount; plural = 1; @@ -3997,7 +4701,7 @@ too_many_positional(PyThreadState *tstate, PyCodeObject *co, } _PyErr_Format(tstate, PyExc_TypeError, "%U() takes %U positional argument%s but %zd%U %s given", - co->co_name, + qualname, sig, plural ? "s" : "", given, @@ -4009,7 +4713,8 @@ too_many_positional(PyThreadState *tstate, PyCodeObject *co, static int positional_only_passed_as_keyword(PyThreadState *tstate, PyCodeObject *co, - Py_ssize_t kwcount, PyObject* const* kwnames) + Py_ssize_t kwcount, PyObject* kwnames, + PyObject *qualname) { int posonly_conflicts = 0; PyObject* posonly_names = PyList_New(0); @@ -4019,7 +4724,7 @@ positional_only_passed_as_keyword(PyThreadState *tstate, PyCodeObject *co, for (int k2=0; k2<kwcount; k2++){ /* Compare the pointers first and fallback to PyObject_RichCompareBool*/ - PyObject* kwname = kwnames[k2]; + PyObject* kwname = PyTuple_GET_ITEM(kwnames, k2); if (kwname == posonly_name){ if(PyList_Append(posonly_names, kwname) != 0) { goto fail; @@ -4054,7 +4759,7 @@ positional_only_passed_as_keyword(PyThreadState *tstate, PyCodeObject *co, _PyErr_Format(tstate, PyExc_TypeError, "%U() got some positional-only arguments passed" " as keyword arguments: '%U'", - co->co_name, error_names); + qualname, error_names); Py_DECREF(error_names); goto fail; } @@ -4068,46 +4773,30 @@ fail: } -/* This is gonna seem *real weird*, but if you put some other code between - PyEval_EvalFrame() and _PyEval_EvalFrameDefault() you will need to adjust - the test in the if statements in Misc/gdbinit (pystack and pystackv). */ -PyObject * -_PyEval_EvalCode(PyThreadState *tstate, - PyObject *_co, PyObject *globals, PyObject *locals, +PyFrameObject * +_PyEval_MakeFrameVector(PyThreadState *tstate, + PyFrameConstructor *con, PyObject *locals, PyObject *const *args, Py_ssize_t argcount, - PyObject *const *kwnames, PyObject *const *kwargs, - Py_ssize_t kwcount, int kwstep, - PyObject *const *defs, Py_ssize_t defcount, - PyObject *kwdefs, PyObject *closure, - PyObject *name, PyObject *qualname) + PyObject *kwnames) { assert(is_tstate_valid(tstate)); - PyCodeObject* co = (PyCodeObject*)_co; - PyFrameObject *f; - PyObject *retval = NULL; - PyObject **fastlocals, **freevars; - PyObject *x, *u; + PyCodeObject *co = (PyCodeObject*)con->fc_code; + assert(con->fc_defaults == NULL || PyTuple_CheckExact(con->fc_defaults)); const Py_ssize_t total_args = co->co_argcount + co->co_kwonlyargcount; - Py_ssize_t i, j, n; - PyObject *kwdict; - - if (globals == NULL) { - _PyErr_SetString(tstate, PyExc_SystemError, - "PyEval_EvalCodeEx: NULL globals"); - return NULL; - } /* Create the frame */ - f = _PyFrame_New_NoTrack(tstate, co, globals, locals); + PyFrameObject *f = _PyFrame_New_NoTrack(tstate, con, locals); if (f == NULL) { return NULL; } - fastlocals = f->f_localsplus; - freevars = f->f_localsplus + co->co_nlocals; + PyObject **fastlocals = f->f_localsplus; + PyObject **freevars = f->f_localsplus + co->co_nlocals; /* Create a dictionary for keyword parameters (**kwags) */ + PyObject *kwdict; + Py_ssize_t i; if (co->co_flags & CO_VARKEYWORDS) { kwdict = PyDict_New(); if (kwdict == NULL) @@ -4123,6 +4812,7 @@ _PyEval_EvalCode(PyThreadState *tstate, } /* Copy all positional arguments into local variables */ + Py_ssize_t j, n; if (argcount > co->co_argcount) { n = co->co_argcount; } @@ -4130,97 +4820,102 @@ _PyEval_EvalCode(PyThreadState *tstate, n = argcount; } for (j = 0; j < n; j++) { - x = args[j]; + PyObject *x = args[j]; Py_INCREF(x); SETLOCAL(j, x); } /* Pack other positional arguments into the *args argument */ if (co->co_flags & CO_VARARGS) { - u = _PyTuple_FromArray(args + n, argcount - n); + PyObject *u = _PyTuple_FromArray(args + n, argcount - n); if (u == NULL) { goto fail; } SETLOCAL(total_args, u); } - /* Handle keyword arguments passed as two strided arrays */ - kwcount *= kwstep; - for (i = 0; i < kwcount; i += kwstep) { - PyObject **co_varnames; - PyObject *keyword = kwnames[i]; - PyObject *value = kwargs[i]; - Py_ssize_t j; + /* Handle keyword arguments */ + if (kwnames != NULL) { + Py_ssize_t kwcount = PyTuple_GET_SIZE(kwnames); + for (i = 0; i < kwcount; i++) { + PyObject **co_varnames; + PyObject *keyword = PyTuple_GET_ITEM(kwnames, i); + PyObject *value = args[i+argcount]; + Py_ssize_t j; - if (keyword == NULL || !PyUnicode_Check(keyword)) { - _PyErr_Format(tstate, PyExc_TypeError, - "%U() keywords must be strings", - co->co_name); - goto fail; - } - - /* Speed hack: do raw pointer compares. As names are - normally interned this should almost always hit. */ - co_varnames = ((PyTupleObject *)(co->co_varnames))->ob_item; - for (j = co->co_posonlyargcount; j < total_args; j++) { - PyObject *name = co_varnames[j]; - if (name == keyword) { - goto kw_found; + if (keyword == NULL || !PyUnicode_Check(keyword)) { + _PyErr_Format(tstate, PyExc_TypeError, + "%U() keywords must be strings", + con->fc_qualname); + goto fail; } - } - /* Slow fallback, just in case */ - for (j = co->co_posonlyargcount; j < total_args; j++) { - PyObject *name = co_varnames[j]; - int cmp = PyObject_RichCompareBool( keyword, name, Py_EQ); - if (cmp > 0) { - goto kw_found; + /* Speed hack: do raw pointer compares. As names are + normally interned this should almost always hit. */ + co_varnames = ((PyTupleObject *)(co->co_varnames))->ob_item; + for (j = co->co_posonlyargcount; j < total_args; j++) { + PyObject *varname = co_varnames[j]; + if (varname == keyword) { + goto kw_found; + } } - else if (cmp < 0) { - goto fail; + + /* Slow fallback, just in case */ + for (j = co->co_posonlyargcount; j < total_args; j++) { + PyObject *varname = co_varnames[j]; + int cmp = PyObject_RichCompareBool( keyword, varname, Py_EQ); + if (cmp > 0) { + goto kw_found; + } + else if (cmp < 0) { + goto fail; + } } - } - assert(j >= total_args); - if (kwdict == NULL) { + assert(j >= total_args); + if (kwdict == NULL) { - if (co->co_posonlyargcount - && positional_only_passed_as_keyword(tstate, co, - kwcount, kwnames)) - { + if (co->co_posonlyargcount + && positional_only_passed_as_keyword(tstate, co, + kwcount, kwnames, + con->fc_qualname)) + { + goto fail; + } + + _PyErr_Format(tstate, PyExc_TypeError, + "%U() got an unexpected keyword argument '%S'", + con->fc_qualname, keyword); goto fail; } - _PyErr_Format(tstate, PyExc_TypeError, - "%U() got an unexpected keyword argument '%S'", - co->co_name, keyword); - goto fail; - } - - if (PyDict_SetItem(kwdict, keyword, value) == -1) { - goto fail; - } - continue; + if (PyDict_SetItem(kwdict, keyword, value) == -1) { + goto fail; + } + continue; - kw_found: - if (GETLOCAL(j) != NULL) { - _PyErr_Format(tstate, PyExc_TypeError, - "%U() got multiple values for argument '%S'", - co->co_name, keyword); - goto fail; + kw_found: + if (GETLOCAL(j) != NULL) { + _PyErr_Format(tstate, PyExc_TypeError, + "%U() got multiple values for argument '%S'", + con->fc_qualname, keyword); + goto fail; + } + Py_INCREF(value); + SETLOCAL(j, value); } - Py_INCREF(value); - SETLOCAL(j, value); } /* Check the number of positional arguments */ if ((argcount > co->co_argcount) && !(co->co_flags & CO_VARARGS)) { - too_many_positional(tstate, co, argcount, defcount, fastlocals); + too_many_positional(tstate, co, argcount, con->fc_defaults, fastlocals, + con->fc_qualname); goto fail; } /* Add missing positional arguments (copy default values from defs) */ if (argcount < co->co_argcount) { + Py_ssize_t defcount = con->fc_defaults == NULL ? 0 : PyTuple_GET_SIZE(con->fc_defaults); Py_ssize_t m = co->co_argcount - defcount; Py_ssize_t missing = 0; for (i = argcount; i < m; i++) { @@ -4229,18 +4924,22 @@ _PyEval_EvalCode(PyThreadState *tstate, } } if (missing) { - missing_arguments(tstate, co, missing, defcount, fastlocals); + missing_arguments(tstate, co, missing, defcount, fastlocals, + con->fc_qualname); goto fail; } if (n > m) i = n - m; else i = 0; - for (; i < defcount; i++) { - if (GETLOCAL(m+i) == NULL) { - PyObject *def = defs[i]; - Py_INCREF(def); - SETLOCAL(m+i, def); + if (defcount) { + PyObject **defs = &PyTuple_GET_ITEM(con->fc_defaults, 0); + for (; i < defcount; i++) { + if (GETLOCAL(m+i) == NULL) { + PyObject *def = defs[i]; + Py_INCREF(def); + SETLOCAL(m+i, def); + } } } } @@ -4249,12 +4948,11 @@ _PyEval_EvalCode(PyThreadState *tstate, if (co->co_kwonlyargcount > 0) { Py_ssize_t missing = 0; for (i = co->co_argcount; i < total_args; i++) { - PyObject *name; if (GETLOCAL(i) != NULL) continue; - name = PyTuple_GET_ITEM(co->co_varnames, i); - if (kwdefs != NULL) { - PyObject *def = PyDict_GetItemWithError(kwdefs, name); + PyObject *varname = PyTuple_GET_ITEM(co->co_varnames, i); + if (con->fc_kwdefaults != NULL) { + PyObject *def = PyDict_GetItemWithError(con->fc_kwdefaults, varname); if (def) { Py_INCREF(def); SETLOCAL(i, def); @@ -4267,7 +4965,8 @@ _PyEval_EvalCode(PyThreadState *tstate, missing++; } if (missing) { - missing_arguments(tstate, co, missing, -1, fastlocals); + missing_arguments(tstate, co, missing, -1, fastlocals, + con->fc_qualname); goto fail; } } @@ -4294,41 +4993,76 @@ _PyEval_EvalCode(PyThreadState *tstate, /* Copy closure variables to free variables */ for (i = 0; i < PyTuple_GET_SIZE(co->co_freevars); ++i) { - PyObject *o = PyTuple_GET_ITEM(closure, i); + PyObject *o = PyTuple_GET_ITEM(con->fc_closure, i); Py_INCREF(o); freevars[PyTuple_GET_SIZE(co->co_cellvars) + i] = o; } - /* Handle generator/coroutine/asynchronous generator */ - if (co->co_flags & (CO_GENERATOR | CO_COROUTINE | CO_ASYNC_GENERATOR)) { - PyObject *gen; - int is_coro = co->co_flags & CO_COROUTINE; + return f; - /* Don't need to keep the reference to f_back, it will be set - * when the generator is resumed. */ - Py_CLEAR(f->f_back); - - /* Create a new generator that owns the ready to run frame - * and return that as the value. */ - if (is_coro) { - gen = PyCoro_New(f, name, qualname); - } else if (co->co_flags & CO_ASYNC_GENERATOR) { - gen = PyAsyncGen_New(f, name, qualname); - } else { - gen = PyGen_NewWithQualName(f, name, qualname); - } - if (gen == NULL) { - return NULL; - } +fail: /* Jump here from prelude on failure */ + /* decref'ing the frame can cause __del__ methods to get invoked, + which can call back into Python. While we're done with the + current Python frame (f), the associated C stack is still in use, + so recursion_depth must be boosted for the duration. + */ + if (Py_REFCNT(f) > 1) { + Py_DECREF(f); _PyObject_GC_TRACK(f); + } + else { + ++tstate->recursion_depth; + Py_DECREF(f); + --tstate->recursion_depth; + } + return NULL; +} - return gen; +static PyObject * +make_coro(PyFrameConstructor *con, PyFrameObject *f) +{ + assert (((PyCodeObject *)con->fc_code)->co_flags & (CO_GENERATOR | CO_COROUTINE | CO_ASYNC_GENERATOR)); + PyObject *gen; + int is_coro = ((PyCodeObject *)con->fc_code)->co_flags & CO_COROUTINE; + + /* Don't need to keep the reference to f_back, it will be set + * when the generator is resumed. */ + Py_CLEAR(f->f_back); + + /* Create a new generator that owns the ready to run frame + * and return that as the value. */ + if (is_coro) { + gen = PyCoro_New(f, con->fc_name, con->fc_qualname); + } else if (((PyCodeObject *)con->fc_code)->co_flags & CO_ASYNC_GENERATOR) { + gen = PyAsyncGen_New(f, con->fc_name, con->fc_qualname); + } else { + gen = PyGen_NewWithQualName(f, con->fc_name, con->fc_qualname); + } + if (gen == NULL) { + return NULL; } - retval = _PyEval_EvalFrame(tstate, f, 0); + _PyObject_GC_TRACK(f); -fail: /* Jump here from prelude on failure */ + return gen; +} + +PyObject * +_PyEval_Vector(PyThreadState *tstate, PyFrameConstructor *con, + PyObject *locals, + PyObject* const* args, size_t argcount, + PyObject *kwnames) +{ + PyFrameObject *f = _PyEval_MakeFrameVector( + tstate, con, locals, args, argcount, kwnames); + if (f == NULL) { + return NULL; + } + if (((PyCodeObject *)con->fc_code)->co_flags & (CO_GENERATOR | CO_COROUTINE | CO_ASYNC_GENERATOR)) { + return make_coro(con, f); + } + PyObject *retval = _PyEval_EvalFrame(tstate, f, 0); /* decref'ing the frame can cause __del__ methods to get invoked, which can call back into Python. While we're done with the @@ -4347,26 +5081,7 @@ fail: /* Jump here from prelude on failure */ return retval; } - -PyObject * -_PyEval_EvalCodeWithName(PyObject *_co, PyObject *globals, PyObject *locals, - PyObject *const *args, Py_ssize_t argcount, - PyObject *const *kwnames, PyObject *const *kwargs, - Py_ssize_t kwcount, int kwstep, - PyObject *const *defs, Py_ssize_t defcount, - PyObject *kwdefs, PyObject *closure, - PyObject *name, PyObject *qualname) -{ - PyThreadState *tstate = _PyThreadState_GET(); - return _PyEval_EvalCode(tstate, _co, globals, locals, - args, argcount, - kwnames, kwargs, - kwcount, kwstep, - defs, defcount, - kwdefs, closure, - name, qualname); -} - +/* Legacy API */ PyObject * PyEval_EvalCodeEx(PyObject *_co, PyObject *globals, PyObject *locals, PyObject *const *args, int argcount, @@ -4374,15 +5089,70 @@ PyEval_EvalCodeEx(PyObject *_co, PyObject *globals, PyObject *locals, PyObject *const *defs, int defcount, PyObject *kwdefs, PyObject *closure) { - return _PyEval_EvalCodeWithName(_co, globals, locals, - args, argcount, - kws, kws != NULL ? kws + 1 : NULL, - kwcount, 2, - defs, defcount, - kwdefs, closure, - NULL, NULL); + PyThreadState *tstate = _PyThreadState_GET(); + PyObject *res = NULL; + PyObject *defaults = _PyTuple_FromArray(defs, defcount); + if (defaults == NULL) { + return NULL; + } + PyObject *builtins = _PyEval_BuiltinsFromGlobals(tstate, globals); // borrowed ref + if (builtins == NULL) { + Py_DECREF(defaults); + return NULL; + } + if (locals == NULL) { + locals = globals; + } + PyObject *kwnames = NULL; + PyObject *const *allargs; + PyObject **newargs = NULL; + if (kwcount == 0) { + allargs = args; + } + else { + kwnames = PyTuple_New(kwcount); + if (kwnames == NULL) { + goto fail; + } + newargs = PyMem_Malloc(sizeof(PyObject *)*(kwcount+argcount)); + if (newargs == NULL) { + goto fail; + } + for (int i = 0; i < argcount; i++) { + newargs[i] = args[i]; + } + for (int i = 0; i < kwcount; i++) { + Py_INCREF(kws[2*i]); + PyTuple_SET_ITEM(kwnames, i, kws[2*i]); + newargs[argcount+i] = kws[2*i+1]; + } + allargs = newargs; + } + for (int i = 0; i < kwcount; i++) { + Py_INCREF(kws[2*i]); + PyTuple_SET_ITEM(kwnames, i, kws[2*i]); + } + PyFrameConstructor constr = { + .fc_globals = globals, + .fc_builtins = builtins, + .fc_name = ((PyCodeObject *)_co)->co_name, + .fc_qualname = ((PyCodeObject *)_co)->co_name, + .fc_code = _co, + .fc_defaults = defaults, + .fc_kwdefaults = kwdefs, + .fc_closure = closure + }; + res = _PyEval_Vector(tstate, &constr, locals, + allargs, argcount, + kwnames); +fail: + Py_XDECREF(kwnames); + PyMem_Free(newargs); + Py_DECREF(defaults); + return res; } + static PyObject * special_lookup(PyThreadState *tstate, PyObject *o, _Py_Identifier *id) { @@ -4410,7 +5180,7 @@ do_raise(PyThreadState *tstate, PyObject *exc, PyObject *cause) type = exc_info->exc_type; value = exc_info->exc_value; tb = exc_info->exc_traceback; - if (type == Py_None || type == NULL) { + if (Py_IsNone(type) || type == NULL) { _PyErr_SetString(tstate, PyExc_RuntimeError, "No active exception to reraise"); return 0; @@ -4468,7 +5238,7 @@ do_raise(PyThreadState *tstate, PyObject *exc, PyObject *cause) else if (PyExceptionInstance_Check(cause)) { fixed_cause = cause; } - else if (cause == Py_None) { + else if (Py_IsNone(cause)) { Py_DECREF(cause); fixed_cause = NULL; } @@ -4594,7 +5364,6 @@ Error: return 0; } - #ifdef LLTRACE static int prtrace(PyThreadState *tstate, PyObject *v, const char *str) @@ -4614,7 +5383,9 @@ prtrace(PyThreadState *tstate, PyObject *v, const char *str) static void call_exc_trace(Py_tracefunc func, PyObject *self, - PyThreadState *tstate, PyFrameObject *f) + PyThreadState *tstate, + PyFrameObject *f, + PyTraceInfo *trace_info) { PyObject *type, *value, *traceback, *orig_traceback, *arg; int err; @@ -4630,7 +5401,7 @@ call_exc_trace(Py_tracefunc func, PyObject *self, _PyErr_Restore(tstate, type, value, orig_traceback); return; } - err = call_trace(func, self, tstate, f, PyTrace_EXCEPTION, arg); + err = call_trace(func, self, tstate, f, trace_info, PyTrace_EXCEPTION, arg); Py_DECREF(arg); if (err == 0) { _PyErr_Restore(tstate, type, value, orig_traceback); @@ -4645,12 +5416,13 @@ call_exc_trace(Py_tracefunc func, PyObject *self, static int call_trace_protected(Py_tracefunc func, PyObject *obj, PyThreadState *tstate, PyFrameObject *frame, + PyTraceInfo *trace_info, int what, PyObject *arg) { PyObject *type, *value, *traceback; int err; _PyErr_Fetch(tstate, &type, &value, &traceback); - err = call_trace(func, obj, tstate, frame, what, arg); + err = call_trace(func, obj, tstate, frame, trace_info, what, arg); if (err == 0) { _PyErr_Restore(tstate, type, value, traceback); @@ -4664,18 +5436,36 @@ call_trace_protected(Py_tracefunc func, PyObject *obj, } } +static void +initialize_trace_info(PyTraceInfo *trace_info, PyFrameObject *frame) +{ + if (trace_info->code != frame->f_code) { + trace_info->code = frame->f_code; + _PyCode_InitAddressRange(frame->f_code, &trace_info->bounds); + } +} + static int call_trace(Py_tracefunc func, PyObject *obj, PyThreadState *tstate, PyFrameObject *frame, + PyTraceInfo *trace_info, int what, PyObject *arg) { int result; if (tstate->tracing) return 0; tstate->tracing++; - tstate->use_tracing = 0; + tstate->cframe->use_tracing = 0; + if (frame->f_lasti < 0) { + frame->f_lineno = frame->f_code->co_firstlineno; + } + else { + initialize_trace_info(trace_info, frame); + frame->f_lineno = _PyCode_CheckLineNumber(frame->f_lasti*sizeof(_Py_CODEUNIT), &trace_info->bounds); + } result = func(obj, frame, what, arg); - tstate->use_tracing = ((tstate->c_tracefunc != NULL) + frame->f_lineno = 0; + tstate->cframe->use_tracing = ((tstate->c_tracefunc != NULL) || (tstate->c_profilefunc != NULL)); tstate->tracing--; return result; @@ -4686,15 +5476,15 @@ _PyEval_CallTracing(PyObject *func, PyObject *args) { PyThreadState *tstate = _PyThreadState_GET(); int save_tracing = tstate->tracing; - int save_use_tracing = tstate->use_tracing; + int save_use_tracing = tstate->cframe->use_tracing; PyObject *result; tstate->tracing = 0; - tstate->use_tracing = ((tstate->c_tracefunc != NULL) + tstate->cframe->use_tracing = ((tstate->c_tracefunc != NULL) || (tstate->c_profilefunc != NULL)); result = PyObject_Call(func, args, NULL); tstate->tracing = save_tracing; - tstate->use_tracing = save_use_tracing; + tstate->cframe->use_tracing = save_use_tracing; return result; } @@ -4702,36 +5492,27 @@ _PyEval_CallTracing(PyObject *func, PyObject *args) static int maybe_call_line_trace(Py_tracefunc func, PyObject *obj, PyThreadState *tstate, PyFrameObject *frame, - int *instr_lb, int *instr_ub, int *instr_prev) + PyTraceInfo *trace_info, int instr_prev) { int result = 0; - int line = frame->f_lineno; - /* If the last instruction executed isn't in the current - instruction window, reset the window. - */ - if (frame->f_lasti < *instr_lb || frame->f_lasti >= *instr_ub) { - PyAddrPair bounds; - line = _PyCode_CheckLineNumber(frame->f_code, frame->f_lasti, - &bounds); - *instr_lb = bounds.ap_lower; - *instr_ub = bounds.ap_upper; - } /* If the last instruction falls at the start of a line or if it represents a jump backwards, update the frame's line number and then call the trace function if we're tracing source lines. */ - if ((frame->f_lasti == *instr_lb || frame->f_lasti < *instr_prev)) { - frame->f_lineno = line; - if (frame->f_trace_lines) { - result = call_trace(func, obj, tstate, frame, PyTrace_LINE, Py_None); + initialize_trace_info(trace_info, frame); + int lastline = _PyCode_CheckLineNumber(instr_prev*sizeof(_Py_CODEUNIT), &trace_info->bounds); + int line = _PyCode_CheckLineNumber(frame->f_lasti*sizeof(_Py_CODEUNIT), &trace_info->bounds); + if (line != -1 && frame->f_trace_lines) { + /* Trace backward edges or if line number has changed */ + if (frame->f_lasti < instr_prev || line != lastline) { + result = call_trace(func, obj, tstate, frame, trace_info, PyTrace_LINE, Py_None); } } /* Always emit an opcode event if we're tracing all opcodes. */ if (frame->f_trace_opcodes) { - result = call_trace(func, obj, tstate, frame, PyTrace_OPCODE, Py_None); + result = call_trace(func, obj, tstate, frame, trace_info, PyTrace_OPCODE, Py_None); } - *instr_prev = frame->f_lasti; return result; } @@ -4754,7 +5535,7 @@ _PyEval_SetProfile(PyThreadState *tstate, Py_tracefunc func, PyObject *arg) tstate->c_profilefunc = NULL; tstate->c_profileobj = NULL; /* Must make sure that tracing is not ignored if 'profileobj' is freed */ - tstate->use_tracing = tstate->c_tracefunc != NULL; + tstate->cframe->use_tracing = tstate->c_tracefunc != NULL; Py_XDECREF(profileobj); Py_XINCREF(arg); @@ -4762,7 +5543,7 @@ _PyEval_SetProfile(PyThreadState *tstate, Py_tracefunc func, PyObject *arg) tstate->c_profilefunc = func; /* Flag that tracing or profiling is turned on */ - tstate->use_tracing = (func != NULL) || (tstate->c_tracefunc != NULL); + tstate->cframe->use_tracing = (func != NULL) || (tstate->c_tracefunc != NULL); return 0; } @@ -4790,14 +5571,12 @@ _PyEval_SetTrace(PyThreadState *tstate, Py_tracefunc func, PyObject *arg) return -1; } - struct _ceval_state *ceval2 = &tstate->interp->ceval; PyObject *traceobj = tstate->c_traceobj; - ceval2->tracing_possible += (func != NULL) - (tstate->c_tracefunc != NULL); tstate->c_tracefunc = NULL; tstate->c_traceobj = NULL; /* Must make sure that profiling is not ignored if 'traceobj' is freed */ - tstate->use_tracing = (tstate->c_profilefunc != NULL); + tstate->cframe->use_tracing = (tstate->c_profilefunc != NULL); Py_XDECREF(traceobj); Py_XINCREF(arg); @@ -4805,7 +5584,7 @@ _PyEval_SetTrace(PyThreadState *tstate, Py_tracefunc func, PyObject *arg) tstate->c_tracefunc = func; /* Flag that tracing or profiling is turned on */ - tstate->use_tracing = ((func != NULL) + tstate->cframe->use_tracing = ((func != NULL) || (tstate->c_profilefunc != NULL)); return 0; @@ -4886,14 +5665,20 @@ PyEval_GetFrame(void) } PyObject * +_PyEval_GetBuiltins(PyThreadState *tstate) +{ + PyFrameObject *frame = tstate->frame; + if (frame != NULL) { + return frame->f_builtins; + } + return tstate->interp->builtins; +} + +PyObject * PyEval_GetBuiltins(void) { PyThreadState *tstate = _PyThreadState_GET(); - PyFrameObject *current_frame = tstate->frame; - if (current_frame == NULL) - return tstate->interp->builtins; - else - return current_frame->f_builtins; + return _PyEval_GetBuiltins(tstate); } /* Convenience function to get a builtin from its name */ @@ -4994,9 +5779,9 @@ PyEval_GetFuncDesc(PyObject *func) } #define C_TRACE(x, call) \ -if (tstate->use_tracing && tstate->c_profilefunc) { \ +if (trace_info->cframe.use_tracing && tstate->c_profilefunc) { \ if (call_trace(tstate->c_profilefunc, tstate->c_profileobj, \ - tstate, tstate->frame, \ + tstate, tstate->frame, trace_info, \ PyTrace_C_CALL, func)) { \ x = NULL; \ } \ @@ -5006,13 +5791,13 @@ if (tstate->use_tracing && tstate->c_profilefunc) { \ if (x == NULL) { \ call_trace_protected(tstate->c_profilefunc, \ tstate->c_profileobj, \ - tstate, tstate->frame, \ + tstate, tstate->frame, trace_info, \ PyTrace_C_EXCEPTION, func); \ /* XXX should pass (type, value, tb) */ \ } else { \ if (call_trace(tstate->c_profilefunc, \ tstate->c_profileobj, \ - tstate, tstate->frame, \ + tstate, tstate->frame, trace_info, \ PyTrace_C_RETURN, func)) { \ Py_DECREF(x); \ x = NULL; \ @@ -5027,6 +5812,7 @@ if (tstate->use_tracing && tstate->c_profilefunc) { \ static PyObject * trace_call_function(PyThreadState *tstate, + PyTraceInfo *trace_info, PyObject *func, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) @@ -5061,7 +5847,11 @@ trace_call_function(PyThreadState *tstate, /* Issue #29227: Inline call_function() into _PyEval_EvalFrameDefault() to reduce the stack consumption. */ Py_LOCAL_INLINE(PyObject *) _Py_HOT_FUNCTION -call_function(PyThreadState *tstate, PyObject ***pp_stack, Py_ssize_t oparg, PyObject *kwnames) +call_function(PyThreadState *tstate, + PyTraceInfo *trace_info, + PyObject ***pp_stack, + Py_ssize_t oparg, + PyObject *kwnames) { PyObject **pfunc = (*pp_stack) - oparg - 1; PyObject *func = *pfunc; @@ -5070,8 +5860,8 @@ call_function(PyThreadState *tstate, PyObject ***pp_stack, Py_ssize_t oparg, PyO Py_ssize_t nargs = oparg - nkwargs; PyObject **stack = (*pp_stack) - nargs - nkwargs; - if (tstate->use_tracing) { - x = trace_call_function(tstate, func, stack, nargs, kwnames); + if (trace_info->cframe.use_tracing) { + x = trace_call_function(tstate, trace_info, func, stack, nargs, kwnames); } else { x = PyObject_Vectorcall(func, stack, nargs | PY_VECTORCALL_ARGUMENTS_OFFSET, kwnames); @@ -5089,7 +5879,11 @@ call_function(PyThreadState *tstate, PyObject ***pp_stack, Py_ssize_t oparg, PyO } static PyObject * -do_call_core(PyThreadState *tstate, PyObject *func, PyObject *callargs, PyObject *kwdict) +do_call_core(PyThreadState *tstate, + PyTraceInfo *trace_info, + PyObject *func, + PyObject *callargs, + PyObject *kwdict) { PyObject *result; @@ -5099,7 +5893,7 @@ do_call_core(PyThreadState *tstate, PyObject *func, PyObject *callargs, PyObject } else if (Py_IS_TYPE(func, &PyMethodDescr_Type)) { Py_ssize_t nargs = PyTuple_GET_SIZE(callargs); - if (nargs > 0 && tstate->use_tracing) { + if (nargs > 0 && trace_info->cframe.use_tracing) { /* We need to create a temporary bound method as argument for profiling. @@ -5135,7 +5929,7 @@ int _PyEval_SliceIndex(PyObject *v, Py_ssize_t *pi) { PyThreadState *tstate = _PyThreadState_GET(); - if (v != Py_None) { + if (!Py_IsNone(v)) { Py_ssize_t x; if (_PyIndex_Check(v)) { x = PyNumber_AsSsize_t(v, NULL); @@ -5459,6 +6253,23 @@ format_exc_check_arg(PyThreadState *tstate, PyObject *exc, return; _PyErr_Format(tstate, exc, format_str, obj_str); + + if (exc == PyExc_NameError) { + // Include the name in the NameError exceptions to offer suggestions later. + _Py_IDENTIFIER(name); + PyObject *type, *value, *traceback; + PyErr_Fetch(&type, &value, &traceback); + PyErr_NormalizeException(&type, &value, &traceback); + if (PyErr_GivenExceptionMatches(value, PyExc_NameError)) { + PyNameErrorObject* exc = (PyNameErrorObject*) value; + if (exc->name == NULL) { + // We do not care if this fails because we are going to restore the + // NameError anyway. + (void)_PyObject_SetAttrId(value, &PyId_name, obj); + } + } + PyErr_Restore(type, value, traceback); + } } static void @@ -5626,7 +6437,7 @@ dtrace_function_entry(PyFrameObject *f) PyCodeObject *code = f->f_code; filename = PyUnicode_AsUTF8(code->co_filename); funcname = PyUnicode_AsUTF8(code->co_name); - lineno = PyCode_Addr2Line(code, f->f_lasti); + lineno = PyFrame_GetLineNumber(f); PyDTrace_FUNCTION_ENTRY(filename, funcname, lineno); } @@ -5641,7 +6452,7 @@ dtrace_function_return(PyFrameObject *f) PyCodeObject *code = f->f_code; filename = PyUnicode_AsUTF8(code->co_filename); funcname = PyUnicode_AsUTF8(code->co_name); - lineno = PyCode_Addr2Line(code, f->f_lasti); + lineno = PyFrame_GetLineNumber(f); PyDTrace_FUNCTION_RETURN(filename, funcname, lineno); } @@ -5649,35 +6460,30 @@ dtrace_function_return(PyFrameObject *f) /* DTrace equivalent of maybe_call_line_trace. */ static void maybe_dtrace_line(PyFrameObject *frame, - int *instr_lb, int *instr_ub, int *instr_prev) + PyTraceInfo *trace_info, int instr_prev) { - int line = frame->f_lineno; const char *co_filename, *co_name; /* If the last instruction executed isn't in the current instruction window, reset the window. */ - if (frame->f_lasti < *instr_lb || frame->f_lasti >= *instr_ub) { - PyAddrPair bounds; - line = _PyCode_CheckLineNumber(frame->f_code, frame->f_lasti, - &bounds); - *instr_lb = bounds.ap_lower; - *instr_ub = bounds.ap_upper; - } + initialize_trace_info(trace_info, frame); + int line = _PyCode_CheckLineNumber(frame->f_lasti*sizeof(_Py_CODEUNIT), &trace_info->bounds); /* If the last instruction falls at the start of a line or if it represents a jump backwards, update the frame's line number and call the trace function. */ - if (frame->f_lasti == *instr_lb || frame->f_lasti < *instr_prev) { - frame->f_lineno = line; - co_filename = PyUnicode_AsUTF8(frame->f_code->co_filename); - if (!co_filename) - co_filename = "?"; - co_name = PyUnicode_AsUTF8(frame->f_code->co_name); - if (!co_name) - co_name = "?"; - PyDTrace_LINE(co_filename, co_name, line); - } - *instr_prev = frame->f_lasti; + if (line != frame->f_lineno || frame->f_lasti < instr_prev) { + if (line != -1) { + frame->f_lineno = line; + co_filename = PyUnicode_AsUTF8(frame->f_code->co_filename); + if (!co_filename) + co_filename = "?"; + co_name = PyUnicode_AsUTF8(frame->f_code->co_name); + if (!co_name) + co_name = "?"; + PyDTrace_LINE(co_filename, co_name, line); + } + } } diff --git a/contrib/tools/python3/src/Python/ceval_gil.h b/contrib/tools/python3/src/Python/ceval_gil.h index 3510675a69b..9b8b43253f0 100644 --- a/contrib/tools/python3/src/Python/ceval_gil.h +++ b/contrib/tools/python3/src/Python/ceval_gil.h @@ -144,7 +144,11 @@ static void drop_gil(struct _ceval_runtime_state *ceval, struct _ceval_state *ceval2, PyThreadState *tstate) { +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + struct _gil_runtime_state *gil = &ceval2->gil; +#else struct _gil_runtime_state *gil = &ceval->gil; +#endif if (!_Py_atomic_load_relaxed(&gil->locked)) { Py_FatalError("drop_gil: GIL is not locked"); } @@ -228,7 +232,11 @@ take_gil(PyThreadState *tstate) PyInterpreterState *interp = tstate->interp; struct _ceval_runtime_state *ceval = &interp->runtime->ceval; struct _ceval_state *ceval2 = &interp->ceval; +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + struct _gil_runtime_state *gil = &ceval2->gil; +#else struct _gil_runtime_state *gil = &ceval->gil; +#endif /* Check that _PyEval_InitThreads() was called to create the lock */ assert(gil_created(gil)); @@ -310,7 +318,7 @@ _ready: /* Don't access tstate if the thread must exit */ if (tstate->async_exc != NULL) { - _PyEval_SignalAsyncExc(tstate); + _PyEval_SignalAsyncExc(tstate->interp); } MUTEX_UNLOCK(gil->mutex); @@ -320,12 +328,22 @@ _ready: void _PyEval_SetSwitchInterval(unsigned long microseconds) { +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + PyInterpreterState *interp = PyInterpreterState_Get(); + struct _gil_runtime_state *gil = &interp->ceval.gil; +#else struct _gil_runtime_state *gil = &_PyRuntime.ceval.gil; +#endif gil->interval = microseconds; } unsigned long _PyEval_GetSwitchInterval() { +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + PyInterpreterState *interp = PyInterpreterState_Get(); + struct _gil_runtime_state *gil = &interp->ceval.gil; +#else struct _gil_runtime_state *gil = &_PyRuntime.ceval.gil; +#endif return gil->interval; } diff --git a/contrib/tools/python3/src/Python/clinic/_warnings.c.h b/contrib/tools/python3/src/Python/clinic/_warnings.c.h index 67ab0e3d9de..ad6b9a8e242 100644 --- a/contrib/tools/python3/src/Python/clinic/_warnings.c.h +++ b/contrib/tools/python3/src/Python/clinic/_warnings.c.h @@ -43,14 +43,9 @@ warnings_warn(PyObject *module, PyObject *const *args, Py_ssize_t nargs, PyObjec } } if (args[2]) { - if (PyFloat_Check(args[2])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } { Py_ssize_t ival = -1; - PyObject *iobj = PyNumber_Index(args[2]); + PyObject *iobj = _PyNumber_Index(args[2]); if (iobj != NULL) { ival = PyLong_AsSsize_t(iobj); Py_DECREF(iobj); @@ -71,4 +66,4 @@ skip_optional_pos: exit: return return_value; } -/*[clinic end generated code: output=b7bb54c73b5433ec input=a9049054013a1b77]*/ +/*[clinic end generated code: output=eb9997fa998fdbad input=a9049054013a1b77]*/ diff --git a/contrib/tools/python3/src/Python/clinic/bltinmodule.c.h b/contrib/tools/python3/src/Python/clinic/bltinmodule.c.h index d15af1f7f37..545f5b53f6e 100644 --- a/contrib/tools/python3/src/Python/clinic/bltinmodule.c.h +++ b/contrib/tools/python3/src/Python/clinic/bltinmodule.c.h @@ -134,11 +134,6 @@ builtin_chr(PyObject *module, PyObject *arg) PyObject *return_value = NULL; int i; - if (PyFloat_Check(arg)) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } i = _PyLong_AsInt(arg); if (i == -1 && PyErr_Occurred()) { goto exit; @@ -216,11 +211,6 @@ builtin_compile(PyObject *module, PyObject *const *args, Py_ssize_t nargs, PyObj goto skip_optional_pos; } if (args[3]) { - if (PyFloat_Check(args[3])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } flags = _PyLong_AsInt(args[3]); if (flags == -1 && PyErr_Occurred()) { goto exit; @@ -230,11 +220,6 @@ builtin_compile(PyObject *module, PyObject *const *args, Py_ssize_t nargs, PyObj } } if (args[4]) { - if (PyFloat_Check(args[4])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } dont_inherit = _PyLong_AsInt(args[4]); if (dont_inherit == -1 && PyErr_Occurred()) { goto exit; @@ -244,11 +229,6 @@ builtin_compile(PyObject *module, PyObject *const *args, Py_ssize_t nargs, PyObj } } if (args[5]) { - if (PyFloat_Check(args[5])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } optimize = _PyLong_AsInt(args[5]); if (optimize == -1 && PyErr_Occurred()) { goto exit; @@ -261,11 +241,6 @@ skip_optional_pos: if (!noptargs) { goto skip_optional_kwonly; } - if (PyFloat_Check(args[6])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } feature_version = _PyLong_AsInt(args[6]); if (feature_version == -1 && PyErr_Occurred()) { goto exit; @@ -555,6 +530,50 @@ PyDoc_STRVAR(builtin_hex__doc__, #define BUILTIN_HEX_METHODDEF \ {"hex", (PyCFunction)builtin_hex, METH_O, builtin_hex__doc__}, +PyDoc_STRVAR(builtin_aiter__doc__, +"aiter($module, async_iterable, /)\n" +"--\n" +"\n" +"Return an AsyncIterator for an AsyncIterable object."); + +#define BUILTIN_AITER_METHODDEF \ + {"aiter", (PyCFunction)builtin_aiter, METH_O, builtin_aiter__doc__}, + +PyDoc_STRVAR(builtin_anext__doc__, +"anext($module, aiterator, default=<unrepresentable>, /)\n" +"--\n" +"\n" +"Return the next item from the async iterator."); + +#define BUILTIN_ANEXT_METHODDEF \ + {"anext", (PyCFunction)(void(*)(void))builtin_anext, METH_FASTCALL, builtin_anext__doc__}, + +static PyObject * +builtin_anext_impl(PyObject *module, PyObject *aiterator, + PyObject *default_value); + +static PyObject * +builtin_anext(PyObject *module, PyObject *const *args, Py_ssize_t nargs) +{ + PyObject *return_value = NULL; + PyObject *aiterator; + PyObject *default_value = NULL; + + if (!_PyArg_CheckPositional("anext", nargs, 1, 2)) { + goto exit; + } + aiterator = args[0]; + if (nargs < 2) { + goto skip_optional; + } + default_value = args[1]; +skip_optional: + return_value = builtin_anext_impl(module, aiterator, default_value); + +exit: + return return_value; +} + PyDoc_STRVAR(builtin_len__doc__, "len($module, obj, /)\n" "--\n" @@ -825,11 +844,11 @@ PyDoc_STRVAR(builtin_issubclass__doc__, "issubclass($module, cls, class_or_tuple, /)\n" "--\n" "\n" -"Return whether \'cls\' is a derived from another class or is the same class.\n" +"Return whether \'cls\' is derived from another class or is the same class.\n" "\n" "A tuple, as in ``issubclass(x, (A, B, ...))``, may be given as the target to\n" "check against. This is equivalent to ``issubclass(x, A) or issubclass(x, B)\n" -"or ...`` etc."); +"or ...``."); #define BUILTIN_ISSUBCLASS_METHODDEF \ {"issubclass", (PyCFunction)(void(*)(void))builtin_issubclass, METH_FASTCALL, builtin_issubclass__doc__}, @@ -855,4 +874,4 @@ builtin_issubclass(PyObject *module, PyObject *const *args, Py_ssize_t nargs) exit: return return_value; } -/*[clinic end generated code: output=29686a89b739d600 input=a9049054013a1b77]*/ +/*[clinic end generated code: output=da9ae459e9233259 input=a9049054013a1b77]*/ diff --git a/contrib/tools/python3/src/Python/clinic/import.c.h b/contrib/tools/python3/src/Python/clinic/import.c.h index e4867f34d4e..4e013cc97d6 100644 --- a/contrib/tools/python3/src/Python/clinic/import.c.h +++ b/contrib/tools/python3/src/Python/clinic/import.c.h @@ -420,11 +420,6 @@ _imp_source_hash(PyObject *module, PyObject *const *args, Py_ssize_t nargs, PyOb if (!args) { goto exit; } - if (PyFloat_Check(args[0])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } key = PyLong_AsLong(args[0]); if (key == -1 && PyErr_Occurred()) { goto exit; @@ -454,4 +449,4 @@ exit: #ifndef _IMP_EXEC_DYNAMIC_METHODDEF #define _IMP_EXEC_DYNAMIC_METHODDEF #endif /* !defined(_IMP_EXEC_DYNAMIC_METHODDEF) */ -/*[clinic end generated code: output=3dc495e9c64d944e input=a9049054013a1b77]*/ +/*[clinic end generated code: output=7c31c433af88af6b input=a9049054013a1b77]*/ diff --git a/contrib/tools/python3/src/Python/clinic/marshal.c.h b/contrib/tools/python3/src/Python/clinic/marshal.c.h index 05d4830c4ab..f80d5ef31f2 100644 --- a/contrib/tools/python3/src/Python/clinic/marshal.c.h +++ b/contrib/tools/python3/src/Python/clinic/marshal.c.h @@ -42,11 +42,6 @@ marshal_dump(PyObject *module, PyObject *const *args, Py_ssize_t nargs) if (nargs < 3) { goto skip_optional; } - if (PyFloat_Check(args[2])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } version = _PyLong_AsInt(args[2]); if (version == -1 && PyErr_Occurred()) { goto exit; @@ -111,11 +106,6 @@ marshal_dumps(PyObject *module, PyObject *const *args, Py_ssize_t nargs) if (nargs < 2) { goto skip_optional; } - if (PyFloat_Check(args[1])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } version = _PyLong_AsInt(args[1]); if (version == -1 && PyErr_Occurred()) { goto exit; @@ -165,4 +155,4 @@ exit: return return_value; } -/*[clinic end generated code: output=a859dabe8b0afeb6 input=a9049054013a1b77]*/ +/*[clinic end generated code: output=68b78f38bfe0c06d input=a9049054013a1b77]*/ diff --git a/contrib/tools/python3/src/Python/clinic/sysmodule.c.h b/contrib/tools/python3/src/Python/clinic/sysmodule.c.h index 4615ebaab5d..04c84811498 100644 --- a/contrib/tools/python3/src/Python/clinic/sysmodule.c.h +++ b/contrib/tools/python3/src/Python/clinic/sysmodule.c.h @@ -372,11 +372,6 @@ sys_setrecursionlimit(PyObject *module, PyObject *arg) PyObject *return_value = NULL; int new_limit; - if (PyFloat_Check(arg)) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } new_limit = _PyLong_AsInt(arg); if (new_limit == -1 && PyErr_Occurred()) { goto exit; @@ -417,11 +412,6 @@ sys_set_coroutine_origin_tracking_depth(PyObject *module, PyObject *const *args, if (!args) { goto exit; } - if (PyFloat_Check(args[0])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } depth = _PyLong_AsInt(args[0]); if (depth == -1 && PyErr_Occurred()) { goto exit; @@ -590,11 +580,6 @@ sys_setdlopenflags(PyObject *module, PyObject *arg) PyObject *return_value = NULL; int new_val; - if (PyFloat_Check(arg)) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } new_val = _PyLong_AsInt(arg); if (new_val == -1 && PyErr_Occurred()) { goto exit; @@ -650,11 +635,6 @@ sys_mdebug(PyObject *module, PyObject *arg) PyObject *return_value = NULL; int flag; - if (PyFloat_Check(arg)) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } flag = _PyLong_AsInt(arg); if (flag == -1 && PyErr_Occurred()) { goto exit; @@ -790,11 +770,6 @@ sys__getframe(PyObject *module, PyObject *const *args, Py_ssize_t nargs) if (nargs < 1) { goto skip_optional; } - if (PyFloat_Check(args[0])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } depth = _PyLong_AsInt(args[0]); if (depth == -1 && PyErr_Occurred()) { goto exit; @@ -826,6 +801,26 @@ sys__current_frames(PyObject *module, PyObject *Py_UNUSED(ignored)) return sys__current_frames_impl(module); } +PyDoc_STRVAR(sys__current_exceptions__doc__, +"_current_exceptions($module, /)\n" +"--\n" +"\n" +"Return a dict mapping each thread\'s identifier to its current raised exception.\n" +"\n" +"This function should be used for specialized purposes only."); + +#define SYS__CURRENT_EXCEPTIONS_METHODDEF \ + {"_current_exceptions", (PyCFunction)sys__current_exceptions, METH_NOARGS, sys__current_exceptions__doc__}, + +static PyObject * +sys__current_exceptions_impl(PyObject *module); + +static PyObject * +sys__current_exceptions(PyObject *module, PyObject *Py_UNUSED(ignored)) +{ + return sys__current_exceptions_impl(module); +} + PyDoc_STRVAR(sys_call_tracing__doc__, "call_tracing($module, func, args, /)\n" "--\n" @@ -943,6 +938,24 @@ sys_getandroidapilevel(PyObject *module, PyObject *Py_UNUSED(ignored)) #endif /* defined(ANDROID_API_LEVEL) */ +PyDoc_STRVAR(sys__deactivate_opcache__doc__, +"_deactivate_opcache($module, /)\n" +"--\n" +"\n" +"Deactivate the opcode cache permanently"); + +#define SYS__DEACTIVATE_OPCACHE_METHODDEF \ + {"_deactivate_opcache", (PyCFunction)sys__deactivate_opcache, METH_NOARGS, sys__deactivate_opcache__doc__}, + +static PyObject * +sys__deactivate_opcache_impl(PyObject *module); + +static PyObject * +sys__deactivate_opcache(PyObject *module, PyObject *Py_UNUSED(ignored)) +{ + return sys__deactivate_opcache_impl(module); +} + #ifndef SYS_GETWINDOWSVERSION_METHODDEF #define SYS_GETWINDOWSVERSION_METHODDEF #endif /* !defined(SYS_GETWINDOWSVERSION_METHODDEF) */ @@ -970,4 +983,4 @@ sys_getandroidapilevel(PyObject *module, PyObject *Py_UNUSED(ignored)) #ifndef SYS_GETANDROIDAPILEVEL_METHODDEF #define SYS_GETANDROIDAPILEVEL_METHODDEF #endif /* !defined(SYS_GETANDROIDAPILEVEL_METHODDEF) */ -/*[clinic end generated code: output=39eb34a01fb9a919 input=a9049054013a1b77]*/ +/*[clinic end generated code: output=68c62b9ca317a0c8 input=a9049054013a1b77]*/ diff --git a/contrib/tools/python3/src/Python/clinic/traceback.c.h b/contrib/tools/python3/src/Python/clinic/traceback.c.h index 04daf2a3766..404a0c416d3 100644 --- a/contrib/tools/python3/src/Python/clinic/traceback.c.h +++ b/contrib/tools/python3/src/Python/clinic/traceback.c.h @@ -36,20 +36,10 @@ tb_new(PyTypeObject *type, PyObject *args, PyObject *kwargs) goto exit; } tb_frame = (PyFrameObject *)fastargs[1]; - if (PyFloat_Check(fastargs[2])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } tb_lasti = _PyLong_AsInt(fastargs[2]); if (tb_lasti == -1 && PyErr_Occurred()) { goto exit; } - if (PyFloat_Check(fastargs[3])) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - goto exit; - } tb_lineno = _PyLong_AsInt(fastargs[3]); if (tb_lineno == -1 && PyErr_Occurred()) { goto exit; @@ -59,4 +49,4 @@ tb_new(PyTypeObject *type, PyObject *args, PyObject *kwargs) exit: return return_value; } -/*[clinic end generated code: output=3def6c06248feed8 input=a9049054013a1b77]*/ +/*[clinic end generated code: output=403778d7af5ebef9 input=a9049054013a1b77]*/ diff --git a/contrib/tools/python3/src/Python/codecs.c b/contrib/tools/python3/src/Python/codecs.c index 0f18c27e5fe..fa329ce2436 100644 --- a/contrib/tools/python3/src/Python/codecs.c +++ b/contrib/tools/python3/src/Python/codecs.c @@ -11,7 +11,7 @@ Copyright (c) Corporation for National Research Initiatives. #include "Python.h" #include "pycore_interp.h" // PyInterpreterState.codec_search_path #include "pycore_pystate.h" // _PyInterpreterState_GET() -#include "ucnhash.h" +#include "pycore_ucnhash.h" // _PyUnicode_Name_CAPI #include <ctype.h> const char *Py_hexdigits = "0123456789abcdef"; @@ -50,6 +50,31 @@ int PyCodec_Register(PyObject *search_function) return -1; } +int +PyCodec_Unregister(PyObject *search_function) +{ + PyInterpreterState *interp = PyInterpreterState_Get(); + PyObject *codec_search_path = interp->codec_search_path; + /* Do nothing if codec_search_path is not created yet or was cleared. */ + if (codec_search_path == NULL) { + return 0; + } + + assert(PyList_CheckExact(codec_search_path)); + Py_ssize_t n = PyList_GET_SIZE(codec_search_path); + for (Py_ssize_t i = 0; i < n; i++) { + PyObject *item = PyList_GET_ITEM(codec_search_path, i); + if (item == search_function) { + if (interp->codec_search_cache != NULL) { + assert(PyDict_CheckExact(interp->codec_search_cache)); + PyDict_Clear(interp->codec_search_cache); + } + return PyList_SetSlice(codec_search_path, i, i+1, NULL); + } + } + return 0; +} + extern int _Py_normalize_encoding(const char *, char *, size_t); /* Convert a string to a normalized Python string(decoded from UTF-8): all characters are @@ -183,31 +208,6 @@ PyObject *_PyCodec_Lookup(const char *encoding) return NULL; } -int _PyCodec_Forget(const char *encoding) -{ - PyObject *v; - int result; - - PyInterpreterState *interp = _PyInterpreterState_GET(); - if (interp->codec_search_path == NULL) { - return -1; - } - - /* Convert the encoding to a normalized Python string: all - characters are converted to lower case, spaces and hyphens are - replaced with underscores. */ - v = normalizestring(encoding); - if (v == NULL) { - return -1; - } - - /* Drop the named codec from the internal cache */ - result = PyDict_DelItem(interp->codec_search_cache, v); - Py_DECREF(v); - - return result; -} - /* Codec registry encoding check API. */ int PyCodec_KnownEncoding(const char *encoding) @@ -954,7 +954,7 @@ PyObject *PyCodec_BackslashReplaceErrors(PyObject *exc) return Py_BuildValue("(Nn)", res, end); } -static _PyUnicode_Name_CAPI *ucnhash_CAPI = NULL; +static _PyUnicode_Name_CAPI *ucnhash_capi = NULL; PyObject *PyCodec_NameReplaceErrors(PyObject *exc) { @@ -976,17 +976,18 @@ PyObject *PyCodec_NameReplaceErrors(PyObject *exc) return NULL; if (!(object = PyUnicodeEncodeError_GetObject(exc))) return NULL; - if (!ucnhash_CAPI) { + if (!ucnhash_capi) { /* load the unicode data module */ - ucnhash_CAPI = (_PyUnicode_Name_CAPI *)PyCapsule_Import( + ucnhash_capi = (_PyUnicode_Name_CAPI *)PyCapsule_Import( PyUnicodeData_CAPSULE_NAME, 1); - if (!ucnhash_CAPI) + if (!ucnhash_capi) { return NULL; + } } for (i = start, ressize = 0; i < end; ++i) { /* object is guaranteed to be "ready" */ c = PyUnicode_READ_CHAR(object, i); - if (ucnhash_CAPI->getname(NULL, c, buffer, sizeof(buffer), 1)) { + if (ucnhash_capi->getname(c, buffer, sizeof(buffer), 1)) { replsize = 1+1+1+(int)strlen(buffer)+1; } else if (c >= 0x10000) { @@ -1009,7 +1010,7 @@ PyObject *PyCodec_NameReplaceErrors(PyObject *exc) i < end; ++i) { c = PyUnicode_READ_CHAR(object, i); *outp++ = '\\'; - if (ucnhash_CAPI->getname(NULL, c, buffer, sizeof(buffer), 1)) { + if (ucnhash_capi->getname(c, buffer, sizeof(buffer), 1)) { *outp++ = 'N'; *outp++ = '{'; strcpy((char *)outp, buffer); diff --git a/contrib/tools/python3/src/Python/compile.c b/contrib/tools/python3/src/Python/compile.c index 28003b66bd4..f012406c066 100644 --- a/contrib/tools/python3/src/Python/compile.c +++ b/contrib/tools/python3/src/Python/compile.c @@ -1,7 +1,7 @@ /* * This file compiles an abstract syntax tree (AST) into Python bytecode. * - * The primary entry point is PyAST_Compile(), which returns a + * The primary entry point is _PyAST_Compile(), which returns a * PyCodeObject. The compiler makes several passes to build the code * object: * 1. Checks for future statements. See future.c @@ -9,7 +9,7 @@ * 3. Generate code for basic blocks. See compiler_mod() in this file. * 4. Assemble the basic blocks into final code. See assemble() in * this file. - * 5. Optimize the byte code (peephole optimizations). See peephole.c + * 5. Optimize the byte code (peephole optimizations). * * Note that compiler_mod() suggests module, but the module ast type * (mod_ty) has cases for expressions and interactive statements. @@ -21,14 +21,19 @@ * objects. */ +#include <stdbool.h> + #include "Python.h" +#include "pycore_ast.h" // _PyAST_GetDocString() +#include "pycore_compile.h" // _PyFuture_FromAST() +#include "pycore_pymem.h" // _PyMem_IsPtrFreed() +#include "pycore_long.h" // _PyLong_GetZero() +#include "pycore_symtable.h" // PySTEntryObject + +#define NEED_OPCODE_JUMP_TABLES +#include "opcode.h" // EXTENDED_ARG +#include "wordcode_helpers.h" // instrsize() -#include "Python-ast.h" -#include "ast.h" -#include "code.h" -#include "symtable.h" -#include "opcode.h" -#include "wordcode_helpers.h" #define DEFAULT_BLOCK_SIZE 16 #define DEFAULT_BLOCKS 8 @@ -40,19 +45,67 @@ #define COMP_SETCOMP 2 #define COMP_DICTCOMP 3 +/* A soft limit for stack use, to avoid excessive + * memory use for large constants, etc. + * + * The value 30 is plucked out of thin air. + * Code that could use more stack than this is + * rare, so the exact value is unimportant. + */ +#define STACK_USE_GUIDELINE 30 + +/* If we exceed this limit, it should + * be considered a compiler bug. + * Currently it should be impossible + * to exceed STACK_USE_GUIDELINE * 100, + * as 100 is the maximum parse depth. + * For performance reasons we will + * want to reduce this to a + * few hundred in the future. + * + * NOTE: Whatever MAX_ALLOWED_STACK_USE is + * set to, it should never restrict what Python + * we can write, just how we compile it. + */ +#define MAX_ALLOWED_STACK_USE (STACK_USE_GUIDELINE * 100) + #define IS_TOP_LEVEL_AWAIT(c) ( \ (c->c_flags->cf_flags & PyCF_ALLOW_TOP_LEVEL_AWAIT) \ && (c->u->u_ste->ste_type == ModuleBlock)) struct instr { - unsigned i_jabs : 1; - unsigned i_jrel : 1; unsigned char i_opcode; int i_oparg; struct basicblock_ *i_target; /* target block (if jump instruction) */ int i_lineno; }; +#define LOG_BITS_PER_INT 5 +#define MASK_LOW_LOG_BITS 31 + +static inline int +is_bit_set_in_table(uint32_t *table, int bitindex) { + /* Is the relevant bit set in the relevant word? */ + /* 256 bits fit into 8 32-bits words. + * Word is indexed by (bitindex>>ln(size of int in bits)). + * Bit within word is the low bits of bitindex. + */ + uint32_t word = table[bitindex >> LOG_BITS_PER_INT]; + return (word >> (bitindex & MASK_LOW_LOG_BITS)) & 1; +} + +static inline int +is_relative_jump(struct instr *i) +{ + return is_bit_set_in_table(_PyOpcode_RelativeJump, i->i_opcode); +} + +static inline int +is_jump(struct instr *i) +{ + return is_bit_set_in_table(_PyOpcode_Jump, i->i_opcode); +} + typedef struct basicblock_ { /* Each basicblock in a compilation unit is linked via b_list in the reverse order that the block are allocated. b_list points to the next @@ -67,10 +120,16 @@ typedef struct basicblock_ { /* If b_next is non-NULL, it is a pointer to the next block reached by normal control flow. */ struct basicblock_ *b_next; - /* b_seen is used to perform a DFS of basicblocks. */ - unsigned b_seen : 1; /* b_return is true if a RETURN_VALUE opcode is inserted. */ unsigned b_return : 1; + /* Number of predecssors that a block has. */ + int b_predecessors; + /* Basic block has no fall through (it ends with a return, raise or jump) */ + unsigned b_nofallthrough : 1; + /* Basic block exits scope (it ends with a return or raise) */ + unsigned b_exit : 1; + /* Used by compiler passes to mark whether they have visited a basic block. */ + unsigned b_visited : 1; /* depth of stack upon entry of block, computed by stackdepth() */ int b_startdepth; /* instruction offset for block, computed by assemble_jump_offsets() */ @@ -85,7 +144,8 @@ compiler IR. */ enum fblocktype { WHILE_LOOP, FOR_LOOP, TRY_EXCEPT, FINALLY_TRY, FINALLY_END, - WITH, ASYNC_WITH, HANDLER_CLEANUP, POP_VALUE, EXCEPTION_HANDLER }; + WITH, ASYNC_WITH, HANDLER_CLEANUP, POP_VALUE, EXCEPTION_HANDLER, + ASYNC_COMPREHENSION_GENERATOR }; struct fblockinfo { enum fblocktype fb_type; @@ -141,6 +201,8 @@ struct compiler_unit { int u_firstlineno; /* the first lineno of the block */ int u_lineno; /* the lineno for the current stmt */ int u_col_offset; /* the offset of the current stmt */ + int u_end_lineno; /* the end line of the current stmt */ + int u_end_col_offset; /* the end offset of the current stmt */ }; /* This struct captures the global state of a compilation. @@ -164,12 +226,6 @@ struct compiler { int c_optimize; /* optimization level */ int c_interactive; /* true if in interactive mode */ int c_nestlevel; - int c_do_not_emit_bytecode; /* The compiler won't emit any bytecode - if this value is different from zero. - This can be used to temporarily visit - nodes without emitting bytecode to - check only errors. */ - PyObject *c_const_cache; /* Python dict holding all constants, including names tuple */ struct compiler_unit *u; /* compiler state for current block */ @@ -177,14 +233,40 @@ struct compiler { PyArena *c_arena; /* pointer to memory allocation arena */ }; +typedef struct { + // A list of strings corresponding to name captures. It is used to track: + // - Repeated name assignments in the same pattern. + // - Different name assignments in alternatives. + // - The order of name assignments in alternatives. + PyObject *stores; + // If 0, any name captures against our subject will raise. + int allow_irrefutable; + // An array of blocks to jump to on failure. Jumping to fail_pop[i] will pop + // i items off of the stack. The end result looks like this (with each block + // falling through to the next): + // fail_pop[4]: POP_TOP + // fail_pop[3]: POP_TOP + // fail_pop[2]: POP_TOP + // fail_pop[1]: POP_TOP + // fail_pop[0]: NOP + basicblock **fail_pop; + // The current length of fail_pop. + Py_ssize_t fail_pop_size; + // The number of items on top of the stack that need to *stay* on top of the + // stack. Variable captures go beneath these. All of them will be popped on + // failure. + Py_ssize_t on_top; +} pattern_context; + static int compiler_enter_scope(struct compiler *, identifier, int, void *, int); static void compiler_free(struct compiler *); static basicblock *compiler_new_block(struct compiler *); static int compiler_next_instr(basicblock *); static int compiler_addop(struct compiler *, int); static int compiler_addop_i(struct compiler *, int, Py_ssize_t); -static int compiler_addop_j(struct compiler *, int, basicblock *, int); -static int compiler_error(struct compiler *, const char *); +static int compiler_addop_j(struct compiler *, int, basicblock *); +static int compiler_addop_j_noline(struct compiler *, int, basicblock *); +static int compiler_error(struct compiler *, const char *, ...); static int compiler_warn(struct compiler *, const char *, ...); static int compiler_nameop(struct compiler *, identifier, expr_context_ty); @@ -198,30 +280,35 @@ static int compiler_subscript(struct compiler *, expr_ty); static int compiler_slice(struct compiler *, expr_ty); static int inplace_binop(operator_ty); -static int are_all_items_const(asdl_seq *, Py_ssize_t, Py_ssize_t); -static int expr_constant(expr_ty); +static int are_all_items_const(asdl_expr_seq *, Py_ssize_t, Py_ssize_t); + static int compiler_with(struct compiler *, stmt_ty, int); static int compiler_async_with(struct compiler *, stmt_ty, int); static int compiler_async_for(struct compiler *, stmt_ty); static int compiler_call_helper(struct compiler *c, int n, - asdl_seq *args, - asdl_seq *keywords); + asdl_expr_seq *args, + asdl_keyword_seq *keywords); static int compiler_try_except(struct compiler *, stmt_ty); static int compiler_set_qualname(struct compiler *); static int compiler_sync_comprehension_generator( struct compiler *c, - asdl_seq *generators, int gen_index, + asdl_comprehension_seq *generators, int gen_index, int depth, expr_ty elt, expr_ty val, int type); static int compiler_async_comprehension_generator( struct compiler *c, - asdl_seq *generators, int gen_index, + asdl_comprehension_seq *generators, int gen_index, int depth, expr_ty elt, expr_ty val, int type); +static int compiler_pattern(struct compiler *, pattern_ty, pattern_context *); +static int compiler_match(struct compiler *, stmt_ty); +static int compiler_pattern_subpattern(struct compiler *, pattern_ty, + pattern_context *); + static PyCodeObject *assemble(struct compiler *, int addNone); static PyObject *__doc__, *__annotations__; @@ -315,8 +402,8 @@ compiler_init(struct compiler *c) } PyCodeObject * -PyAST_CompileObject(mod_ty mod, PyObject *filename, PyCompilerFlags *flags, - int optimize, PyArena *arena) +_PyAST_Compile(mod_ty mod, PyObject *filename, PyCompilerFlags *flags, + int optimize, PyArena *arena) { struct compiler c; PyCodeObject *co = NULL; @@ -338,7 +425,7 @@ PyAST_CompileObject(mod_ty mod, PyObject *filename, PyCompilerFlags *flags, Py_INCREF(filename); c.c_filename = filename; c.c_arena = arena; - c.c_future = PyFuture_FromASTObject(mod, filename); + c.c_future = _PyFuture_FromAST(mod, filename); if (c.c_future == NULL) goto finally; if (!flags) { @@ -350,7 +437,6 @@ PyAST_CompileObject(mod_ty mod, PyObject *filename, PyCompilerFlags *flags, c.c_flags = flags; c.c_optimize = (optimize == -1) ? _Py_GetConfig()->optimization_level : optimize; c.c_nestlevel = 0; - c.c_do_not_emit_bytecode = 0; _PyASTOptimizeState state; state.optimize = c.c_optimize; @@ -360,7 +446,7 @@ PyAST_CompileObject(mod_ty mod, PyObject *filename, PyCompilerFlags *flags, goto finally; } - c.c_st = PySymtable_BuildObject(mod, filename, c.c_future); + c.c_st = _PySymtable_Build(mod, filename, c.c_future); if (c.c_st == NULL) { if (!PyErr_Occurred()) PyErr_SetString(PyExc_SystemError, "no symtable"); @@ -375,41 +461,11 @@ PyAST_CompileObject(mod_ty mod, PyObject *filename, PyCompilerFlags *flags, return co; } -PyCodeObject * -PyAST_CompileEx(mod_ty mod, const char *filename_str, PyCompilerFlags *flags, - int optimize, PyArena *arena) -{ - PyObject *filename; - PyCodeObject *co; - filename = PyUnicode_DecodeFSDefault(filename_str); - if (filename == NULL) - return NULL; - co = PyAST_CompileObject(mod, filename, flags, optimize, arena); - Py_DECREF(filename); - return co; - -} - -PyCodeObject * -PyNode_Compile(struct _node *n, const char *filename) -{ - PyCodeObject *co = NULL; - mod_ty mod; - PyArena *arena = PyArena_New(); - if (!arena) - return NULL; - mod = PyAST_FromNode(n, NULL, filename, arena); - if (mod) - co = PyAST_Compile(mod, filename, NULL, arena); - PyArena_Free(arena); - return co; -} - static void compiler_free(struct compiler *c) { if (c->c_st) - PySymtable_Free(c->c_st); + _PySymtable_Free(c->c_st); if (c->c_future) PyObject_Free(c->c_future); Py_XDECREF(c->c_filename); @@ -480,8 +536,8 @@ dictbytype(PyObject *src, int scope_type, int flag, Py_ssize_t offset) /* XXX this should probably be a macro in symtable.h */ long vi; k = PyList_GET_ITEM(sorted_keys, key_i); - v = PyDict_GetItem(src, k); - assert(PyLong_Check(v)); + v = PyDict_GetItemWithError(src, k); + assert(v && PyLong_Check(v)); vi = PyLong_AS_LONG(v); scope = (vi >> SCOPE_OFFSET) & SCOPE_MASK; @@ -511,12 +567,10 @@ compiler_unit_check(struct compiler_unit *u) { basicblock *block; for (block = u->u_blocks; block != NULL; block = block->b_list) { - assert((uintptr_t)block != 0xcbcbcbcbU); - assert((uintptr_t)block != 0xfbfbfbfbU); - assert((uintptr_t)block != 0xdbdbdbdbU); + assert(!_PyMem_IsPtrFreed(block)); if (block->b_instr != NULL) { assert(block->b_ialloc > 0); - assert(block->b_iused > 0); + assert(block->b_iused >= 0); assert(block->b_ialloc >= block->b_iused); } else { @@ -594,7 +648,7 @@ compiler_enter_scope(struct compiler *c, identifier name, compiler_unit_free(u); return 0; } - res = PyDict_SetItem(u->u_cellvars, name, _PyLong_Zero); + res = PyDict_SetItem(u->u_cellvars, name, _PyLong_GetZero()); if (res < 0) { compiler_unit_free(u); return 0; @@ -613,6 +667,8 @@ compiler_enter_scope(struct compiler *c, identifier name, u->u_firstlineno = lineno; u->u_lineno = 0; u->u_col_offset = 0; + u->u_end_lineno = 0; + u->u_end_col_offset = 0; u->u_consts = PyDict_New(); if (!u->u_consts) { compiler_unit_free(u); @@ -658,25 +714,30 @@ compiler_enter_scope(struct compiler *c, identifier name, static void compiler_exit_scope(struct compiler *c) { - Py_ssize_t n; - PyObject *capsule; + // Don't call PySequence_DelItem() with an exception raised + PyObject *exc_type, *exc_val, *exc_tb; + PyErr_Fetch(&exc_type, &exc_val, &exc_tb); c->c_nestlevel--; compiler_unit_free(c->u); /* Restore c->u to the parent unit. */ - n = PyList_GET_SIZE(c->c_stack) - 1; + Py_ssize_t n = PyList_GET_SIZE(c->c_stack) - 1; if (n >= 0) { - capsule = PyList_GET_ITEM(c->c_stack, n); + PyObject *capsule = PyList_GET_ITEM(c->c_stack, n); c->u = (struct compiler_unit *)PyCapsule_GetPointer(capsule, CAPSULE_NAME); assert(c->u); /* we are deleting from a list so this really shouldn't fail */ - if (PySequence_DelItem(c->c_stack, n) < 0) - Py_FatalError("compiler_exit_scope()"); + if (PySequence_DelItem(c->c_stack, n) < 0) { + _PyErr_WriteUnraisableMsg("on removing the last compiler " + "stack item", NULL); + } compiler_unit_check(c->u); } - else + else { c->u = NULL; + } + PyErr_Restore(exc_type, exc_val, exc_tb); } static int @@ -707,7 +768,7 @@ compiler_set_qualname(struct compiler *c) mangled = _Py_Mangle(parent->u_private, u->u_name); if (!mangled) return 0; - scope = PyST_GetScope(parent->u_ste, mangled); + scope = _PyST_GetScope(parent->u_ste, mangled); Py_DECREF(mangled); assert(scope != GLOBAL_IMPLICIT); if (scope == GLOBAL_EXPLICIT) @@ -798,6 +859,29 @@ compiler_use_next_block(struct compiler *c, basicblock *block) return block; } +static basicblock * +compiler_copy_block(struct compiler *c, basicblock *block) +{ + /* Cannot copy a block if it has a fallthrough, since + * a block can only have one fallthrough predecessor. + */ + assert(block->b_nofallthrough); + basicblock *result = compiler_new_block(c); + if (result == NULL) { + return NULL; + } + for (int i = 0; i < block->b_iused; i++) { + int n = compiler_next_instr(result); + if (n < 0) { + return NULL; + } + result->b_instr[n] = block->b_instr[i]; + } + result->b_exit = block->b_exit; + result->b_nofallthrough = 1; + return result; +} + /* Returns the offset of the next instruction in the current block's b_instr array. Resizes the b_instr as necessary. Returns -1 on failure. @@ -855,7 +939,9 @@ compiler_next_instr(basicblock *b) #define SET_LOC(c, x) \ (c)->u->u_lineno = (x)->lineno; \ - (c)->u->u_col_offset = (x)->col_offset; + (c)->u->u_col_offset = (x)->col_offset; \ + (c)->u->u_end_lineno = (x)->end_lineno; \ + (c)->u->u_end_col_offset = (x)->end_col_offset; /* Return the stack effect of opcode with argument oparg. @@ -866,8 +952,6 @@ compiler_next_instr(basicblock *b) * 1 -- when jump * -1 -- maximal */ -/* XXX Make the stack effect of WITH_CLEANUP_START and - WITH_CLEANUP_FINISH deterministic. */ static int stack_effect(int opcode, int oparg, int jump) { @@ -1111,11 +1195,25 @@ stack_effect(int opcode, int oparg, int jump) return 1; case LIST_TO_TUPLE: return 0; + case GEN_START: + return -1; case LIST_EXTEND: case SET_UPDATE: case DICT_MERGE: case DICT_UPDATE: return -1; + case COPY_DICT_WITHOUT_KEYS: + return 0; + case MATCH_CLASS: + return -1; + case GET_LEN: + case MATCH_MAPPING: + case MATCH_SEQUENCE: + return 1; + case MATCH_KEYS: + return 2; + case ROT_N: + return 0; default: return PY_INVALID_STACK_EFFECT; } @@ -1139,15 +1237,12 @@ PyCompile_OpcodeStackEffect(int opcode, int oparg) */ static int -compiler_addop(struct compiler *c, int opcode) +compiler_addop_line(struct compiler *c, int opcode, int line) { basicblock *b; struct instr *i; int off; assert(!HAS_ARG(opcode)); - if (c->c_do_not_emit_bytecode) { - return 1; - } off = compiler_next_instr(c->u->u_curblock); if (off < 0) return 0; @@ -1157,10 +1252,23 @@ compiler_addop(struct compiler *c, int opcode) i->i_oparg = 0; if (opcode == RETURN_VALUE) b->b_return = 1; - i->i_lineno = c->u->u_lineno; + i->i_lineno = line; return 1; } +static int +compiler_addop(struct compiler *c, int opcode) +{ + return compiler_addop_line(c, opcode, c->u->u_lineno); +} + +static int +compiler_addop_noline(struct compiler *c, int opcode) +{ + return compiler_addop_line(c, opcode, -1); +} + + static Py_ssize_t compiler_add_o(PyObject *dict, PyObject *o) { @@ -1301,10 +1409,6 @@ merge_consts_recursive(struct compiler *c, PyObject *o) static Py_ssize_t compiler_add_const(struct compiler *c, PyObject *o) { - if (c->c_do_not_emit_bytecode) { - return 0; - } - PyObject *key = merge_consts_recursive(c, o); if (key == NULL) { return -1; @@ -1318,10 +1422,6 @@ compiler_add_const(struct compiler *c, PyObject *o) static int compiler_addop_load_const(struct compiler *c, PyObject *o) { - if (c->c_do_not_emit_bytecode) { - return 1; - } - Py_ssize_t arg = compiler_add_const(c, o); if (arg < 0) return 0; @@ -1332,10 +1432,6 @@ static int compiler_addop_o(struct compiler *c, int opcode, PyObject *dict, PyObject *o) { - if (c->c_do_not_emit_bytecode) { - return 1; - } - Py_ssize_t arg = compiler_add_o(dict, o); if (arg < 0) return 0; @@ -1348,10 +1444,6 @@ compiler_addop_name(struct compiler *c, int opcode, PyObject *dict, { Py_ssize_t arg; - if (c->c_do_not_emit_bytecode) { - return 1; - } - PyObject *mangled = _Py_Mangle(c->u->u_private, o); if (!mangled) return 0; @@ -1367,15 +1459,11 @@ compiler_addop_name(struct compiler *c, int opcode, PyObject *dict, */ static int -compiler_addop_i(struct compiler *c, int opcode, Py_ssize_t oparg) +compiler_addop_i_line(struct compiler *c, int opcode, Py_ssize_t oparg, int lineno) { struct instr *i; int off; - if (c->c_do_not_emit_bytecode) { - return 1; - } - /* oparg value is unsigned, but a signed C int is usually used to store it in the C code (like Python/ceval.c). @@ -1392,36 +1480,51 @@ compiler_addop_i(struct compiler *c, int opcode, Py_ssize_t oparg) i = &c->u->u_curblock->b_instr[off]; i->i_opcode = opcode; i->i_oparg = Py_SAFE_DOWNCAST(oparg, Py_ssize_t, int); - i->i_lineno = c->u->u_lineno; + i->i_lineno = lineno; return 1; } static int -compiler_addop_j(struct compiler *c, int opcode, basicblock *b, int absolute) +compiler_addop_i(struct compiler *c, int opcode, Py_ssize_t oparg) { - struct instr *i; - int off; + return compiler_addop_i_line(c, opcode, oparg, c->u->u_lineno); +} - if (c->c_do_not_emit_bytecode) { - return 1; - } +static int +compiler_addop_i_noline(struct compiler *c, int opcode, Py_ssize_t oparg) +{ + return compiler_addop_i_line(c, opcode, oparg, -1); +} +static int add_jump_to_block(basicblock *b, int opcode, int lineno, basicblock *target) +{ assert(HAS_ARG(opcode)); assert(b != NULL); - off = compiler_next_instr(c->u->u_curblock); - if (off < 0) + assert(target != NULL); + + int off = compiler_next_instr(b); + struct instr *i = &b->b_instr[off]; + if (off < 0) { return 0; - i = &c->u->u_curblock->b_instr[off]; + } i->i_opcode = opcode; - i->i_target = b; - if (absolute) - i->i_jabs = 1; - else - i->i_jrel = 1; - i->i_lineno = c->u->u_lineno; + i->i_target = target; + i->i_lineno = lineno; return 1; } +static int +compiler_addop_j(struct compiler *c, int opcode, basicblock *b) +{ + return add_jump_to_block(c->u->u_curblock, opcode, c->u->u_lineno, b); +} + +static int +compiler_addop_j_noline(struct compiler *c, int opcode, basicblock *b) +{ + return add_jump_to_block(c->u->u_curblock, opcode, -1, b); +} + /* NEXT_BLOCK() creates an implicit jump from the current block to the new block. @@ -1438,6 +1541,11 @@ compiler_addop_j(struct compiler *c, int opcode, basicblock *b, int absolute) return 0; \ } +#define ADDOP_NOLINE(C, OP) { \ + if (!compiler_addop_noline((C), (OP))) \ + return 0; \ +} + #define ADDOP_IN_SCOPE(C, OP) { \ if (!compiler_addop((C), (OP))) { \ compiler_exit_scope(c); \ @@ -1464,12 +1572,14 @@ compiler_addop_j(struct compiler *c, int opcode, basicblock *b, int absolute) } #define ADDOP_O(C, OP, O, TYPE) { \ + assert((OP) != LOAD_CONST); /* use ADDOP_LOAD_CONST */ \ if (!compiler_addop_o((C), (OP), (C)->u->u_ ## TYPE, (O))) \ return 0; \ } /* Same as ADDOP_O, but steals a reference. */ #define ADDOP_N(C, OP, O, TYPE) { \ + assert((OP) != LOAD_CONST); /* use ADDOP_LOAD_CONST_NEW */ \ if (!compiler_addop_o((C), (OP), (C)->u->u_ ## TYPE, (O))) { \ Py_DECREF((O)); \ return 0; \ @@ -1487,16 +1597,23 @@ compiler_addop_j(struct compiler *c, int opcode, basicblock *b, int absolute) return 0; \ } -#define ADDOP_JABS(C, OP, O) { \ - if (!compiler_addop_j((C), (OP), (O), 1)) \ +#define ADDOP_I_NOLINE(C, OP, O) { \ + if (!compiler_addop_i_noline((C), (OP), (O))) \ return 0; \ } -#define ADDOP_JREL(C, OP, O) { \ - if (!compiler_addop_j((C), (OP), (O), 0)) \ +#define ADDOP_JUMP(C, OP, O) { \ + if (!compiler_addop_j((C), (OP), (O))) \ return 0; \ } +/* Add a jump with no line number. + * Used for artificial jumps that have no corresponding + * token in the source code. */ +#define ADDOP_JUMP_NOLINE(C, OP, O) { \ + if (!compiler_addop_j_noline((C), (OP), (O))) \ + return 0; \ +} #define ADDOP_COMPARE(C, CMP) { \ if (!compiler_addcompare((C), (cmpop_ty)(CMP))) \ @@ -1526,7 +1643,7 @@ compiler_addop_j(struct compiler *c, int opcode, basicblock *b, int absolute) #define VISIT_SEQ(C, TYPE, SEQ) { \ int _i; \ - asdl_seq *seq = (SEQ); /* avoid variable capture */ \ + asdl_ ## TYPE ## _seq *seq = (SEQ); /* avoid variable capture */ \ for (_i = 0; _i < asdl_seq_LEN(seq); _i++) { \ TYPE ## _ty elt = (TYPE ## _ty)asdl_seq_GET(seq, _i); \ if (!compiler_visit_ ## TYPE((C), elt)) \ @@ -1536,7 +1653,7 @@ compiler_addop_j(struct compiler *c, int opcode, basicblock *b, int absolute) #define VISIT_SEQ_IN_SCOPE(C, TYPE, SEQ) { \ int _i; \ - asdl_seq *seq = (SEQ); /* avoid variable capture */ \ + asdl_ ## TYPE ## _seq *seq = (SEQ); /* avoid variable capture */ \ for (_i = 0; _i < asdl_seq_LEN(seq); _i++) { \ TYPE ## _ty elt = (TYPE ## _ty)asdl_seq_GET(seq, _i); \ if (!compiler_visit_ ## TYPE((C), elt)) { \ @@ -1546,21 +1663,15 @@ compiler_addop_j(struct compiler *c, int opcode, basicblock *b, int absolute) } \ } -/* These macros allows to check only for errors and not emmit bytecode - * while visiting nodes. -*/ - -#define BEGIN_DO_NOT_EMIT_BYTECODE { \ - c->c_do_not_emit_bytecode++; - -#define END_DO_NOT_EMIT_BYTECODE \ - c->c_do_not_emit_bytecode--; \ -} +#define RETURN_IF_FALSE(X) \ + if (!(X)) { \ + return 0; \ + } /* Search if variable annotations are present statically in a block. */ static int -find_ann(asdl_seq *stmts) +find_ann(asdl_stmt_seq *stmts) { int i, j, res = 0; stmt_ty st; @@ -1646,7 +1757,7 @@ compiler_pop_fblock(struct compiler *c, enum fblocktype t, basicblock *b) static int compiler_call_exit_with_nones(struct compiler *c) { - ADDOP_O(c, LOAD_CONST, Py_None, consts); + ADDOP_LOAD_CONST(c, Py_None); ADDOP(c, DUP_TOP); ADDOP(c, DUP_TOP); ADDOP_I(c, CALL_FUNCTION, 3); @@ -1665,6 +1776,7 @@ compiler_unwind_fblock(struct compiler *c, struct fblockinfo *info, switch (info->fb_type) { case WHILE_LOOP: case EXCEPTION_HANDLER: + case ASYNC_COMPREHENSION_GENERATOR: return 1; case FOR_LOOP: @@ -1680,19 +1792,22 @@ compiler_unwind_fblock(struct compiler *c, struct fblockinfo *info, return 1; case FINALLY_TRY: + /* This POP_BLOCK gets the line number of the unwinding statement */ ADDOP(c, POP_BLOCK); if (preserve_tos) { if (!compiler_push_fblock(c, POP_VALUE, NULL, NULL, NULL)) { return 0; } } - /* Emit the finally block, restoring the line number when done */ - int saved_lineno = c->u->u_lineno; + /* Emit the finally block */ VISIT_SEQ(c, stmt, info->fb_datum); - c->u->u_lineno = saved_lineno; if (preserve_tos) { compiler_pop_fblock(c, POP_VALUE, NULL); } + /* The finally block should appear to execute after the + * statement causing the unwinding, so make the unwinding + * instruction artificial */ + c->u->u_lineno = -1; return 1; case FINALLY_END: @@ -1710,6 +1825,7 @@ compiler_unwind_fblock(struct compiler *c, struct fblockinfo *info, case WITH: case ASYNC_WITH: + SET_LOC(c, (stmt_ty)info->fb_datum); ADDOP(c, POP_BLOCK); if (preserve_tos) { ADDOP(c, ROT_TWO); @@ -1723,6 +1839,10 @@ compiler_unwind_fblock(struct compiler *c, struct fblockinfo *info, ADDOP(c, YIELD_FROM); } ADDOP(c, POP_TOP); + /* The exit block should appear to execute after the + * statement causing the unwinding, so make the unwinding + * instruction artificial */ + c->u->u_lineno = -1; return 1; case HANDLER_CLEANUP: @@ -1778,7 +1898,7 @@ compiler_unwind_fblock_stack(struct compiler *c, int preserve_tos, struct fblock and for annotations. */ static int -compiler_body(struct compiler *c, asdl_seq *stmts) +compiler_body(struct compiler *c, asdl_stmt_seq *stmts) { int i = 0; stmt_ty st; @@ -1827,7 +1947,7 @@ compiler_mod(struct compiler *c, mod_ty mod) return NULL; } /* Use 0 for firstlineno initially, will fixup in assemble(). */ - if (!compiler_enter_scope(c, module, COMPILER_SCOPE_MODULE, mod, 0)) + if (!compiler_enter_scope(c, module, COMPILER_SCOPE_MODULE, mod, 1)) return NULL; switch (mod->kind) { case Module_kind: @@ -1841,8 +1961,7 @@ compiler_mod(struct compiler *c, mod_ty mod) ADDOP(c, SETUP_ANNOTATIONS); } c->c_interactive = 1; - VISIT_SEQ_IN_SCOPE(c, stmt, - mod->v.Interactive.body); + VISIT_SEQ_IN_SCOPE(c, stmt, mod->v.Interactive.body); break; case Expression_kind: VISIT_IN_SCOPE(c, expr, mod->v.Expression.body); @@ -1871,19 +1990,17 @@ get_ref_type(struct compiler *c, PyObject *name) if (c->u->u_scope_type == COMPILER_SCOPE_CLASS && _PyUnicode_EqualToASCIIString(name, "__class__")) return CELL; - scope = PyST_GetScope(c->u->u_ste, name); + scope = _PyST_GetScope(c->u->u_ste, name); if (scope == 0) { - _Py_FatalErrorFormat(__func__, - "unknown scope for %.100s in %.100s(%s)\n" - "symbols: %s\nlocals: %s\nglobals: %s", - PyUnicode_AsUTF8(name), - PyUnicode_AsUTF8(c->u->u_name), - PyUnicode_AsUTF8(PyObject_Repr(c->u->u_ste->ste_id)), - PyUnicode_AsUTF8(PyObject_Repr(c->u->u_ste->ste_symbols)), - PyUnicode_AsUTF8(PyObject_Repr(c->u->u_varnames)), - PyUnicode_AsUTF8(PyObject_Repr(c->u->u_names))); + PyErr_Format(PyExc_SystemError, + "_PyST_GetScope(name=%R) failed: " + "unknown scope in unit %S (%R); " + "symbols: %R; locals: %R; globals: %R", + name, + c->u->u_name, c->u->u_ste->ste_id, + c->u->u_ste->ste_symbols, c->u->u_varnames, c->u->u_names); + return -1; } - return scope; } @@ -1891,14 +2008,15 @@ static int compiler_lookup_arg(PyObject *dict, PyObject *name) { PyObject *v; - v = PyDict_GetItem(dict, name); + v = PyDict_GetItemWithError(dict, name); if (v == NULL) return -1; return PyLong_AS_LONG(v); } static int -compiler_make_closure(struct compiler *c, PyCodeObject *co, Py_ssize_t flags, PyObject *qualname) +compiler_make_closure(struct compiler *c, PyCodeObject *co, Py_ssize_t flags, + PyObject *qualname) { Py_ssize_t i, free = PyCode_GetNumFree(co); if (qualname == NULL) @@ -1910,7 +2028,6 @@ compiler_make_closure(struct compiler *c, PyCodeObject *co, Py_ssize_t flags, Py LOAD_DEREF but LOAD_CLOSURE is needed. */ PyObject *name = PyTuple_GET_ITEM(co->co_freevars, i); - int arg, reftype; /* Special case: If a class contains a method with a free variable that has the same name as a method, @@ -1918,20 +2035,27 @@ compiler_make_closure(struct compiler *c, PyCodeObject *co, Py_ssize_t flags, Py class. It should be handled by the closure, as well as by the normal name lookup logic. */ - reftype = get_ref_type(c, name); - if (reftype == CELL) + int reftype = get_ref_type(c, name); + if (reftype == -1) { + return 0; + } + int arg; + if (reftype == CELL) { arg = compiler_lookup_arg(c->u->u_cellvars, name); - else /* (reftype == FREE) */ + } + else { arg = compiler_lookup_arg(c->u->u_freevars, name); + } if (arg == -1) { - _Py_FatalErrorFormat(__func__, - "lookup %s in %s %d %d\n" - "freevars of %s: %s\n", - PyUnicode_AsUTF8(PyObject_Repr(name)), - PyUnicode_AsUTF8(c->u->u_name), - reftype, arg, - PyUnicode_AsUTF8(co->co_name), - PyUnicode_AsUTF8(PyObject_Repr(co->co_freevars))); + PyErr_Format(PyExc_SystemError, + "compiler_lookup_arg(name=%R) with reftype=%d failed in %S; " + "freevars of code %S: %R", + name, + reftype, + c->u->u_name, + co->co_name, + co->co_freevars); + return 0; } ADDOP_I(c, LOAD_CLOSURE, arg); } @@ -1945,7 +2069,7 @@ compiler_make_closure(struct compiler *c, PyCodeObject *co, Py_ssize_t flags, Py } static int -compiler_decorators(struct compiler *c, asdl_seq* decos) +compiler_decorators(struct compiler *c, asdl_expr_seq* decos) { int i; @@ -1959,8 +2083,8 @@ compiler_decorators(struct compiler *c, asdl_seq* decos) } static int -compiler_visit_kwonlydefaults(struct compiler *c, asdl_seq *kwonlyargs, - asdl_seq *kw_defaults) +compiler_visit_kwonlydefaults(struct compiler *c, asdl_arg_seq *kwonlyargs, + asdl_expr_seq *kw_defaults) { /* Push a dict of keyword-only default values. @@ -2024,31 +2148,32 @@ compiler_visit_annexpr(struct compiler *c, expr_ty annotation) static int compiler_visit_argannotation(struct compiler *c, identifier id, - expr_ty annotation, PyObject *names) + expr_ty annotation, Py_ssize_t *annotations_len) { - if (annotation) { - PyObject *mangled; - if (c->c_future->ff_features & CO_FUTURE_ANNOTATIONS) { - VISIT(c, annexpr, annotation) - } - else { - VISIT(c, expr, annotation); - } - mangled = _Py_Mangle(c->u->u_private, id); - if (!mangled) - return 0; - if (PyList_Append(names, mangled) < 0) { - Py_DECREF(mangled); - return 0; - } - Py_DECREF(mangled); + if (!annotation) { + return 1; } + + PyObject *mangled = _Py_Mangle(c->u->u_private, id); + if (!mangled) { + return 0; + } + ADDOP_LOAD_CONST(c, mangled); + Py_DECREF(mangled); + + if (c->c_future->ff_features & CO_FUTURE_ANNOTATIONS) { + VISIT(c, annexpr, annotation) + } + else { + VISIT(c, expr, annotation); + } + *annotations_len += 2; return 1; } static int -compiler_visit_argannotations(struct compiler *c, asdl_seq* args, - PyObject *names) +compiler_visit_argannotations(struct compiler *c, asdl_arg_seq* args, + Py_ssize_t *annotations_len) { int i; for (i = 0; i < asdl_seq_LEN(args); i++) { @@ -2057,7 +2182,7 @@ compiler_visit_argannotations(struct compiler *c, asdl_seq* args, c, arg->arg, arg->annotation, - names)) + annotations_len)) return 0; } return 1; @@ -2067,58 +2192,44 @@ static int compiler_visit_annotations(struct compiler *c, arguments_ty args, expr_ty returns) { - /* Push arg annotation dict. + /* Push arg annotation names and values. The expressions are evaluated out-of-order wrt the source code. - Return 0 on error, -1 if no dict pushed, 1 if a dict is pushed. + Return 0 on error, -1 if no annotations pushed, 1 if a annotations is pushed. */ static identifier return_str; - PyObject *names; - Py_ssize_t len; - names = PyList_New(0); - if (!names) - return 0; + Py_ssize_t annotations_len = 0; - if (!compiler_visit_argannotations(c, args->args, names)) - goto error; - if (!compiler_visit_argannotations(c, args->posonlyargs, names)) - goto error; + if (!compiler_visit_argannotations(c, args->args, &annotations_len)) + return 0; + if (!compiler_visit_argannotations(c, args->posonlyargs, &annotations_len)) + return 0; if (args->vararg && args->vararg->annotation && !compiler_visit_argannotation(c, args->vararg->arg, - args->vararg->annotation, names)) - goto error; - if (!compiler_visit_argannotations(c, args->kwonlyargs, names)) - goto error; + args->vararg->annotation, &annotations_len)) + return 0; + if (!compiler_visit_argannotations(c, args->kwonlyargs, &annotations_len)) + return 0; if (args->kwarg && args->kwarg->annotation && !compiler_visit_argannotation(c, args->kwarg->arg, - args->kwarg->annotation, names)) - goto error; + args->kwarg->annotation, &annotations_len)) + return 0; if (!return_str) { return_str = PyUnicode_InternFromString("return"); if (!return_str) - goto error; + return 0; } - if (!compiler_visit_argannotation(c, return_str, returns, names)) { - goto error; + if (!compiler_visit_argannotation(c, return_str, returns, &annotations_len)) { + return 0; } - len = PyList_GET_SIZE(names); - if (len) { - PyObject *keytuple = PyList_AsTuple(names); - Py_DECREF(names); - ADDOP_LOAD_CONST_NEW(c, keytuple); - ADDOP_I(c, BUILD_CONST_KEY_MAP, len); + if (annotations_len) { + ADDOP_I(c, BUILD_TUPLE, annotations_len); return 1; } - else { - Py_DECREF(names); - return -1; - } -error: - Py_DECREF(names); - return 0; + return -1; } static int @@ -2159,6 +2270,10 @@ forbidden_name(struct compiler *c, identifier name, expr_context_ty ctx) compiler_error(c, "cannot assign to __debug__"); return 1; } + if (ctx == Del && _PyUnicode_EqualToASCIIString(name, "__debug__")) { + compiler_error(c, "cannot delete __debug__"); + return 1; + } return 0; } @@ -2173,7 +2288,7 @@ compiler_check_debug_one_arg(struct compiler *c, arg_ty arg) } static int -compiler_check_debug_args_seq(struct compiler *c, asdl_seq *args) +compiler_check_debug_args_seq(struct compiler *c, asdl_arg_seq *args) { if (args != NULL) { for (Py_ssize_t i = 0, n = asdl_seq_LEN(args); i < n; i++) { @@ -2208,8 +2323,8 @@ compiler_function(struct compiler *c, stmt_ty s, int is_async) arguments_ty args; expr_ty returns; identifier name; - asdl_seq* decos; - asdl_seq *body; + asdl_expr_seq* decos; + asdl_stmt_seq *body; Py_ssize_t i, funcflags; int annotations; int scope_type; @@ -2277,7 +2392,9 @@ compiler_function(struct compiler *c, stmt_ty s, int is_async) c->u->u_argcount = asdl_seq_LEN(args->args); c->u->u_posonlyargcount = asdl_seq_LEN(args->posonlyargs); c->u->u_kwonlyargcount = asdl_seq_LEN(args->kwonlyargs); - VISIT_SEQ_IN_SCOPE(c, stmt, body); + for (i = docstring ? 1 : 0; i < asdl_seq_LEN(body); i++) { + VISIT_IN_SCOPE(c, stmt, (stmt_ty)asdl_seq_GET(body, i)); + } co = assemble(c, 1); qualname = c->u->u_qualname; Py_INCREF(qualname); @@ -2288,7 +2405,11 @@ compiler_function(struct compiler *c, stmt_ty s, int is_async) return 0; } - compiler_make_closure(c, co, funcflags, qualname); + if (!compiler_make_closure(c, co, funcflags, qualname)) { + Py_DECREF(qualname); + Py_DECREF(co); + return 0; + } Py_DECREF(qualname); Py_DECREF(co); @@ -2306,7 +2427,7 @@ compiler_class(struct compiler *c, stmt_ty s) PyCodeObject *co; PyObject *str; int i, firstlineno; - asdl_seq* decos = s->v.ClassDef.decorator_list; + asdl_expr_seq *decos = s->v.ClassDef.decorator_list; if (!compiler_decorators(c, decos)) return 0; @@ -2366,6 +2487,8 @@ compiler_class(struct compiler *c, stmt_ty s) compiler_exit_scope(c); return 0; } + /* The following code is artificial */ + c->u->u_lineno = -1; /* Return __classcell__ if it is referenced, otherwise return None */ if (c->u->u_ste->ste_needs_class_closure) { /* Store __classcell__ into class namespace & return it */ @@ -2410,16 +2533,17 @@ compiler_class(struct compiler *c, stmt_ty s) ADDOP(c, LOAD_BUILD_CLASS); /* 3. load a function (or closure) made from the code object */ - compiler_make_closure(c, co, 0, NULL); + if (!compiler_make_closure(c, co, 0, NULL)) { + Py_DECREF(co); + return 0; + } Py_DECREF(co); /* 4. load class name */ ADDOP_LOAD_CONST(c, s->v.ClassDef.name); /* 5. generate the rest of the code for the call */ - if (!compiler_call_helper(c, 2, - s->v.ClassDef.bases, - s->v.ClassDef.keywords)) + if (!compiler_call_helper(c, 2, s->v.ClassDef.bases, s->v.ClassDef.keywords)) return 0; /* 6. apply decorators */ @@ -2527,7 +2651,7 @@ compiler_jump_if(struct compiler *c, expr_ty e, basicblock *next, int cond) /* fallback to general implementation */ break; case BoolOp_kind: { - asdl_seq *s = e->v.BoolOp.values; + asdl_expr_seq *s = e->v.BoolOp.values; Py_ssize_t i, n = asdl_seq_LEN(s) - 1; assert(n >= 0); int cond2 = e->v.BoolOp.op == Or; @@ -2559,7 +2683,7 @@ compiler_jump_if(struct compiler *c, expr_ty e, basicblock *next, int cond) return 0; if (!compiler_jump_if(c, e->v.IfExp.body, next, cond)) return 0; - ADDOP_JREL(c, JUMP_FORWARD, end); + ADDOP_JUMP_NOLINE(c, JUMP_FORWARD, end); compiler_use_next_block(c, next2); if (!compiler_jump_if(c, e->v.IfExp.orelse, next, cond)) return 0; @@ -2582,20 +2706,21 @@ compiler_jump_if(struct compiler *c, expr_ty e, basicblock *next, int cond) ADDOP(c, DUP_TOP); ADDOP(c, ROT_THREE); ADDOP_COMPARE(c, asdl_seq_GET(e->v.Compare.ops, i)); - ADDOP_JABS(c, POP_JUMP_IF_FALSE, cleanup); + ADDOP_JUMP(c, POP_JUMP_IF_FALSE, cleanup); NEXT_BLOCK(c); } VISIT(c, expr, (expr_ty)asdl_seq_GET(e->v.Compare.comparators, n)); ADDOP_COMPARE(c, asdl_seq_GET(e->v.Compare.ops, n)); - ADDOP_JABS(c, cond ? POP_JUMP_IF_TRUE : POP_JUMP_IF_FALSE, next); + ADDOP_JUMP(c, cond ? POP_JUMP_IF_TRUE : POP_JUMP_IF_FALSE, next); + NEXT_BLOCK(c); basicblock *end = compiler_new_block(c); if (end == NULL) return 0; - ADDOP_JREL(c, JUMP_FORWARD, end); + ADDOP_JUMP_NOLINE(c, JUMP_FORWARD, end); compiler_use_next_block(c, cleanup); ADDOP(c, POP_TOP); if (!cond) { - ADDOP_JREL(c, JUMP_FORWARD, next); + ADDOP_JUMP_NOLINE(c, JUMP_FORWARD, next); } compiler_use_next_block(c, end); return 1; @@ -2610,7 +2735,8 @@ compiler_jump_if(struct compiler *c, expr_ty e, basicblock *next, int cond) /* general implementation */ VISIT(c, expr, e); - ADDOP_JABS(c, cond ? POP_JUMP_IF_TRUE : POP_JUMP_IF_FALSE, next); + ADDOP_JUMP(c, cond ? POP_JUMP_IF_TRUE : POP_JUMP_IF_FALSE, next); + NEXT_BLOCK(c); return 1; } @@ -2629,7 +2755,7 @@ compiler_ifexp(struct compiler *c, expr_ty e) if (!compiler_jump_if(c, e->v.IfExp.test, next, 0)) return 0; VISIT(c, expr, e->v.IfExp.body); - ADDOP_JREL(c, JUMP_FORWARD, end); + ADDOP_JUMP_NOLINE(c, JUMP_FORWARD, end); compiler_use_next_block(c, next); VISIT(c, expr, e->v.IfExp.orelse); compiler_use_next_block(c, end); @@ -2683,10 +2809,16 @@ compiler_lambda(struct compiler *c, expr_ty e) qualname = c->u->u_qualname; Py_INCREF(qualname); compiler_exit_scope(c); - if (co == NULL) + if (co == NULL) { + Py_DECREF(qualname); return 0; + } - compiler_make_closure(c, co, funcflags, qualname); + if (!compiler_make_closure(c, co, funcflags, qualname)) { + Py_DECREF(qualname); + Py_DECREF(co); + return 0; + } Py_DECREF(qualname); Py_DECREF(co); @@ -2697,48 +2829,28 @@ static int compiler_if(struct compiler *c, stmt_ty s) { basicblock *end, *next; - int constant; assert(s->kind == If_kind); end = compiler_new_block(c); - if (end == NULL) + if (end == NULL) { return 0; - - constant = expr_constant(s->v.If.test); - /* constant = 0: "if 0" - * constant = 1: "if 1", "if 2", ... - * constant = -1: rest */ - if (constant == 0) { - BEGIN_DO_NOT_EMIT_BYTECODE - VISIT_SEQ(c, stmt, s->v.If.body); - END_DO_NOT_EMIT_BYTECODE - if (s->v.If.orelse) { - VISIT_SEQ(c, stmt, s->v.If.orelse); - } - } else if (constant == 1) { - VISIT_SEQ(c, stmt, s->v.If.body); - if (s->v.If.orelse) { - BEGIN_DO_NOT_EMIT_BYTECODE - VISIT_SEQ(c, stmt, s->v.If.orelse); - END_DO_NOT_EMIT_BYTECODE - } - } else { - if (asdl_seq_LEN(s->v.If.orelse)) { - next = compiler_new_block(c); - if (next == NULL) - return 0; - } - else { - next = end; - } - if (!compiler_jump_if(c, s->v.If.test, next, 0)) { + } + if (asdl_seq_LEN(s->v.If.orelse)) { + next = compiler_new_block(c); + if (next == NULL) { return 0; } - VISIT_SEQ(c, stmt, s->v.If.body); - if (asdl_seq_LEN(s->v.If.orelse)) { - ADDOP_JREL(c, JUMP_FORWARD, end); - compiler_use_next_block(c, next); - VISIT_SEQ(c, stmt, s->v.If.orelse); - } + } + else { + next = end; + } + if (!compiler_jump_if(c, s->v.If.test, next, 0)) { + return 0; + } + VISIT_SEQ(c, stmt, s->v.If.body); + if (asdl_seq_LEN(s->v.If.orelse)) { + ADDOP_JUMP_NOLINE(c, JUMP_FORWARD, end); + compiler_use_next_block(c, next); + VISIT_SEQ(c, stmt, s->v.If.orelse); } compiler_use_next_block(c, end); return 1; @@ -2747,12 +2859,13 @@ compiler_if(struct compiler *c, stmt_ty s) static int compiler_for(struct compiler *c, stmt_ty s) { - basicblock *start, *cleanup, *end; + basicblock *start, *body, *cleanup, *end; start = compiler_new_block(c); + body = compiler_new_block(c); cleanup = compiler_new_block(c); end = compiler_new_block(c); - if (start == NULL || end == NULL || cleanup == NULL) { + if (start == NULL || body == NULL || end == NULL || cleanup == NULL) { return 0; } if (!compiler_push_fblock(c, FOR_LOOP, start, end, NULL)) { @@ -2761,10 +2874,13 @@ compiler_for(struct compiler *c, stmt_ty s) VISIT(c, expr, s->v.For.iter); ADDOP(c, GET_ITER); compiler_use_next_block(c, start); - ADDOP_JREL(c, FOR_ITER, cleanup); + ADDOP_JUMP(c, FOR_ITER, cleanup); + compiler_use_next_block(c, body); VISIT(c, expr, s->v.For.target); VISIT_SEQ(c, stmt, s->v.For.body); - ADDOP_JABS(c, JUMP_ABSOLUTE, start); + /* Mark jump as artificial */ + c->u->u_lineno = -1; + ADDOP_JUMP(c, JUMP_ABSOLUTE, start); compiler_use_next_block(c, cleanup); compiler_pop_fblock(c, FOR_LOOP, start); @@ -2800,7 +2916,7 @@ compiler_async_for(struct compiler *c, stmt_ty s) return 0; } /* SETUP_FINALLY to guard the __anext__ call */ - ADDOP_JREL(c, SETUP_FINALLY, except); + ADDOP_JUMP(c, SETUP_FINALLY, except); ADDOP(c, GET_ANEXT); ADDOP_LOAD_CONST(c, Py_None); ADDOP(c, YIELD_FROM); @@ -2809,18 +2925,16 @@ compiler_async_for(struct compiler *c, stmt_ty s) /* Success block for __anext__ */ VISIT(c, expr, s->v.AsyncFor.target); VISIT_SEQ(c, stmt, s->v.AsyncFor.body); - ADDOP_JABS(c, JUMP_ABSOLUTE, start); + ADDOP_JUMP(c, JUMP_ABSOLUTE, start); compiler_pop_fblock(c, FOR_LOOP, start); /* Except block for __anext__ */ compiler_use_next_block(c, except); - /* We don't want to trace the END_ASYNC_FOR, so make sure - * that it has the same lineno as the following instruction. */ - if (asdl_seq_LEN(s->v.For.orelse)) { - SET_LOC(c, (stmt_ty)asdl_seq_GET(s->v.For.orelse, 0)); - } + /* Use same line number as the iterator, + * as the END_ASYNC_FOR succeeds the `for`, not the body. */ + SET_LOC(c, s->v.AsyncFor.iter); ADDOP(c, END_ASYNC_FOR); /* `else` block */ @@ -2834,63 +2948,35 @@ compiler_async_for(struct compiler *c, stmt_ty s) static int compiler_while(struct compiler *c, stmt_ty s) { - basicblock *loop, *orelse, *end, *anchor = NULL; - int constant = expr_constant(s->v.While.test); - - if (constant == 0) { - BEGIN_DO_NOT_EMIT_BYTECODE - // Push a dummy block so the VISIT_SEQ knows that we are - // inside a while loop so it can correctly evaluate syntax - // errors. - if (!compiler_push_fblock(c, WHILE_LOOP, NULL, NULL, NULL)) { - return 0; - } - VISIT_SEQ(c, stmt, s->v.While.body); - // Remove the dummy block now that is not needed. - compiler_pop_fblock(c, WHILE_LOOP, NULL); - END_DO_NOT_EMIT_BYTECODE - if (s->v.While.orelse) { - VISIT_SEQ(c, stmt, s->v.While.orelse); - } - return 1; - } + basicblock *loop, *body, *end, *anchor = NULL; loop = compiler_new_block(c); + body = compiler_new_block(c); + anchor = compiler_new_block(c); end = compiler_new_block(c); - if (constant == -1) { - anchor = compiler_new_block(c); - if (anchor == NULL) - return 0; - } - if (loop == NULL || end == NULL) + if (loop == NULL || body == NULL || anchor == NULL || end == NULL) { return 0; - if (s->v.While.orelse) { - orelse = compiler_new_block(c); - if (orelse == NULL) - return 0; } - else - orelse = NULL; - compiler_use_next_block(c, loop); - if (!compiler_push_fblock(c, WHILE_LOOP, loop, end, NULL)) + if (!compiler_push_fblock(c, WHILE_LOOP, loop, end, NULL)) { + return 0; + } + if (!compiler_jump_if(c, s->v.While.test, anchor, 0)) { return 0; - if (constant == -1) { - if (!compiler_jump_if(c, s->v.While.test, anchor, 0)) - return 0; } - VISIT_SEQ(c, stmt, s->v.While.body); - ADDOP_JABS(c, JUMP_ABSOLUTE, loop); - /* XXX should the two POP instructions be in a separate block - if there is no else clause ? - */ + compiler_use_next_block(c, body); + VISIT_SEQ(c, stmt, s->v.While.body); + SET_LOC(c, s); + if (!compiler_jump_if(c, s->v.While.test, body, 1)) { + return 0; + } - if (constant == -1) - compiler_use_next_block(c, anchor); compiler_pop_fblock(c, WHILE_LOOP, loop); - if (orelse != NULL) /* what if orelse is just pass? */ + compiler_use_next_block(c, anchor); + if (s->v.While.orelse) { VISIT_SEQ(c, stmt, s->v.While.orelse); + } compiler_use_next_block(c, end); return 1; @@ -2911,16 +2997,28 @@ compiler_return(struct compiler *c, stmt_ty s) } if (preserve_tos) { VISIT(c, expr, s->v.Return.value); + } else { + /* Emit instruction with line number for return value */ + if (s->v.Return.value != NULL) { + SET_LOC(c, s->v.Return.value); + ADDOP(c, NOP); + } + } + if (s->v.Return.value == NULL || s->v.Return.value->lineno != s->lineno) { + SET_LOC(c, s); + ADDOP(c, NOP); } + if (!compiler_unwind_fblock_stack(c, preserve_tos, NULL)) return 0; if (s->v.Return.value == NULL) { ADDOP_LOAD_CONST(c, Py_None); } else if (!preserve_tos) { - VISIT(c, expr, s->v.Return.value); + ADDOP_LOAD_CONST(c, s->v.Return.value->v.Constant.value); } ADDOP(c, RETURN_VALUE); + NEXT_BLOCK(c); return 1; } @@ -2929,6 +3027,8 @@ static int compiler_break(struct compiler *c) { struct fblockinfo *loop = NULL; + /* Emit instruction with line number */ + ADDOP(c, NOP); if (!compiler_unwind_fblock_stack(c, 0, &loop)) { return 0; } @@ -2938,7 +3038,8 @@ compiler_break(struct compiler *c) if (!compiler_unwind_fblock(c, loop, 0)) { return 0; } - ADDOP_JABS(c, JUMP_ABSOLUTE, loop->fb_exit); + ADDOP_JUMP(c, JUMP_ABSOLUTE, loop->fb_exit); + NEXT_BLOCK(c); return 1; } @@ -2946,13 +3047,16 @@ static int compiler_continue(struct compiler *c) { struct fblockinfo *loop = NULL; + /* Emit instruction with line number */ + ADDOP(c, NOP); if (!compiler_unwind_fblock_stack(c, 0, &loop)) { return 0; } if (loop == NULL) { return compiler_error(c, "'continue' not properly in loop"); } - ADDOP_JABS(c, JUMP_ABSOLUTE, loop->fb_block); + ADDOP_JUMP(c, JUMP_ABSOLUTE, loop->fb_block); + NEXT_BLOCK(c) return 1; } @@ -2998,7 +3102,7 @@ compiler_try_finally(struct compiler *c, stmt_ty s) return 0; /* `try` block */ - ADDOP_JREL(c, SETUP_FINALLY, end); + ADDOP_JUMP(c, SETUP_FINALLY, end); compiler_use_next_block(c, body); if (!compiler_push_fblock(c, FINALLY_TRY, body, end, s->v.Try.finalbody)) return 0; @@ -3009,17 +3113,17 @@ compiler_try_finally(struct compiler *c, stmt_ty s) else { VISIT_SEQ(c, stmt, s->v.Try.body); } - ADDOP(c, POP_BLOCK); + ADDOP_NOLINE(c, POP_BLOCK); compiler_pop_fblock(c, FINALLY_TRY, body); VISIT_SEQ(c, stmt, s->v.Try.finalbody); - ADDOP_JREL(c, JUMP_FORWARD, exit); + ADDOP_JUMP_NOLINE(c, JUMP_FORWARD, exit); /* `finally` block */ compiler_use_next_block(c, end); if (!compiler_push_fblock(c, FINALLY_END, end, NULL, NULL)) return 0; VISIT_SEQ(c, stmt, s->v.Try.finalbody); compiler_pop_fblock(c, FINALLY_END, end); - ADDOP(c, RERAISE); + ADDOP_I(c, RERAISE, 0); compiler_use_next_block(c, exit); return 1; } @@ -3066,14 +3170,14 @@ compiler_try_except(struct compiler *c, stmt_ty s) end = compiler_new_block(c); if (body == NULL || except == NULL || orelse == NULL || end == NULL) return 0; - ADDOP_JREL(c, SETUP_FINALLY, except); + ADDOP_JUMP(c, SETUP_FINALLY, except); compiler_use_next_block(c, body); if (!compiler_push_fblock(c, TRY_EXCEPT, body, NULL, NULL)) return 0; VISIT_SEQ(c, stmt, s->v.Try.body); - ADDOP(c, POP_BLOCK); compiler_pop_fblock(c, TRY_EXCEPT, body); - ADDOP_JREL(c, JUMP_FORWARD, orelse); + ADDOP_NOLINE(c, POP_BLOCK); + ADDOP_JUMP_NOLINE(c, JUMP_FORWARD, orelse); n = asdl_seq_LEN(s->v.Try.handlers); compiler_use_next_block(c, except); /* Runtime will push a block here, so we need to account for that */ @@ -3082,16 +3186,17 @@ compiler_try_except(struct compiler *c, stmt_ty s) for (i = 0; i < n; i++) { excepthandler_ty handler = (excepthandler_ty)asdl_seq_GET( s->v.Try.handlers, i); + SET_LOC(c, handler); if (!handler->v.ExceptHandler.type && i < n-1) return compiler_error(c, "default 'except:' must be last"); - SET_LOC(c, handler); except = compiler_new_block(c); if (except == NULL) return 0; if (handler->v.ExceptHandler.type) { ADDOP(c, DUP_TOP); VISIT(c, expr, handler->v.ExceptHandler.type); - ADDOP_JABS(c, JUMP_IF_NOT_EXC_MATCH, except); + ADDOP_JUMP(c, JUMP_IF_NOT_EXC_MATCH, except); + NEXT_BLOCK(c); } ADDOP(c, POP_TOP); if (handler->v.ExceptHandler.name) { @@ -3118,7 +3223,7 @@ compiler_try_except(struct compiler *c, stmt_ty s) */ /* second try: */ - ADDOP_JREL(c, SETUP_FINALLY, cleanup_end); + ADDOP_JUMP(c, SETUP_FINALLY, cleanup_end); compiler_use_next_block(c, cleanup_body); if (!compiler_push_fblock(c, HANDLER_CLEANUP, cleanup_body, NULL, handler->v.ExceptHandler.name)) return 0; @@ -3126,23 +3231,25 @@ compiler_try_except(struct compiler *c, stmt_ty s) /* second # body */ VISIT_SEQ(c, stmt, handler->v.ExceptHandler.body); compiler_pop_fblock(c, HANDLER_CLEANUP, cleanup_body); + /* name = None; del name; # Mark as artificial */ + c->u->u_lineno = -1; ADDOP(c, POP_BLOCK); ADDOP(c, POP_EXCEPT); - /* name = None; del name */ ADDOP_LOAD_CONST(c, Py_None); compiler_nameop(c, handler->v.ExceptHandler.name, Store); compiler_nameop(c, handler->v.ExceptHandler.name, Del); - ADDOP_JREL(c, JUMP_FORWARD, end); + ADDOP_JUMP(c, JUMP_FORWARD, end); /* except: */ compiler_use_next_block(c, cleanup_end); - /* name = None; del name */ + /* name = None; del name; # Mark as artificial */ + c->u->u_lineno = -1; ADDOP_LOAD_CONST(c, Py_None); compiler_nameop(c, handler->v.ExceptHandler.name, Store); compiler_nameop(c, handler->v.ExceptHandler.name, Del); - ADDOP(c, RERAISE); + ADDOP_I(c, RERAISE, 1); } else { basicblock *cleanup_body; @@ -3158,13 +3265,16 @@ compiler_try_except(struct compiler *c, stmt_ty s) return 0; VISIT_SEQ(c, stmt, handler->v.ExceptHandler.body); compiler_pop_fblock(c, HANDLER_CLEANUP, cleanup_body); + c->u->u_lineno = -1; ADDOP(c, POP_EXCEPT); - ADDOP_JREL(c, JUMP_FORWARD, end); + ADDOP_JUMP(c, JUMP_FORWARD, end); } compiler_use_next_block(c, except); } compiler_pop_fblock(c, EXCEPTION_HANDLER, NULL); - ADDOP(c, RERAISE); + /* Mark as artificial */ + c->u->u_lineno = -1; + ADDOP_I(c, RERAISE, 0); compiler_use_next_block(c, orelse); VISIT_SEQ(c, stmt, s->v.Try.orelse); compiler_use_next_block(c, end); @@ -3232,11 +3342,12 @@ compiler_import(struct compiler *c, stmt_ty s) */ Py_ssize_t i, n = asdl_seq_LEN(s->v.Import.names); + PyObject *zero = _PyLong_GetZero(); // borrowed reference for (i = 0; i < n; i++) { alias_ty alias = (alias_ty)asdl_seq_GET(s->v.Import.names, i); int r; - ADDOP_LOAD_CONST(c, _PyLong_Zero); + ADDOP_LOAD_CONST(c, zero); ADDOP_LOAD_CONST(c, Py_None); ADDOP_NAME(c, IMPORT_NAME, alias->name, names); @@ -3334,10 +3445,12 @@ compiler_assert(struct compiler *c, stmt_ty s) { basicblock *end; - if (c->c_optimize) - return 1; - if (s->v.Assert.test->kind == Tuple_kind && - asdl_seq_LEN(s->v.Assert.test->v.Tuple.elts) > 0) + /* Always emit a warning if the test is a non-zero length tuple */ + if ((s->v.Assert.test->kind == Tuple_kind && + asdl_seq_LEN(s->v.Assert.test->v.Tuple.elts) > 0) || + (s->v.Assert.test->kind == Constant_kind && + PyTuple_Check(s->v.Assert.test->v.Constant.value) && + PyTuple_Size(s->v.Assert.test->v.Constant.value) > 0)) { if (!compiler_warn(c, "assertion is always true, " "perhaps remove parentheses?")) @@ -3345,6 +3458,8 @@ compiler_assert(struct compiler *c, stmt_ty s) return 0; } } + if (c->c_optimize) + return 1; end = compiler_new_block(c); if (end == NULL) return 0; @@ -3371,10 +3486,13 @@ compiler_visit_stmt_expr(struct compiler *c, expr_ty value) if (value->kind == Constant_kind) { /* ignore constant statement */ + ADDOP(c, NOP); return 1; } VISIT(c, expr, value); + /* Mark POP_TOP as artificial */ + c->u->u_lineno = -1; ADDOP(c, POP_TOP); return 1; } @@ -3417,6 +3535,8 @@ compiler_visit_stmt(struct compiler *c, stmt_ty s) return compiler_while(c, s); case If_kind: return compiler_if(c, s); + case Match_kind: + return compiler_match(c, s); case Raise_kind: n = 0; if (s->v.Raise.exc) { @@ -3428,6 +3548,7 @@ compiler_visit_stmt(struct compiler *c, stmt_ty s) } } ADDOP_I(c, RAISE_VARARGS, (int)n); + NEXT_BLOCK(c); break; case Try_kind: return compiler_try(c, s); @@ -3443,6 +3564,7 @@ compiler_visit_stmt(struct compiler *c, stmt_ty s) case Expr_kind: return compiler_visit_stmt_expr(c, s->v.Expr.value); case Pass_kind: + ADDOP(c, NOP); break; case Break_kind: return compiler_break(c); @@ -3577,7 +3699,7 @@ compiler_nameop(struct compiler *c, identifier name, expr_context_ty ctx) op = 0; optype = OP_NAME; - scope = PyST_GetScope(c->u->u_ste, mangled); + scope = _PyST_GetScope(c->u->u_ste, mangled); switch (scope) { case FREE: dict = c->u->u_freevars; @@ -3654,7 +3776,7 @@ compiler_boolop(struct compiler *c, expr_ty e) basicblock *end; int jumpi; Py_ssize_t i, n; - asdl_seq *s; + asdl_expr_seq *s; assert(e->kind == BoolOp_kind); if (e->v.BoolOp.op == And) @@ -3669,7 +3791,12 @@ compiler_boolop(struct compiler *c, expr_ty e) assert(n >= 0); for (i = 0; i < n; ++i) { VISIT(c, expr, (expr_ty)asdl_seq_GET(s, i)); - ADDOP_JABS(c, jumpi, end); + ADDOP_JUMP(c, jumpi, end); + basicblock *next = compiler_new_block(c); + if (next == NULL) { + return 0; + } + compiler_use_next_block(c, next); } VISIT(c, expr, (expr_ty)asdl_seq_GET(s, n)); compiler_use_next_block(c, end); @@ -3677,18 +3804,17 @@ compiler_boolop(struct compiler *c, expr_ty e) } static int -starunpack_helper(struct compiler *c, asdl_seq *elts, int pushed, +starunpack_helper(struct compiler *c, asdl_expr_seq *elts, int pushed, int build, int add, int extend, int tuple) { Py_ssize_t n = asdl_seq_LEN(elts); - Py_ssize_t i, seen_star = 0; if (n > 2 && are_all_items_const(elts, 0, n)) { PyObject *folded = PyTuple_New(n); if (folded == NULL) { return 0; } PyObject *val; - for (i = 0; i < n; i++) { + for (Py_ssize_t i = 0; i < n; i++) { val = ((expr_ty)asdl_seq_GET(elts, i))->v.Constant.value; Py_INCREF(val); PyTuple_SET_ITEM(folded, i, val); @@ -3709,38 +3835,16 @@ starunpack_helper(struct compiler *c, asdl_seq *elts, int pushed, return 1; } - for (i = 0; i < n; i++) { + int big = n+pushed > STACK_USE_GUIDELINE; + int seen_star = 0; + for (Py_ssize_t i = 0; i < n; i++) { expr_ty elt = asdl_seq_GET(elts, i); if (elt->kind == Starred_kind) { seen_star = 1; } } - if (seen_star) { - seen_star = 0; - for (i = 0; i < n; i++) { - expr_ty elt = asdl_seq_GET(elts, i); - if (elt->kind == Starred_kind) { - if (seen_star == 0) { - ADDOP_I(c, build, i+pushed); - seen_star = 1; - } - VISIT(c, expr, elt->v.Starred.value); - ADDOP_I(c, extend, 1); - } - else { - VISIT(c, expr, elt); - if (seen_star) { - ADDOP_I(c, add, 1); - } - } - } - assert(seen_star); - if (tuple) { - ADDOP(c, LIST_TO_TUPLE); - } - } - else { - for (i = 0; i < n; i++) { + if (!seen_star && !big) { + for (Py_ssize_t i = 0; i < n; i++) { expr_ty elt = asdl_seq_GET(elts, i); VISIT(c, expr, elt); } @@ -3749,17 +3853,43 @@ starunpack_helper(struct compiler *c, asdl_seq *elts, int pushed, } else { ADDOP_I(c, build, n+pushed); } + return 1; + } + int sequence_built = 0; + if (big) { + ADDOP_I(c, build, pushed); + sequence_built = 1; + } + for (Py_ssize_t i = 0; i < n; i++) { + expr_ty elt = asdl_seq_GET(elts, i); + if (elt->kind == Starred_kind) { + if (sequence_built == 0) { + ADDOP_I(c, build, i+pushed); + sequence_built = 1; + } + VISIT(c, expr, elt->v.Starred.value); + ADDOP_I(c, extend, 1); + } + else { + VISIT(c, expr, elt); + if (sequence_built) { + ADDOP_I(c, add, 1); + } + } + } + assert(sequence_built); + if (tuple) { + ADDOP(c, LIST_TO_TUPLE); } return 1; } static int -assignment_helper(struct compiler *c, asdl_seq *elts) +unpack_helper(struct compiler *c, asdl_expr_seq *elts) { Py_ssize_t n = asdl_seq_LEN(elts); - Py_ssize_t i; int seen_star = 0; - for (i = 0; i < n; i++) { + for (Py_ssize_t i = 0; i < n; i++) { expr_ty elt = asdl_seq_GET(elts, i); if (elt->kind == Starred_kind && !seen_star) { if ((i >= (1 << 8)) || @@ -3778,7 +3908,15 @@ assignment_helper(struct compiler *c, asdl_seq *elts) if (!seen_star) { ADDOP_I(c, UNPACK_SEQUENCE, n); } - for (i = 0; i < n; i++) { + return 1; +} + +static int +assignment_helper(struct compiler *c, asdl_expr_seq *elts) +{ + Py_ssize_t n = asdl_seq_LEN(elts); + RETURN_IF_FALSE(unpack_helper(c, elts)); + for (Py_ssize_t i = 0; i < n; i++) { expr_ty elt = asdl_seq_GET(elts, i); VISIT(c, expr, elt->kind != Starred_kind ? elt : elt->v.Starred.value); } @@ -3788,7 +3926,7 @@ assignment_helper(struct compiler *c, asdl_seq *elts) static int compiler_list(struct compiler *c, expr_ty e) { - asdl_seq *elts = e->v.List.elts; + asdl_expr_seq *elts = e->v.List.elts; if (e->v.List.ctx == Store) { return assignment_helper(c, elts); } @@ -3804,7 +3942,7 @@ compiler_list(struct compiler *c, expr_ty e) static int compiler_tuple(struct compiler *c, expr_ty e) { - asdl_seq *elts = e->v.Tuple.elts; + asdl_expr_seq *elts = e->v.Tuple.elts; if (e->v.Tuple.ctx == Store) { return assignment_helper(c, elts); } @@ -3825,7 +3963,7 @@ compiler_set(struct compiler *c, expr_ty e) } static int -are_all_items_const(asdl_seq *seq, Py_ssize_t begin, Py_ssize_t end) +are_all_items_const(asdl_expr_seq *seq, Py_ssize_t begin, Py_ssize_t end) { Py_ssize_t i; for (i = begin; i < end; i++) { @@ -3841,7 +3979,8 @@ compiler_subdict(struct compiler *c, expr_ty e, Py_ssize_t begin, Py_ssize_t end { Py_ssize_t i, n = end - begin; PyObject *keys, *key; - if (n > 1 && are_all_items_const(e->v.Dict.keys, begin, end)) { + int big = n*2 > STACK_USE_GUIDELINE; + if (n > 1 && !big && are_all_items_const(e->v.Dict.keys, begin, end)) { for (i = begin; i < end; i++) { VISIT(c, expr, (expr_ty)asdl_seq_GET(e->v.Dict.values, i)); } @@ -3856,12 +3995,19 @@ compiler_subdict(struct compiler *c, expr_ty e, Py_ssize_t begin, Py_ssize_t end } ADDOP_LOAD_CONST_NEW(c, keys); ADDOP_I(c, BUILD_CONST_KEY_MAP, n); + return 1; } - else { - for (i = begin; i < end; i++) { - VISIT(c, expr, (expr_ty)asdl_seq_GET(e->v.Dict.keys, i)); - VISIT(c, expr, (expr_ty)asdl_seq_GET(e->v.Dict.values, i)); + if (big) { + ADDOP_I(c, BUILD_MAP, 0); + } + for (i = begin; i < end; i++) { + VISIT(c, expr, (expr_ty)asdl_seq_GET(e->v.Dict.keys, i)); + VISIT(c, expr, (expr_ty)asdl_seq_GET(e->v.Dict.values, i)); + if (big) { + ADDOP_I(c, MAP_ADD, 1); } + } + if (!big) { ADDOP_I(c, BUILD_MAP, n); } return 1; @@ -3897,7 +4043,7 @@ compiler_dict(struct compiler *c, expr_ty e) ADDOP_I(c, DICT_UPDATE, 1); } else { - if (elements == 0xFFFF) { + if (elements*2 > STACK_USE_GUIDELINE) { if (!compiler_subdict(c, e, i - elements, i + 1)) { return 0; } @@ -3952,7 +4098,7 @@ compiler_compare(struct compiler *c, expr_ty e) ADDOP(c, DUP_TOP); ADDOP(c, ROT_THREE); ADDOP_COMPARE(c, asdl_seq_GET(e->v.Compare.ops, i)); - ADDOP_JABS(c, JUMP_IF_FALSE_OR_POP, cleanup); + ADDOP_JUMP(c, JUMP_IF_FALSE_OR_POP, cleanup); NEXT_BLOCK(c); } VISIT(c, expr, (expr_ty)asdl_seq_GET(e->v.Compare.comparators, n)); @@ -3960,7 +4106,7 @@ compiler_compare(struct compiler *c, expr_ty e) basicblock *end = compiler_new_block(c); if (end == NULL) return 0; - ADDOP_JREL(c, JUMP_FORWARD, end); + ADDOP_JUMP_NOLINE(c, JUMP_FORWARD, end); compiler_use_next_block(c, cleanup); ADDOP(c, ROT_TWO); ADDOP(c, POP_TOP); @@ -4088,16 +4234,20 @@ maybe_optimize_method_call(struct compiler *c, expr_ty e) { Py_ssize_t argsl, i; expr_ty meth = e->v.Call.func; - asdl_seq *args = e->v.Call.args; + asdl_expr_seq *args = e->v.Call.args; /* Check that the call node is an attribute access, and that the call doesn't have keyword parameters. */ if (meth->kind != Attribute_kind || meth->v.Attribute.ctx != Load || - asdl_seq_LEN(e->v.Call.keywords)) + asdl_seq_LEN(e->v.Call.keywords)) { return -1; - - /* Check that there are no *varargs types of arguments. */ + } + /* Check that there aren't too many arguments */ argsl = asdl_seq_LEN(args); + if (argsl >= STACK_USE_GUIDELINE) { + return -1; + } + /* Check that there are no *varargs types of arguments. */ for (i = 0; i < argsl; i++) { expr_ty elt = asdl_seq_GET(args, i); if (elt->kind == Starred_kind) { @@ -4107,14 +4257,17 @@ maybe_optimize_method_call(struct compiler *c, expr_ty e) /* Alright, we can optimize the code. */ VISIT(c, expr, meth->v.Attribute.value); + int old_lineno = c->u->u_lineno; + c->u->u_lineno = meth->end_lineno; ADDOP_NAME(c, LOAD_METHOD, meth->v.Attribute.attr, names); VISIT_SEQ(c, expr, e->v.Call.args); ADDOP_I(c, CALL_METHOD, asdl_seq_LEN(e->v.Call.args)); + c->u->u_lineno = old_lineno; return 1; } static int -validate_keywords(struct compiler *c, asdl_seq *keywords) +validate_keywords(struct compiler *c, asdl_keyword_seq *keywords) { Py_ssize_t nkeywords = asdl_seq_LEN(keywords); for (Py_ssize_t i = 0; i < nkeywords; i++) { @@ -4128,13 +4281,8 @@ validate_keywords(struct compiler *c, asdl_seq *keywords) for (Py_ssize_t j = i + 1; j < nkeywords; j++) { keyword_ty other = ((keyword_ty)asdl_seq_GET(keywords, j)); if (other->arg && !PyUnicode_Compare(key->arg, other->arg)) { - PyObject *msg = PyUnicode_FromFormat("keyword argument repeated: %U", key->arg); - if (msg == NULL) { - return -1; - } - c->u->u_col_offset = other->col_offset; - compiler_error(c, PyUnicode_AsUTF8(msg)); - Py_DECREF(msg); + SET_LOC(c, other); + compiler_error(c, "keyword argument repeated: %U", key->arg); return -1; } } @@ -4161,9 +4309,29 @@ compiler_call(struct compiler *c, expr_ty e) static int compiler_joined_str(struct compiler *c, expr_ty e) { - VISIT_SEQ(c, expr, e->v.JoinedStr.values); - if (asdl_seq_LEN(e->v.JoinedStr.values) != 1) - ADDOP_I(c, BUILD_STRING, asdl_seq_LEN(e->v.JoinedStr.values)); + + Py_ssize_t value_count = asdl_seq_LEN(e->v.JoinedStr.values); + if (value_count > STACK_USE_GUIDELINE) { + ADDOP_LOAD_CONST_NEW(c, _PyUnicode_FromASCII("", 0)); + PyObject *join = _PyUnicode_FromASCII("join", 4); + if (join == NULL) { + return 0; + } + ADDOP_NAME(c, LOAD_METHOD, join, names); + Py_DECREF(join); + ADDOP_I(c, BUILD_LIST, 0); + for (Py_ssize_t i = 0; i < asdl_seq_LEN(e->v.JoinedStr.values); i++) { + VISIT(c, expr, asdl_seq_GET(e->v.JoinedStr.values, i)); + ADDOP_I(c, LIST_APPEND, 1); + } + ADDOP_I(c, CALL_METHOD, 1); + } + else { + VISIT_SEQ(c, expr, e->v.JoinedStr.values); + if (asdl_seq_LEN(e->v.JoinedStr.values) != 1) { + ADDOP_I(c, BUILD_STRING, asdl_seq_LEN(e->v.JoinedStr.values)); + } + } return 1; } @@ -4214,13 +4382,14 @@ compiler_formatted_value(struct compiler *c, expr_ty e) } static int -compiler_subkwargs(struct compiler *c, asdl_seq *keywords, Py_ssize_t begin, Py_ssize_t end) +compiler_subkwargs(struct compiler *c, asdl_keyword_seq *keywords, Py_ssize_t begin, Py_ssize_t end) { Py_ssize_t i, n = end - begin; keyword_ty kw; PyObject *keys, *key; assert(n > 0); - if (n > 1) { + int big = n*2 > STACK_USE_GUIDELINE; + if (n > 1 && !big) { for (i = begin; i < end; i++) { kw = asdl_seq_GET(keywords, i); VISIT(c, expr, kw->value); @@ -4236,14 +4405,20 @@ compiler_subkwargs(struct compiler *c, asdl_seq *keywords, Py_ssize_t begin, Py_ } ADDOP_LOAD_CONST_NEW(c, keys); ADDOP_I(c, BUILD_CONST_KEY_MAP, n); + return 1; } - else { - /* a for loop only executes once */ - for (i = begin; i < end; i++) { - kw = asdl_seq_GET(keywords, i); - ADDOP_LOAD_CONST(c, kw->arg); - VISIT(c, expr, kw->value); + if (big) { + ADDOP_I_NOLINE(c, BUILD_MAP, 0); + } + for (i = begin; i < end; i++) { + kw = asdl_seq_GET(keywords, i); + ADDOP_LOAD_CONST(c, kw->arg); + VISIT(c, expr, kw->value); + if (big) { + ADDOP_I_NOLINE(c, MAP_ADD, 1); } + } + if (!big) { ADDOP_I(c, BUILD_MAP, n); } return 1; @@ -4253,8 +4428,8 @@ compiler_subkwargs(struct compiler *c, asdl_seq *keywords, Py_ssize_t begin, Py_ static int compiler_call_helper(struct compiler *c, int n, /* Args already pushed */ - asdl_seq *args, - asdl_seq *keywords) + asdl_expr_seq *args, + asdl_keyword_seq *keywords) { Py_ssize_t i, nseen, nelts, nkwelts; @@ -4265,6 +4440,9 @@ compiler_call_helper(struct compiler *c, nelts = asdl_seq_LEN(args); nkwelts = asdl_seq_LEN(keywords); + if (nelts + nkwelts*2 > STACK_USE_GUIDELINE) { + goto ex_call; + } for (i = 0; i < nelts; i++) { expr_ty elt = asdl_seq_GET(args, i); if (elt->kind == Starred_kind) { @@ -4379,7 +4557,7 @@ ex_call: static int compiler_comprehension_generator(struct compiler *c, - asdl_seq *generators, int gen_index, + asdl_comprehension_seq *generators, int gen_index, int depth, expr_ty elt, expr_ty val, int type) { @@ -4396,7 +4574,7 @@ compiler_comprehension_generator(struct compiler *c, static int compiler_sync_comprehension_generator(struct compiler *c, - asdl_seq *generators, int gen_index, + asdl_comprehension_seq *generators, int gen_index, int depth, expr_ty elt, expr_ty val, int type) { @@ -4428,7 +4606,7 @@ compiler_sync_comprehension_generator(struct compiler *c, /* Fast path for the temporary variable assignment idiom: for y in [f(x)] */ - asdl_seq *elts; + asdl_expr_seq *elts; switch (gen->iter->kind) { case List_kind: elts = gen->iter->v.List.elts; @@ -4454,7 +4632,7 @@ compiler_sync_comprehension_generator(struct compiler *c, if (start) { depth++; compiler_use_next_block(c, start); - ADDOP_JREL(c, FOR_ITER, anchor); + ADDOP_JUMP(c, FOR_ITER, anchor); NEXT_BLOCK(c); } VISIT(c, expr, gen->target); @@ -4506,7 +4684,7 @@ compiler_sync_comprehension_generator(struct compiler *c, } compiler_use_next_block(c, if_cleanup); if (start) { - ADDOP_JABS(c, JUMP_ABSOLUTE, start); + ADDOP_JUMP(c, JUMP_ABSOLUTE, start); compiler_use_next_block(c, anchor); } @@ -4515,7 +4693,7 @@ compiler_sync_comprehension_generator(struct compiler *c, static int compiler_async_comprehension_generator(struct compiler *c, - asdl_seq *generators, int gen_index, + asdl_comprehension_seq *generators, int gen_index, int depth, expr_ty elt, expr_ty val, int type) { @@ -4544,8 +4722,13 @@ compiler_async_comprehension_generator(struct compiler *c, } compiler_use_next_block(c, start); + /* Runtime will push a block here, so we need to account for that */ + if (!compiler_push_fblock(c, ASYNC_COMPREHENSION_GENERATOR, start, + NULL, NULL)) { + return 0; + } - ADDOP_JREL(c, SETUP_FINALLY, except); + ADDOP_JUMP(c, SETUP_FINALLY, except); ADDOP(c, GET_ANEXT); ADDOP_LOAD_CONST(c, Py_None); ADDOP(c, YIELD_FROM); @@ -4596,7 +4779,9 @@ compiler_async_comprehension_generator(struct compiler *c, } } compiler_use_next_block(c, if_cleanup); - ADDOP_JABS(c, JUMP_ABSOLUTE, start); + ADDOP_JUMP(c, JUMP_ABSOLUTE, start); + + compiler_pop_fblock(c, ASYNC_COMPREHENSION_GENERATOR, start); compiler_use_next_block(c, except); ADDOP(c, END_ASYNC_FOR); @@ -4606,7 +4791,7 @@ compiler_async_comprehension_generator(struct compiler *c, static int compiler_comprehension(struct compiler *c, expr_ty e, int type, - identifier name, asdl_seq *generators, expr_ty elt, + identifier name, asdl_comprehension_seq *generators, expr_ty elt, expr_ty val) { PyCodeObject *co = NULL; @@ -4624,6 +4809,7 @@ compiler_comprehension(struct compiler *c, expr_ty e, int type, { goto error; } + SET_LOC(c, e); is_async_generator = c->u->u_ste->ste_coroutine; @@ -4672,8 +4858,9 @@ compiler_comprehension(struct compiler *c, expr_ty e, int type, if (co == NULL) goto error; - if (!compiler_make_closure(c, co, 0, qualname)) + if (!compiler_make_closure(c, co, 0, qualname)) { goto error; + } Py_DECREF(qualname); Py_DECREF(co); @@ -4778,22 +4965,14 @@ compiler_visit_keyword(struct compiler *c, keyword_ty k) */ static int -expr_constant(expr_ty e) -{ - if (e->kind == Constant_kind) { - return PyObject_IsTrue(e->v.Constant.value); - } - return -1; -} - -static int compiler_with_except_finish(struct compiler *c) { basicblock *exit; exit = compiler_new_block(c); if (exit == NULL) return 0; - ADDOP_JABS(c, POP_JUMP_IF_TRUE, exit); - ADDOP(c, RERAISE); + ADDOP_JUMP(c, POP_JUMP_IF_TRUE, exit); + NEXT_BLOCK(c); + ADDOP_I(c, RERAISE, 1); compiler_use_next_block(c, exit); ADDOP(c, POP_TOP); ADDOP(c, POP_TOP); @@ -4854,11 +5033,11 @@ compiler_async_with(struct compiler *c, stmt_ty s, int pos) ADDOP_LOAD_CONST(c, Py_None); ADDOP(c, YIELD_FROM); - ADDOP_JREL(c, SETUP_ASYNC_WITH, final); + ADDOP_JUMP(c, SETUP_ASYNC_WITH, final); /* SETUP_ASYNC_WITH pushes a finally block. */ compiler_use_next_block(c, block); - if (!compiler_push_fblock(c, ASYNC_WITH, block, final, NULL)) { + if (!compiler_push_fblock(c, ASYNC_WITH, block, final, s)) { return 0; } @@ -4884,19 +5063,19 @@ compiler_async_with(struct compiler *c, stmt_ty s, int pos) /* For successful outcome: * call __exit__(None, None, None) */ + SET_LOC(c, s); if(!compiler_call_exit_with_nones(c)) return 0; ADDOP(c, GET_AWAITABLE); - ADDOP_O(c, LOAD_CONST, Py_None, consts); + ADDOP_LOAD_CONST(c, Py_None); ADDOP(c, YIELD_FROM); ADDOP(c, POP_TOP); - ADDOP_JABS(c, JUMP_ABSOLUTE, exit); + ADDOP_JUMP(c, JUMP_ABSOLUTE, exit); /* For exceptional outcome: */ compiler_use_next_block(c, final); - ADDOP(c, WITH_EXCEPT_START); ADDOP(c, GET_AWAITABLE); ADDOP_LOAD_CONST(c, Py_None); @@ -4946,11 +5125,11 @@ compiler_with(struct compiler *c, stmt_ty s, int pos) /* Evaluate EXPR */ VISIT(c, expr, item->context_expr); /* Will push bound __exit__ */ - ADDOP_JREL(c, SETUP_WITH, final); + ADDOP_JUMP(c, SETUP_WITH, final); /* SETUP_WITH pushes a finally block. */ compiler_use_next_block(c, block); - if (!compiler_push_fblock(c, WITH, block, final, NULL)) { + if (!compiler_push_fblock(c, WITH, block, final, s)) { return 0; } @@ -4969,6 +5148,9 @@ compiler_with(struct compiler *c, stmt_ty s, int pos) else if (!compiler_with(c, s, pos)) return 0; + + /* Mark all following code as artificial */ + c->u->u_lineno = -1; ADDOP(c, POP_BLOCK); compiler_pop_fblock(c, WITH, block); @@ -4977,14 +5159,14 @@ compiler_with(struct compiler *c, stmt_ty s, int pos) /* For successful outcome: * call __exit__(None, None, None) */ + SET_LOC(c, s); if (!compiler_call_exit_with_nones(c)) return 0; ADDOP(c, POP_TOP); - ADDOP_JREL(c, JUMP_FORWARD, exit); + ADDOP_JUMP(c, JUMP_FORWARD, exit); /* For exceptional outcome: */ compiler_use_next_block(c, final); - ADDOP(c, WITH_EXCEPT_START); compiler_with_except_finish(c); @@ -5084,12 +5266,21 @@ compiler_visit_expr1(struct compiler *c, expr_ty e) VISIT(c, expr, e->v.Attribute.value); switch (e->v.Attribute.ctx) { case Load: + { + int old_lineno = c->u->u_lineno; + c->u->u_lineno = e->end_lineno; ADDOP_NAME(c, LOAD_ATTR, e->v.Attribute.attr, names); + c->u->u_lineno = old_lineno; break; + } case Store: - if (forbidden_name(c, e->v.Attribute.attr, e->v.Attribute.ctx)) + if (forbidden_name(c, e->v.Attribute.attr, e->v.Attribute.ctx)) { return 0; + } + int old_lineno = c->u->u_lineno; + c->u->u_lineno = e->end_lineno; ADDOP_NAME(c, STORE_ATTR, e->v.Attribute.attr, names); + c->u->u_lineno = old_lineno; break; case Del: ADDOP_NAME(c, DELETE_ATTR, e->v.Attribute.attr, names); @@ -5127,11 +5318,15 @@ static int compiler_visit_expr(struct compiler *c, expr_ty e) { int old_lineno = c->u->u_lineno; + int old_end_lineno = c->u->u_end_lineno; int old_col_offset = c->u->u_col_offset; + int old_end_col_offset = c->u->u_end_col_offset; SET_LOC(c, e); int res = compiler_visit_expr1(c, e); c->u->u_lineno = old_lineno; + c->u->u_end_lineno = old_end_lineno; c->u->u_col_offset = old_col_offset; + c->u->u_end_col_offset = old_end_col_offset; return res; } @@ -5142,14 +5337,19 @@ compiler_augassign(struct compiler *c, stmt_ty s) expr_ty e = s->v.AugAssign.target; int old_lineno = c->u->u_lineno; + int old_end_lineno = c->u->u_end_lineno; int old_col_offset = c->u->u_col_offset; + int old_end_col_offset = c->u->u_end_col_offset; SET_LOC(c, e); switch (e->kind) { case Attribute_kind: VISIT(c, expr, e->v.Attribute.value); ADDOP(c, DUP_TOP); + int old_lineno = c->u->u_lineno; + c->u->u_lineno = e->end_lineno; ADDOP_NAME(c, LOAD_ATTR, e->v.Attribute.attr, names); + c->u->u_lineno = old_lineno; break; case Subscript_kind: VISIT(c, expr, e->v.Subscript.value); @@ -5169,7 +5369,9 @@ compiler_augassign(struct compiler *c, stmt_ty s) } c->u->u_lineno = old_lineno; + c->u->u_end_lineno = old_end_lineno; c->u->u_col_offset = old_col_offset; + c->u->u_end_col_offset = old_end_col_offset; VISIT(c, expr, s->v.AugAssign.value); ADDOP(c, inplace_binop(s->v.AugAssign.op)); @@ -5178,6 +5380,7 @@ compiler_augassign(struct compiler *c, stmt_ty s) switch (e->kind) { case Attribute_kind: + c->u->u_lineno = e->end_lineno; ADDOP(c, ROT_TWO); ADDOP_NAME(c, STORE_ATTR, e->v.Attribute.attr, names); break; @@ -5204,6 +5407,12 @@ check_ann_expr(struct compiler *c, expr_ty e) static int check_annotation(struct compiler *c, stmt_ty s) { + /* Annotations of complex targets does not produce anything + under annotations future */ + if (c->c_future->ff_features & CO_FUTURE_ANNOTATIONS) { + return 1; + } + /* Annotations are only evaluated in a module or class. */ if (c->u->u_scope_type == COMPILER_SCOPE_MODULE || c->u->u_scope_type == COMPILER_SCOPE_CLASS) { @@ -5230,7 +5439,7 @@ check_ann_subscr(struct compiler *c, expr_ty e) return 1; case Tuple_kind: { /* extended slice */ - asdl_seq *elts = e->v.Tuple.elts; + asdl_expr_seq *elts = e->v.Tuple.elts; Py_ssize_t i, n = asdl_seq_LEN(elts); for (i = 0; i < n; i++) { if (!check_ann_subscr(c, asdl_seq_GET(elts, i))) { @@ -5310,28 +5519,35 @@ compiler_annassign(struct compiler *c, stmt_ty s) */ static int -compiler_error(struct compiler *c, const char *errstr) +compiler_error(struct compiler *c, const char *format, ...) { - PyObject *loc; - PyObject *u = NULL, *v = NULL; - - loc = PyErr_ProgramTextObject(c->c_filename, c->u->u_lineno); - if (!loc) { + va_list vargs; +#ifdef HAVE_STDARG_PROTOTYPES + va_start(vargs, format); +#else + va_start(vargs); +#endif + PyObject *msg = PyUnicode_FromFormatV(format, vargs); + va_end(vargs); + if (msg == NULL) { + return 0; + } + PyObject *loc = PyErr_ProgramTextObject(c->c_filename, c->u->u_lineno); + if (loc == NULL) { Py_INCREF(Py_None); loc = Py_None; } - u = Py_BuildValue("(OiiO)", c->c_filename, c->u->u_lineno, - c->u->u_col_offset + 1, loc); - if (!u) - goto exit; - v = Py_BuildValue("(zO)", errstr, u); - if (!v) + PyObject *args = Py_BuildValue("O(OiiOii)", msg, c->c_filename, + c->u->u_lineno, c->u->u_col_offset + 1, loc, + c->u->u_end_lineno, c->u->u_end_col_offset + 1); + Py_DECREF(msg); + if (args == NULL) { goto exit; - PyErr_SetObject(PyExc_SyntaxError, v); + } + PyErr_SetObject(PyExc_SyntaxError, args); exit: Py_DECREF(loc); - Py_XDECREF(u); - Py_XDECREF(v); + Py_XDECREF(args); return 0; } @@ -5426,6 +5642,812 @@ compiler_slice(struct compiler *c, expr_ty s) return 1; } + +// PEP 634: Structural Pattern Matching + +// To keep things simple, all compiler_pattern_* and pattern_helper_* routines +// follow the convention of consuming TOS (the subject for the given pattern) +// and calling jump_to_fail_pop on failure (no match). + +// When calling into these routines, it's important that pc->on_top be kept +// updated to reflect the current number of items that we are using on the top +// of the stack: they will be popped on failure, and any name captures will be +// stored *underneath* them on success. This lets us defer all names stores +// until the *entire* pattern matches. + +#define WILDCARD_CHECK(N) \ + ((N)->kind == MatchAs_kind && !(N)->v.MatchAs.name) + +#define WILDCARD_STAR_CHECK(N) \ + ((N)->kind == MatchStar_kind && !(N)->v.MatchStar.name) + +// Limit permitted subexpressions, even if the parser & AST validator let them through +#define MATCH_VALUE_EXPR(N) \ + ((N)->kind == Constant_kind || (N)->kind == Attribute_kind) + +// Allocate or resize pc->fail_pop to allow for n items to be popped on failure. +static int +ensure_fail_pop(struct compiler *c, pattern_context *pc, Py_ssize_t n) +{ + Py_ssize_t size = n + 1; + if (size <= pc->fail_pop_size) { + return 1; + } + Py_ssize_t needed = sizeof(basicblock*) * size; + basicblock **resized = PyObject_Realloc(pc->fail_pop, needed); + if (resized == NULL) { + PyErr_NoMemory(); + return 0; + } + pc->fail_pop = resized; + while (pc->fail_pop_size < size) { + basicblock *new_block; + RETURN_IF_FALSE(new_block = compiler_new_block(c)); + pc->fail_pop[pc->fail_pop_size++] = new_block; + } + return 1; +} + +// Use op to jump to the correct fail_pop block. +static int +jump_to_fail_pop(struct compiler *c, pattern_context *pc, int op) +{ + // Pop any items on the top of the stack, plus any objects we were going to + // capture on success: + Py_ssize_t pops = pc->on_top + PyList_GET_SIZE(pc->stores); + RETURN_IF_FALSE(ensure_fail_pop(c, pc, pops)); + ADDOP_JUMP(c, op, pc->fail_pop[pops]); + NEXT_BLOCK(c); + return 1; +} + +// Build all of the fail_pop blocks and reset fail_pop. +static int +emit_and_reset_fail_pop(struct compiler *c, pattern_context *pc) +{ + if (!pc->fail_pop_size) { + assert(pc->fail_pop == NULL); + NEXT_BLOCK(c); + return 1; + } + while (--pc->fail_pop_size) { + compiler_use_next_block(c, pc->fail_pop[pc->fail_pop_size]); + if (!compiler_addop(c, POP_TOP)) { + pc->fail_pop_size = 0; + PyObject_Free(pc->fail_pop); + pc->fail_pop = NULL; + return 0; + } + } + compiler_use_next_block(c, pc->fail_pop[0]); + PyObject_Free(pc->fail_pop); + pc->fail_pop = NULL; + return 1; +} + +static int +compiler_error_duplicate_store(struct compiler *c, identifier n) +{ + return compiler_error(c, "multiple assignments to name %R in pattern", n); +} + +static int +pattern_helper_store_name(struct compiler *c, identifier n, pattern_context *pc) +{ + if (n == NULL) { + ADDOP(c, POP_TOP); + return 1; + } + if (forbidden_name(c, n, Store)) { + return 0; + } + // Can't assign to the same name twice: + int duplicate = PySequence_Contains(pc->stores, n); + if (duplicate < 0) { + return 0; + } + if (duplicate) { + return compiler_error_duplicate_store(c, n); + } + // Rotate this object underneath any items we need to preserve: + ADDOP_I(c, ROT_N, pc->on_top + PyList_GET_SIZE(pc->stores) + 1); + return !PyList_Append(pc->stores, n); +} + + +static int +pattern_unpack_helper(struct compiler *c, asdl_pattern_seq *elts) +{ + Py_ssize_t n = asdl_seq_LEN(elts); + int seen_star = 0; + for (Py_ssize_t i = 0; i < n; i++) { + pattern_ty elt = asdl_seq_GET(elts, i); + if (elt->kind == MatchStar_kind && !seen_star) { + if ((i >= (1 << 8)) || + (n-i-1 >= (INT_MAX >> 8))) + return compiler_error(c, + "too many expressions in " + "star-unpacking sequence pattern"); + ADDOP_I(c, UNPACK_EX, (i + ((n-i-1) << 8))); + seen_star = 1; + } + else if (elt->kind == MatchStar_kind) { + return compiler_error(c, + "multiple starred expressions in sequence pattern"); + } + } + if (!seen_star) { + ADDOP_I(c, UNPACK_SEQUENCE, n); + } + return 1; +} + +static int +pattern_helper_sequence_unpack(struct compiler *c, asdl_pattern_seq *patterns, + Py_ssize_t star, pattern_context *pc) +{ + RETURN_IF_FALSE(pattern_unpack_helper(c, patterns)); + Py_ssize_t size = asdl_seq_LEN(patterns); + // We've now got a bunch of new subjects on the stack. They need to remain + // there after each subpattern match: + pc->on_top += size; + for (Py_ssize_t i = 0; i < size; i++) { + // One less item to keep track of each time we loop through: + pc->on_top--; + pattern_ty pattern = asdl_seq_GET(patterns, i); + RETURN_IF_FALSE(compiler_pattern_subpattern(c, pattern, pc)); + } + return 1; +} + +// Like pattern_helper_sequence_unpack, but uses BINARY_SUBSCR instead of +// UNPACK_SEQUENCE / UNPACK_EX. This is more efficient for patterns with a +// starred wildcard like [first, *_] / [first, *_, last] / [*_, last] / etc. +static int +pattern_helper_sequence_subscr(struct compiler *c, asdl_pattern_seq *patterns, + Py_ssize_t star, pattern_context *pc) +{ + // We need to keep the subject around for extracting elements: + pc->on_top++; + Py_ssize_t size = asdl_seq_LEN(patterns); + for (Py_ssize_t i = 0; i < size; i++) { + pattern_ty pattern = asdl_seq_GET(patterns, i); + if (WILDCARD_CHECK(pattern)) { + continue; + } + if (i == star) { + assert(WILDCARD_STAR_CHECK(pattern)); + continue; + } + ADDOP(c, DUP_TOP); + if (i < star) { + ADDOP_LOAD_CONST_NEW(c, PyLong_FromSsize_t(i)); + } + else { + // The subject may not support negative indexing! Compute a + // nonnegative index: + ADDOP(c, GET_LEN); + ADDOP_LOAD_CONST_NEW(c, PyLong_FromSsize_t(size - i)); + ADDOP(c, BINARY_SUBTRACT); + } + ADDOP(c, BINARY_SUBSCR); + RETURN_IF_FALSE(compiler_pattern_subpattern(c, pattern, pc)); + } + // Pop the subject, we're done with it: + pc->on_top--; + ADDOP(c, POP_TOP); + return 1; +} + +// Like compiler_pattern, but turn off checks for irrefutability. +static int +compiler_pattern_subpattern(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + int allow_irrefutable = pc->allow_irrefutable; + pc->allow_irrefutable = 1; + RETURN_IF_FALSE(compiler_pattern(c, p, pc)); + pc->allow_irrefutable = allow_irrefutable; + return 1; +} + +static int +compiler_pattern_as(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + assert(p->kind == MatchAs_kind); + if (p->v.MatchAs.pattern == NULL) { + // An irrefutable match: + if (!pc->allow_irrefutable) { + if (p->v.MatchAs.name) { + const char *e = "name capture %R makes remaining patterns unreachable"; + return compiler_error(c, e, p->v.MatchAs.name); + } + const char *e = "wildcard makes remaining patterns unreachable"; + return compiler_error(c, e); + } + return pattern_helper_store_name(c, p->v.MatchAs.name, pc); + } + // Need to make a copy for (possibly) storing later: + pc->on_top++; + ADDOP(c, DUP_TOP); + RETURN_IF_FALSE(compiler_pattern(c, p->v.MatchAs.pattern, pc)); + // Success! Store it: + pc->on_top--; + RETURN_IF_FALSE(pattern_helper_store_name(c, p->v.MatchAs.name, pc)); + return 1; +} + +static int +compiler_pattern_star(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + assert(p->kind == MatchStar_kind); + RETURN_IF_FALSE(pattern_helper_store_name(c, p->v.MatchStar.name, pc)); + return 1; +} + +static int +validate_kwd_attrs(struct compiler *c, asdl_identifier_seq *attrs, asdl_pattern_seq* patterns) +{ + // Any errors will point to the pattern rather than the arg name as the + // parser is only supplying identifiers rather than Name or keyword nodes + Py_ssize_t nattrs = asdl_seq_LEN(attrs); + for (Py_ssize_t i = 0; i < nattrs; i++) { + identifier attr = ((identifier)asdl_seq_GET(attrs, i)); + SET_LOC(c, ((pattern_ty) asdl_seq_GET(patterns, i))); + if (forbidden_name(c, attr, Store)) { + return -1; + } + for (Py_ssize_t j = i + 1; j < nattrs; j++) { + identifier other = ((identifier)asdl_seq_GET(attrs, j)); + if (!PyUnicode_Compare(attr, other)) { + SET_LOC(c, ((pattern_ty) asdl_seq_GET(patterns, j))); + compiler_error(c, "attribute name repeated in class pattern: %U", attr); + return -1; + } + } + } + return 0; +} + +static int +compiler_pattern_class(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + assert(p->kind == MatchClass_kind); + asdl_pattern_seq *patterns = p->v.MatchClass.patterns; + asdl_identifier_seq *kwd_attrs = p->v.MatchClass.kwd_attrs; + asdl_pattern_seq *kwd_patterns = p->v.MatchClass.kwd_patterns; + Py_ssize_t nargs = asdl_seq_LEN(patterns); + Py_ssize_t nattrs = asdl_seq_LEN(kwd_attrs); + Py_ssize_t nkwd_patterns = asdl_seq_LEN(kwd_patterns); + if (nattrs != nkwd_patterns) { + // AST validator shouldn't let this happen, but if it does, + // just fail, don't crash out of the interpreter + const char * e = "kwd_attrs (%d) / kwd_patterns (%d) length mismatch in class pattern"; + return compiler_error(c, e, nattrs, nkwd_patterns); + } + if (INT_MAX < nargs || INT_MAX < nargs + nattrs - 1) { + const char *e = "too many sub-patterns in class pattern %R"; + return compiler_error(c, e, p->v.MatchClass.cls); + } + if (nattrs) { + RETURN_IF_FALSE(!validate_kwd_attrs(c, kwd_attrs, kwd_patterns)); + SET_LOC(c, p); + } + VISIT(c, expr, p->v.MatchClass.cls); + PyObject *attr_names; + RETURN_IF_FALSE(attr_names = PyTuple_New(nattrs)); + Py_ssize_t i; + for (i = 0; i < nattrs; i++) { + PyObject *name = asdl_seq_GET(kwd_attrs, i); + Py_INCREF(name); + PyTuple_SET_ITEM(attr_names, i, name); + } + ADDOP_LOAD_CONST_NEW(c, attr_names); + ADDOP_I(c, MATCH_CLASS, nargs); + // TOS is now a tuple of (nargs + nattrs) attributes. Preserve it: + pc->on_top++; + RETURN_IF_FALSE(jump_to_fail_pop(c, pc, POP_JUMP_IF_FALSE)); + for (i = 0; i < nargs + nattrs; i++) { + pattern_ty pattern; + if (i < nargs) { + // Positional: + pattern = asdl_seq_GET(patterns, i); + } + else { + // Keyword: + pattern = asdl_seq_GET(kwd_patterns, i - nargs); + } + if (WILDCARD_CHECK(pattern)) { + continue; + } + // Get the i-th attribute, and match it against the i-th pattern: + ADDOP(c, DUP_TOP); + ADDOP_LOAD_CONST_NEW(c, PyLong_FromSsize_t(i)); + ADDOP(c, BINARY_SUBSCR); + RETURN_IF_FALSE(compiler_pattern_subpattern(c, pattern, pc)); + } + // Success! Pop the tuple of attributes: + pc->on_top--; + ADDOP(c, POP_TOP); + return 1; +} + +static int +compiler_pattern_mapping(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + assert(p->kind == MatchMapping_kind); + asdl_expr_seq *keys = p->v.MatchMapping.keys; + asdl_pattern_seq *patterns = p->v.MatchMapping.patterns; + Py_ssize_t size = asdl_seq_LEN(keys); + Py_ssize_t npatterns = asdl_seq_LEN(patterns); + if (size != npatterns) { + // AST validator shouldn't let this happen, but if it does, + // just fail, don't crash out of the interpreter + const char * e = "keys (%d) / patterns (%d) length mismatch in mapping pattern"; + return compiler_error(c, e, size, npatterns); + } + // We have a double-star target if "rest" is set + PyObject *star_target = p->v.MatchMapping.rest; + // We need to keep the subject on top during the mapping and length checks: + pc->on_top++; + ADDOP(c, MATCH_MAPPING); + RETURN_IF_FALSE(jump_to_fail_pop(c, pc, POP_JUMP_IF_FALSE)); + if (!size && !star_target) { + // If the pattern is just "{}", we're done! Pop the subject: + pc->on_top--; + ADDOP(c, POP_TOP); + return 1; + } + if (size) { + // If the pattern has any keys in it, perform a length check: + ADDOP(c, GET_LEN); + ADDOP_LOAD_CONST_NEW(c, PyLong_FromSsize_t(size)); + ADDOP_COMPARE(c, GtE); + RETURN_IF_FALSE(jump_to_fail_pop(c, pc, POP_JUMP_IF_FALSE)); + } + if (INT_MAX < size - 1) { + return compiler_error(c, "too many sub-patterns in mapping pattern"); + } + // Collect all of the keys into a tuple for MATCH_KEYS and + // COPY_DICT_WITHOUT_KEYS. They can either be dotted names or literals: + + // Maintaining a set of Constant_kind kind keys allows us to raise a + // SyntaxError in the case of duplicates. + PyObject *seen = PySet_New(NULL); + if (seen == NULL) { + return 0; + } + + // NOTE: goto error on failure in the loop below to avoid leaking `seen` + for (Py_ssize_t i = 0; i < size; i++) { + expr_ty key = asdl_seq_GET(keys, i); + if (key == NULL) { + const char *e = "can't use NULL keys in MatchMapping " + "(set 'rest' parameter instead)"; + SET_LOC(c, ((pattern_ty) asdl_seq_GET(patterns, i))); + compiler_error(c, e); + goto error; + } + + if (key->kind == Constant_kind) { + int in_seen = PySet_Contains(seen, key->v.Constant.value); + if (in_seen < 0) { + goto error; + } + if (in_seen) { + const char *e = "mapping pattern checks duplicate key (%R)"; + compiler_error(c, e, key->v.Constant.value); + goto error; + } + if (PySet_Add(seen, key->v.Constant.value)) { + goto error; + } + } + + else if (key->kind != Attribute_kind) { + const char *e = "mapping pattern keys may only match literals and attribute lookups"; + compiler_error(c, e); + goto error; + } + if (!compiler_visit_expr(c, key)) { + goto error; + } + } + + // all keys have been checked; there are no duplicates + Py_DECREF(seen); + + ADDOP_I(c, BUILD_TUPLE, size); + ADDOP(c, MATCH_KEYS); + // There's now a tuple of keys and a tuple of values on top of the subject: + pc->on_top += 2; + RETURN_IF_FALSE(jump_to_fail_pop(c, pc, POP_JUMP_IF_FALSE)); + // So far so good. Use that tuple of values on the stack to match + // sub-patterns against: + for (Py_ssize_t i = 0; i < size; i++) { + pattern_ty pattern = asdl_seq_GET(patterns, i); + if (WILDCARD_CHECK(pattern)) { + continue; + } + ADDOP(c, DUP_TOP); + ADDOP_LOAD_CONST_NEW(c, PyLong_FromSsize_t(i)); + ADDOP(c, BINARY_SUBSCR); + RETURN_IF_FALSE(compiler_pattern_subpattern(c, pattern, pc)); + } + // If we get this far, it's a match! We're done with the tuple of values, + // and whatever happens next should consume the tuple of keys underneath it: + pc->on_top -= 2; + ADDOP(c, POP_TOP); + if (star_target) { + // If we have a starred name, bind a dict of remaining items to it: + ADDOP(c, COPY_DICT_WITHOUT_KEYS); + RETURN_IF_FALSE(pattern_helper_store_name(c, star_target, pc)); + } + else { + // Otherwise, we don't care about this tuple of keys anymore: + ADDOP(c, POP_TOP); + } + // Pop the subject: + pc->on_top--; + ADDOP(c, POP_TOP); + return 1; + +error: + Py_DECREF(seen); + return 0; +} + +static int +compiler_pattern_or(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + assert(p->kind == MatchOr_kind); + basicblock *end; + RETURN_IF_FALSE(end = compiler_new_block(c)); + Py_ssize_t size = asdl_seq_LEN(p->v.MatchOr.patterns); + assert(size > 1); + // We're going to be messing with pc. Keep the original info handy: + pattern_context old_pc = *pc; + Py_INCREF(pc->stores); + // control is the list of names bound by the first alternative. It is used + // for checking different name bindings in alternatives, and for correcting + // the order in which extracted elements are placed on the stack. + PyObject *control = NULL; + // NOTE: We can't use returning macros anymore! goto error on error. + for (Py_ssize_t i = 0; i < size; i++) { + pattern_ty alt = asdl_seq_GET(p->v.MatchOr.patterns, i); + SET_LOC(c, alt); + PyObject *pc_stores = PyList_New(0); + if (pc_stores == NULL) { + goto error; + } + Py_SETREF(pc->stores, pc_stores); + // An irrefutable sub-pattern must be last, if it is allowed at all: + pc->allow_irrefutable = (i == size - 1) && old_pc.allow_irrefutable; + pc->fail_pop = NULL; + pc->fail_pop_size = 0; + pc->on_top = 0; + if (!compiler_addop(c, DUP_TOP) || !compiler_pattern(c, alt, pc)) { + goto error; + } + // Success! + Py_ssize_t nstores = PyList_GET_SIZE(pc->stores); + if (!i) { + // This is the first alternative, so save its stores as a "control" + // for the others (they can't bind a different set of names, and + // might need to be reordered): + assert(control == NULL); + control = pc->stores; + Py_INCREF(control); + } + else if (nstores != PyList_GET_SIZE(control)) { + goto diff; + } + else if (nstores) { + // There were captures. Check to see if we differ from control: + Py_ssize_t icontrol = nstores; + while (icontrol--) { + PyObject *name = PyList_GET_ITEM(control, icontrol); + Py_ssize_t istores = PySequence_Index(pc->stores, name); + if (istores < 0) { + PyErr_Clear(); + goto diff; + } + if (icontrol != istores) { + // Reorder the names on the stack to match the order of the + // names in control. There's probably a better way of doing + // this; the current solution is potentially very + // inefficient when each alternative subpattern binds lots + // of names in different orders. It's fine for reasonable + // cases, though. + assert(istores < icontrol); + Py_ssize_t rotations = istores + 1; + // Perform the same rotation on pc->stores: + PyObject *rotated = PyList_GetSlice(pc->stores, 0, + rotations); + if (rotated == NULL || + PyList_SetSlice(pc->stores, 0, rotations, NULL) || + PyList_SetSlice(pc->stores, icontrol - istores, + icontrol - istores, rotated)) + { + Py_XDECREF(rotated); + goto error; + } + Py_DECREF(rotated); + // That just did: + // rotated = pc_stores[:rotations] + // del pc_stores[:rotations] + // pc_stores[icontrol-istores:icontrol-istores] = rotated + // Do the same thing to the stack, using several ROT_Ns: + while (rotations--) { + if (!compiler_addop_i(c, ROT_N, icontrol + 1)) { + goto error; + } + } + } + } + } + assert(control); + if (!compiler_addop_j(c, JUMP_FORWARD, end) || + !compiler_next_block(c) || + !emit_and_reset_fail_pop(c, pc)) + { + goto error; + } + } + Py_DECREF(pc->stores); + *pc = old_pc; + Py_INCREF(pc->stores); + // Need to NULL this for the PyObject_Free call in the error block. + old_pc.fail_pop = NULL; + // No match. Pop the remaining copy of the subject and fail: + if (!compiler_addop(c, POP_TOP) || !jump_to_fail_pop(c, pc, JUMP_FORWARD)) { + goto error; + } + compiler_use_next_block(c, end); + Py_ssize_t nstores = PyList_GET_SIZE(control); + // There's a bunch of stuff on the stack between any where the new stores + // are and where they need to be: + // - The other stores. + // - A copy of the subject. + // - Anything else that may be on top of the stack. + // - Any previous stores we've already stashed away on the stack. + Py_ssize_t nrots = nstores + 1 + pc->on_top + PyList_GET_SIZE(pc->stores); + for (Py_ssize_t i = 0; i < nstores; i++) { + // Rotate this capture to its proper place on the stack: + if (!compiler_addop_i(c, ROT_N, nrots)) { + goto error; + } + // Update the list of previous stores with this new name, checking for + // duplicates: + PyObject *name = PyList_GET_ITEM(control, i); + int dupe = PySequence_Contains(pc->stores, name); + if (dupe < 0) { + goto error; + } + if (dupe) { + compiler_error_duplicate_store(c, name); + goto error; + } + if (PyList_Append(pc->stores, name)) { + goto error; + } + } + Py_DECREF(old_pc.stores); + Py_DECREF(control); + // NOTE: Returning macros are safe again. + // Pop the copy of the subject: + ADDOP(c, POP_TOP); + return 1; +diff: + compiler_error(c, "alternative patterns bind different names"); +error: + PyObject_Free(old_pc.fail_pop); + Py_DECREF(old_pc.stores); + Py_XDECREF(control); + return 0; +} + + +static int +compiler_pattern_sequence(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + assert(p->kind == MatchSequence_kind); + asdl_pattern_seq *patterns = p->v.MatchSequence.patterns; + Py_ssize_t size = asdl_seq_LEN(patterns); + Py_ssize_t star = -1; + int only_wildcard = 1; + int star_wildcard = 0; + // Find a starred name, if it exists. There may be at most one: + for (Py_ssize_t i = 0; i < size; i++) { + pattern_ty pattern = asdl_seq_GET(patterns, i); + if (pattern->kind == MatchStar_kind) { + if (star >= 0) { + const char *e = "multiple starred names in sequence pattern"; + return compiler_error(c, e); + } + star_wildcard = WILDCARD_STAR_CHECK(pattern); + only_wildcard &= star_wildcard; + star = i; + continue; + } + only_wildcard &= WILDCARD_CHECK(pattern); + } + // We need to keep the subject on top during the sequence and length checks: + pc->on_top++; + ADDOP(c, MATCH_SEQUENCE); + RETURN_IF_FALSE(jump_to_fail_pop(c, pc, POP_JUMP_IF_FALSE)); + if (star < 0) { + // No star: len(subject) == size + ADDOP(c, GET_LEN); + ADDOP_LOAD_CONST_NEW(c, PyLong_FromSsize_t(size)); + ADDOP_COMPARE(c, Eq); + RETURN_IF_FALSE(jump_to_fail_pop(c, pc, POP_JUMP_IF_FALSE)); + } + else if (size > 1) { + // Star: len(subject) >= size - 1 + ADDOP(c, GET_LEN); + ADDOP_LOAD_CONST_NEW(c, PyLong_FromSsize_t(size - 1)); + ADDOP_COMPARE(c, GtE); + RETURN_IF_FALSE(jump_to_fail_pop(c, pc, POP_JUMP_IF_FALSE)); + } + // Whatever comes next should consume the subject: + pc->on_top--; + if (only_wildcard) { + // Patterns like: [] / [_] / [_, _] / [*_] / [_, *_] / [_, _, *_] / etc. + ADDOP(c, POP_TOP); + } + else if (star_wildcard) { + RETURN_IF_FALSE(pattern_helper_sequence_subscr(c, patterns, star, pc)); + } + else { + RETURN_IF_FALSE(pattern_helper_sequence_unpack(c, patterns, star, pc)); + } + return 1; +} + +static int +compiler_pattern_value(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + assert(p->kind == MatchValue_kind); + expr_ty value = p->v.MatchValue.value; + if (!MATCH_VALUE_EXPR(value)) { + const char *e = "patterns may only match literals and attribute lookups"; + return compiler_error(c, e); + } + VISIT(c, expr, value); + ADDOP_COMPARE(c, Eq); + RETURN_IF_FALSE(jump_to_fail_pop(c, pc, POP_JUMP_IF_FALSE)); + return 1; +} + +static int +compiler_pattern_singleton(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + assert(p->kind == MatchSingleton_kind); + ADDOP_LOAD_CONST(c, p->v.MatchSingleton.value); + ADDOP_COMPARE(c, Is); + RETURN_IF_FALSE(jump_to_fail_pop(c, pc, POP_JUMP_IF_FALSE)); + return 1; +} + +static int +compiler_pattern(struct compiler *c, pattern_ty p, pattern_context *pc) +{ + SET_LOC(c, p); + switch (p->kind) { + case MatchValue_kind: + return compiler_pattern_value(c, p, pc); + case MatchSingleton_kind: + return compiler_pattern_singleton(c, p, pc); + case MatchSequence_kind: + return compiler_pattern_sequence(c, p, pc); + case MatchMapping_kind: + return compiler_pattern_mapping(c, p, pc); + case MatchClass_kind: + return compiler_pattern_class(c, p, pc); + case MatchStar_kind: + return compiler_pattern_star(c, p, pc); + case MatchAs_kind: + return compiler_pattern_as(c, p, pc); + case MatchOr_kind: + return compiler_pattern_or(c, p, pc); + } + // AST validator shouldn't let this happen, but if it does, + // just fail, don't crash out of the interpreter + const char *e = "invalid match pattern node in AST (kind=%d)"; + return compiler_error(c, e, p->kind); +} + +static int +compiler_match_inner(struct compiler *c, stmt_ty s, pattern_context *pc) +{ + VISIT(c, expr, s->v.Match.subject); + basicblock *end; + RETURN_IF_FALSE(end = compiler_new_block(c)); + Py_ssize_t cases = asdl_seq_LEN(s->v.Match.cases); + assert(cases > 0); + match_case_ty m = asdl_seq_GET(s->v.Match.cases, cases - 1); + int has_default = WILDCARD_CHECK(m->pattern) && 1 < cases; + for (Py_ssize_t i = 0; i < cases - has_default; i++) { + m = asdl_seq_GET(s->v.Match.cases, i); + SET_LOC(c, m->pattern); + // Only copy the subject if we're *not* on the last case: + if (i != cases - has_default - 1) { + ADDOP(c, DUP_TOP); + } + RETURN_IF_FALSE(pc->stores = PyList_New(0)); + // Irrefutable cases must be either guarded, last, or both: + pc->allow_irrefutable = m->guard != NULL || i == cases - 1; + pc->fail_pop = NULL; + pc->fail_pop_size = 0; + pc->on_top = 0; + // NOTE: Can't use returning macros here (they'll leak pc->stores)! + if (!compiler_pattern(c, m->pattern, pc)) { + Py_DECREF(pc->stores); + return 0; + } + assert(!pc->on_top); + // It's a match! Store all of the captured names (they're on the stack). + Py_ssize_t nstores = PyList_GET_SIZE(pc->stores); + for (Py_ssize_t n = 0; n < nstores; n++) { + PyObject *name = PyList_GET_ITEM(pc->stores, n); + if (!compiler_nameop(c, name, Store)) { + Py_DECREF(pc->stores); + return 0; + } + } + Py_DECREF(pc->stores); + // NOTE: Returning macros are safe again. + if (m->guard) { + RETURN_IF_FALSE(ensure_fail_pop(c, pc, 0)); + RETURN_IF_FALSE(compiler_jump_if(c, m->guard, pc->fail_pop[0], 0)); + } + // Success! Pop the subject off, we're done with it: + if (i != cases - has_default - 1) { + ADDOP(c, POP_TOP); + } + VISIT_SEQ(c, stmt, m->body); + ADDOP_JUMP(c, JUMP_FORWARD, end); + // If the pattern fails to match, we want the line number of the + // cleanup to be associated with the failed pattern, not the last line + // of the body + SET_LOC(c, m->pattern); + RETURN_IF_FALSE(emit_and_reset_fail_pop(c, pc)); + } + if (has_default) { + // A trailing "case _" is common, and lets us save a bit of redundant + // pushing and popping in the loop above: + m = asdl_seq_GET(s->v.Match.cases, cases - 1); + SET_LOC(c, m->pattern); + if (cases == 1) { + // No matches. Done with the subject: + ADDOP(c, POP_TOP); + } + else { + // Show line coverage for default case (it doesn't create bytecode) + ADDOP(c, NOP); + } + if (m->guard) { + RETURN_IF_FALSE(compiler_jump_if(c, m->guard, end, 0)); + } + VISIT_SEQ(c, stmt, m->body); + } + compiler_use_next_block(c, end); + return 1; +} + +static int +compiler_match(struct compiler *c, stmt_ty s) +{ + pattern_context pc; + pc.fail_pop = NULL; + int result = compiler_match_inner(c, s, &pc); + PyObject_Free(pc.fail_pop); + return result; +} + +#undef WILDCARD_CHECK +#undef WILDCARD_STAR_CHECK + /* End of the compiler section, beginning of the assembler section */ /* do depth-first search of basic block graph, starting with block. @@ -5438,39 +6460,14 @@ struct assembler { PyObject *a_bytecode; /* string containing bytecode */ int a_offset; /* offset into bytecode */ int a_nblocks; /* number of reachable blocks */ - basicblock **a_postorder; /* list of blocks in dfs postorder */ PyObject *a_lnotab; /* string containing lnotab */ int a_lnotab_off; /* offset into lnotab */ - int a_lineno; /* last lineno of emitted instruction */ - int a_lineno_off; /* bytecode offset of last lineno */ + int a_prevlineno; /* lineno of last emitted line in line table */ + int a_lineno; /* lineno of last emitted instruction */ + int a_lineno_start; /* bytecode start offset of current lineno */ + basicblock *a_entry; }; -static void -dfs(struct compiler *c, basicblock *b, struct assembler *a, int end) -{ - int i, j; - - /* Get rid of recursion for normal control flow. - Since the number of blocks is limited, unused space in a_postorder - (from a_nblocks to end) can be used as a stack for still not ordered - blocks. */ - for (j = end; b && !b->b_seen; b = b->b_next) { - b->b_seen = 1; - assert(a->a_nblocks < j); - a->a_postorder[--j] = b; - } - while (j < end) { - b = a->a_postorder[j++]; - for (i = 0; i < b->b_iused; i++) { - struct instr *instr = &b->b_instr[i]; - if (instr->i_jrel || instr->i_jabs) - dfs(c, instr->i_target, a, j); - } - assert(a->a_nblocks < j); - a->a_postorder[a->a_nblocks++] = b; - } -} - Py_LOCAL_INLINE(void) stackdepth_push(basicblock ***sp, basicblock *b, int depth) { @@ -5496,8 +6493,7 @@ stackdepth(struct compiler *c) entryblock = b; nblocks++; } - if (!entryblock) - return 0; + assert(entryblock!= NULL); stack = (basicblock **)PyObject_Malloc(sizeof(basicblock *) * nblocks); if (!stack) { PyErr_NoMemory(); @@ -5505,7 +6501,11 @@ stackdepth(struct compiler *c) } sp = stack; - stackdepth_push(&sp, entryblock, 0); + if (c->u->u_ste->ste_generator || c->u->u_ste->ste_coroutine) { + stackdepth_push(&sp, entryblock, 1); + } else { + stackdepth_push(&sp, entryblock, 0); + } while (sp != stack) { b = *--sp; int depth = b->b_startdepth; @@ -5515,15 +6515,17 @@ stackdepth(struct compiler *c) struct instr *instr = &b->b_instr[i]; int effect = stack_effect(instr->i_opcode, instr->i_oparg, 0); if (effect == PY_INVALID_STACK_EFFECT) { - _Py_FatalErrorFormat(__func__, - "opcode = %d", instr->i_opcode); + PyErr_Format(PyExc_SystemError, + "compiler stack_effect(opcode=%d, arg=%i) failed", + instr->i_opcode, instr->i_oparg); + return -1; } int new_depth = depth + effect; if (new_depth > maxdepth) { maxdepth = new_depth; } assert(depth >= 0); /* invalid code or bug in stackdepth() */ - if (instr->i_jrel || instr->i_jabs) { + if (is_jump(instr)) { effect = stack_effect(instr->i_opcode, instr->i_oparg, 1); assert(effect != PY_INVALID_STACK_EFFECT); int target_depth = depth + effect; @@ -5546,6 +6548,7 @@ stackdepth(struct compiler *c) } } if (next != NULL) { + assert(b->b_nofallthrough == 0); stackdepth_push(&sp, next, depth); } } @@ -5557,24 +6560,25 @@ static int assemble_init(struct assembler *a, int nblocks, int firstlineno) { memset(a, 0, sizeof(struct assembler)); - a->a_lineno = firstlineno; + a->a_prevlineno = a->a_lineno = firstlineno; + a->a_lnotab = NULL; a->a_bytecode = PyBytes_FromStringAndSize(NULL, DEFAULT_CODE_SIZE); - if (!a->a_bytecode) - return 0; + if (a->a_bytecode == NULL) { + goto error; + } a->a_lnotab = PyBytes_FromStringAndSize(NULL, DEFAULT_LNOTAB_SIZE); - if (!a->a_lnotab) - return 0; - if ((size_t)nblocks > SIZE_MAX / sizeof(basicblock *)) { - PyErr_NoMemory(); - return 0; + if (a->a_lnotab == NULL) { + goto error; } - a->a_postorder = (basicblock **)PyObject_Malloc( - sizeof(basicblock *) * nblocks); - if (!a->a_postorder) { + if ((size_t)nblocks > SIZE_MAX / sizeof(basicblock *)) { PyErr_NoMemory(); - return 0; + goto error; } return 1; +error: + Py_XDECREF(a->a_bytecode); + Py_XDECREF(a->a_lnotab); + return 0; } static void @@ -5582,8 +6586,6 @@ assemble_free(struct assembler *a) { Py_XDECREF(a->a_bytecode); Py_XDECREF(a->a_lnotab); - if (a->a_postorder) - PyObject_Free(a->a_postorder); } static int @@ -5597,114 +6599,81 @@ blocksize(basicblock *b) return size; } -/* Appends a pair to the end of the line number table, a_lnotab, representing - the instruction's bytecode offset and line number. See - Objects/lnotab_notes.txt for the description of the line number table. */ - static int -assemble_lnotab(struct assembler *a, struct instr *i) +assemble_emit_linetable_pair(struct assembler *a, int bdelta, int ldelta) { - int d_bytecode, d_lineno; - Py_ssize_t len; - unsigned char *lnotab; - - d_lineno = i->i_lineno - a->a_lineno; - if (d_lineno == 0) { - return 1; + Py_ssize_t len = PyBytes_GET_SIZE(a->a_lnotab); + if (a->a_lnotab_off + 2 >= len) { + if (_PyBytes_Resize(&a->a_lnotab, len * 2) < 0) + return 0; } + unsigned char *lnotab = (unsigned char *) PyBytes_AS_STRING(a->a_lnotab); + lnotab += a->a_lnotab_off; + a->a_lnotab_off += 2; + *lnotab++ = bdelta; + *lnotab++ = ldelta; + return 1; +} - d_bytecode = (a->a_offset - a->a_lineno_off) * sizeof(_Py_CODEUNIT); - assert(d_bytecode >= 0); +/* Appends a range to the end of the line number table. See + * Objects/lnotab_notes.txt for the description of the line number table. */ - if (d_bytecode > 255) { - int j, nbytes, ncodes = d_bytecode / 255; - nbytes = a->a_lnotab_off + 2 * ncodes; - len = PyBytes_GET_SIZE(a->a_lnotab); - if (nbytes >= len) { - if ((len <= INT_MAX / 2) && (len * 2 < nbytes)) - len = nbytes; - else if (len <= INT_MAX / 2) - len *= 2; - else { - PyErr_NoMemory(); +static int +assemble_line_range(struct assembler *a) +{ + int ldelta, bdelta; + bdelta = (a->a_offset - a->a_lineno_start) * sizeof(_Py_CODEUNIT); + if (bdelta == 0) { + return 1; + } + if (a->a_lineno < 0) { + ldelta = -128; + } + else { + ldelta = a->a_lineno - a->a_prevlineno; + a->a_prevlineno = a->a_lineno; + while (ldelta > 127) { + if (!assemble_emit_linetable_pair(a, 0, 127)) { return 0; } - if (_PyBytes_Resize(&a->a_lnotab, len) < 0) - return 0; - } - lnotab = (unsigned char *) - PyBytes_AS_STRING(a->a_lnotab) + a->a_lnotab_off; - for (j = 0; j < ncodes; j++) { - *lnotab++ = 255; - *lnotab++ = 0; + ldelta -= 127; } - d_bytecode -= ncodes * 255; - a->a_lnotab_off += ncodes * 2; - } - assert(0 <= d_bytecode && d_bytecode <= 255); - - if (d_lineno < -128 || 127 < d_lineno) { - int j, nbytes, ncodes, k; - if (d_lineno < 0) { - k = -128; - /* use division on positive numbers */ - ncodes = (-d_lineno) / 128; - } - else { - k = 127; - ncodes = d_lineno / 127; - } - d_lineno -= ncodes * k; - assert(ncodes >= 1); - nbytes = a->a_lnotab_off + 2 * ncodes; - len = PyBytes_GET_SIZE(a->a_lnotab); - if (nbytes >= len) { - if ((len <= INT_MAX / 2) && len * 2 < nbytes) - len = nbytes; - else if (len <= INT_MAX / 2) - len *= 2; - else { - PyErr_NoMemory(); + while (ldelta < -127) { + if (!assemble_emit_linetable_pair(a, 0, -127)) { return 0; } - if (_PyBytes_Resize(&a->a_lnotab, len) < 0) - return 0; + ldelta += 127; } - lnotab = (unsigned char *) - PyBytes_AS_STRING(a->a_lnotab) + a->a_lnotab_off; - *lnotab++ = d_bytecode; - *lnotab++ = k; - d_bytecode = 0; - for (j = 1; j < ncodes; j++) { - *lnotab++ = 0; - *lnotab++ = k; - } - a->a_lnotab_off += ncodes * 2; } - assert(-128 <= d_lineno && d_lineno <= 127); - - len = PyBytes_GET_SIZE(a->a_lnotab); - if (a->a_lnotab_off + 2 >= len) { - if (_PyBytes_Resize(&a->a_lnotab, len * 2) < 0) + assert(-128 <= ldelta && ldelta < 128); + while (bdelta > 254) { + if (!assemble_emit_linetable_pair(a, 254, ldelta)) { return 0; + } + ldelta = a->a_lineno < 0 ? -128 : 0; + bdelta -= 254; + } + if (!assemble_emit_linetable_pair(a, bdelta, ldelta)) { + return 0; } - lnotab = (unsigned char *) - PyBytes_AS_STRING(a->a_lnotab) + a->a_lnotab_off; + a->a_lineno_start = a->a_offset; + return 1; +} - a->a_lnotab_off += 2; - if (d_bytecode) { - *lnotab++ = d_bytecode; - *lnotab++ = d_lineno; +static int +assemble_lnotab(struct assembler *a, struct instr *i) +{ + if (i->i_lineno == a->a_lineno) { + return 1; } - else { /* First line of a block; def stmt, etc. */ - *lnotab++ = 0; - *lnotab++ = d_lineno; + if (!assemble_line_range(a)) { + return 0; } a->a_lineno = i->i_lineno; - a->a_lineno_off = a->a_offset; return 1; } + /* assemble_emit() Extend the bytecode with a new instruction. Update lnotab if necessary. @@ -5734,6 +6703,31 @@ assemble_emit(struct assembler *a, struct instr *i) } static void +normalize_jumps(struct assembler *a) +{ + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { + b->b_visited = 0; + } + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { + b->b_visited = 1; + if (b->b_iused == 0) { + continue; + } + struct instr *last = &b->b_instr[b->b_iused-1]; + if (last->i_opcode == JUMP_ABSOLUTE) { + if (last->i_target->b_visited == 0) { + last->i_opcode = JUMP_FORWARD; + } + } + if (last->i_opcode == JUMP_FORWARD) { + if (last->i_target->b_visited == 1) { + last->i_opcode = JUMP_ABSOLUTE; + } + } + } +} + +static void assemble_jump_offsets(struct assembler *a, struct compiler *c) { basicblock *b; @@ -5744,8 +6738,7 @@ assemble_jump_offsets(struct assembler *a, struct compiler *c) Replace block pointer with position in bytecode. */ do { totsize = 0; - for (i = a->a_nblocks - 1; i >= 0; i--) { - b = a->a_postorder[i]; + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { bsize = blocksize(b); b->b_offset = totsize; totsize += bsize; @@ -5761,12 +6754,11 @@ assemble_jump_offsets(struct assembler *a, struct compiler *c) the jump instruction. */ bsize += isize; - if (instr->i_jabs || instr->i_jrel) { + if (is_jump(instr)) { instr->i_oparg = instr->i_target->b_offset; - if (instr->i_jrel) { + if (is_relative_jump(instr)) { instr->i_oparg -= bsize; } - instr->i_oparg *= sizeof(_Py_CODEUNIT); if (instrsize(instr->i_oparg) != isize) { extended_arg_recompile = 1; } @@ -5821,7 +6813,7 @@ consts_dict_keys_inorder(PyObject *dict) return NULL; while (PyDict_Next(dict, &pos, &k, &v)) { i = PyLong_AS_LONG(v); - /* The keys of the dictionary can be tuples wrapping a contant. + /* The keys of the dictionary can be tuples wrapping a constant. * (see compiler_add_o and _PyCode_ConstantKey). In that case * the object we want is always second. */ if (PyTuple_CheckExact(k)) { @@ -5868,14 +6860,12 @@ compute_code_flags(struct compiler *c) return flags; } -// Merge *tuple* with constant cache. +// Merge *obj* with constant cache. // Unlike merge_consts_recursive(), this function doesn't work recursively. static int -merge_const_tuple(struct compiler *c, PyObject **tuple) +merge_const_one(struct compiler *c, PyObject **obj) { - assert(PyTuple_CheckExact(*tuple)); - - PyObject *key = _PyCode_ConstantKey(*tuple); + PyObject *key = _PyCode_ConstantKey(*obj); if (key == NULL) { return 0; } @@ -5886,40 +6876,40 @@ merge_const_tuple(struct compiler *c, PyObject **tuple) if (t == NULL) { return 0; } - if (t == key) { // tuple is new constant. + if (t == key) { // obj is new constant. return 1; } - PyObject *u = PyTuple_GET_ITEM(t, 1); - Py_INCREF(u); - Py_DECREF(*tuple); - *tuple = u; + if (PyTuple_CheckExact(t)) { + // t is still borrowed reference + t = PyTuple_GET_ITEM(t, 1); + } + + Py_INCREF(t); + Py_DECREF(*obj); + *obj = t; return 1; } static PyCodeObject * -makecode(struct compiler *c, struct assembler *a) +makecode(struct compiler *c, struct assembler *a, PyObject *consts) { - PyObject *tmp; PyCodeObject *co = NULL; - PyObject *consts = NULL; PyObject *names = NULL; PyObject *varnames = NULL; PyObject *name = NULL; PyObject *freevars = NULL; PyObject *cellvars = NULL; - PyObject *bytecode = NULL; Py_ssize_t nlocals; int nlocals_int; int flags; int posorkeywordargcount, posonlyargcount, kwonlyargcount, maxdepth; - consts = consts_dict_keys_inorder(c->u->u_consts); names = dict_keys_inorder(c->u->u_names, 0); varnames = dict_keys_inorder(c->u->u_varnames, 0); - if (!consts || !names || !varnames) + if (!names || !varnames) { goto error; - + } cellvars = dict_keys_inorder(c->u->u_cellvars, 0); if (!cellvars) goto error; @@ -5927,10 +6917,10 @@ makecode(struct compiler *c, struct assembler *a) if (!freevars) goto error; - if (!merge_const_tuple(c, &names) || - !merge_const_tuple(c, &varnames) || - !merge_const_tuple(c, &cellvars) || - !merge_const_tuple(c, &freevars)) + if (!merge_const_one(c, &names) || + !merge_const_one(c, &varnames) || + !merge_const_one(c, &cellvars) || + !merge_const_one(c, &freevars)) { goto error; } @@ -5943,16 +6933,12 @@ makecode(struct compiler *c, struct assembler *a) if (flags < 0) goto error; - bytecode = PyCode_Optimize(a->a_bytecode, consts, names, a->a_lnotab); - if (!bytecode) - goto error; - - tmp = PyList_AsTuple(consts); /* PyCode_New requires a tuple */ - if (!tmp) + consts = PyList_AsTuple(consts); /* PyCode_New requires a tuple */ + if (consts == NULL) { goto error; - Py_DECREF(consts); - consts = tmp; - if (!merge_const_tuple(c, &consts)) { + } + if (!merge_const_one(c, &consts)) { + Py_DECREF(consts); goto error; } @@ -5961,21 +6947,28 @@ makecode(struct compiler *c, struct assembler *a) kwonlyargcount = Py_SAFE_DOWNCAST(c->u->u_kwonlyargcount, Py_ssize_t, int); maxdepth = stackdepth(c); if (maxdepth < 0) { + Py_DECREF(consts); + goto error; + } + if (maxdepth > MAX_ALLOWED_STACK_USE) { + PyErr_Format(PyExc_SystemError, + "excessive stack use: stack is %d deep", + maxdepth); + Py_DECREF(consts); goto error; } co = PyCode_NewWithPosOnlyArgs(posonlyargcount+posorkeywordargcount, posonlyargcount, kwonlyargcount, nlocals_int, - maxdepth, flags, bytecode, consts, names, + maxdepth, flags, a->a_bytecode, consts, names, varnames, freevars, cellvars, c->c_filename, c->u->u_name, c->u->u_firstlineno, a->a_lnotab); + Py_DECREF(consts); error: - Py_XDECREF(consts); Py_XDECREF(names); Py_XDECREF(varnames); Py_XDECREF(name); Py_XDECREF(freevars); Py_XDECREF(cellvars); - Py_XDECREF(bytecode); return co; } @@ -5983,10 +6976,11 @@ makecode(struct compiler *c, struct assembler *a) /* For debugging purposes only */ #if 0 static void -dump_instr(const struct instr *i) +dump_instr(struct instr *i) { - const char *jrel = i->i_jrel ? "jrel " : ""; - const char *jabs = i->i_jabs ? "jabs " : ""; + const char *jrel = (is_relative_jump(i)) ? "jrel " : ""; + const char *jabs = (is_jump(i) && !is_relative_jump(i))? "jabs " : ""; + char arg[128]; *arg = '\0'; @@ -6000,10 +6994,9 @@ dump_instr(const struct instr *i) static void dump_basicblock(const basicblock *b) { - const char *seen = b->b_seen ? "seen " : ""; const char *b_return = b->b_return ? "return " : ""; - fprintf(stderr, "used: %d, depth: %d, offset: %d %s%s\n", - b->b_iused, b->b_startdepth, b->b_offset, seen, b_return); + fprintf(stderr, "used: %d, depth: %d, offset: %d %s\n", + b->b_iused, b->b_startdepth, b->b_offset, b_return); if (b->b_instr) { int i; for (i = 0; i < b->b_iused; i++) { @@ -6014,69 +7007,910 @@ dump_basicblock(const basicblock *b) } #endif + +static int +normalize_basic_block(basicblock *bb); + +static int +optimize_cfg(struct compiler *c, struct assembler *a, PyObject *consts); + +static int +trim_unused_consts(struct compiler *c, struct assembler *a, PyObject *consts); + +/* Duplicates exit BBs, so that line numbers can be propagated to them */ +static int +duplicate_exits_without_lineno(struct compiler *c); + +static int +extend_block(basicblock *bb); + +static int +insert_generator_prefix(struct compiler *c, basicblock *entryblock) { + + int flags = compute_code_flags(c); + if (flags < 0) { + return -1; + } + int kind; + if (flags & (CO_GENERATOR | CO_COROUTINE | CO_ASYNC_GENERATOR)) { + if (flags & CO_COROUTINE) { + kind = 1; + } + else if (flags & CO_ASYNC_GENERATOR) { + kind = 2; + } + else { + kind = 0; + } + } + else { + return 0; + } + if (compiler_next_instr(entryblock) < 0) { + return -1; + } + for (int i = entryblock->b_iused-1; i > 0; i--) { + entryblock->b_instr[i] = entryblock->b_instr[i-1]; + } + entryblock->b_instr[0].i_opcode = GEN_START; + entryblock->b_instr[0].i_oparg = kind; + entryblock->b_instr[0].i_lineno = -1; + entryblock->b_instr[0].i_target = NULL; + return 0; +} + +/* Make sure that all returns have a line number, even if early passes + * have failed to propagate a correct line number. + * The resulting line number may not be correct according to PEP 626, + * but should be "good enough", and no worse than in older versions. */ +static void +guarantee_lineno_for_exits(struct assembler *a, int firstlineno) { + int lineno = firstlineno; + assert(lineno > 0); + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { + if (b->b_iused == 0) { + continue; + } + struct instr *last = &b->b_instr[b->b_iused-1]; + if (last->i_lineno < 0) { + if (last->i_opcode == RETURN_VALUE) { + for (int i = 0; i < b->b_iused; i++) { + assert(b->b_instr[i].i_lineno < 0); + + b->b_instr[i].i_lineno = lineno; + } + } + } + else { + lineno = last->i_lineno; + } + } +} + +static void +propagate_line_numbers(struct assembler *a); + static PyCodeObject * assemble(struct compiler *c, int addNone) { basicblock *b, *entryblock; struct assembler a; - int i, j, nblocks; + int j, nblocks; PyCodeObject *co = NULL; + PyObject *consts = NULL; /* Make sure every block that falls off the end returns None. XXX NEXT_BLOCK() isn't quite right, because if the last block ends with a jump or return b_next shouldn't set. */ if (!c->u->u_curblock->b_return) { - NEXT_BLOCK(c); + c->u->u_lineno = -1; if (addNone) ADDOP_LOAD_CONST(c, Py_None); ADDOP(c, RETURN_VALUE); } + for (basicblock *b = c->u->u_blocks; b != NULL; b = b->b_list) { + if (normalize_basic_block(b)) { + return NULL; + } + } + + for (basicblock *b = c->u->u_blocks; b != NULL; b = b->b_list) { + if (extend_block(b)) { + return NULL; + } + } + nblocks = 0; entryblock = NULL; for (b = c->u->u_blocks; b != NULL; b = b->b_list) { nblocks++; entryblock = b; } + assert(entryblock != NULL); + + if (insert_generator_prefix(c, entryblock)) { + goto error; + } /* Set firstlineno if it wasn't explicitly set. */ if (!c->u->u_firstlineno) { - if (entryblock && entryblock->b_instr && entryblock->b_instr->i_lineno) + if (entryblock->b_instr && entryblock->b_instr->i_lineno) c->u->u_firstlineno = entryblock->b_instr->i_lineno; - else + else c->u->u_firstlineno = 1; } + if (!assemble_init(&a, nblocks, c->u->u_firstlineno)) goto error; - dfs(c, entryblock, &a, nblocks); + a.a_entry = entryblock; + a.a_nblocks = nblocks; + + consts = consts_dict_keys_inorder(c->u->u_consts); + if (consts == NULL) { + goto error; + } + + if (optimize_cfg(c, &a, consts)) { + goto error; + } + if (duplicate_exits_without_lineno(c)) { + return NULL; + } + if (trim_unused_consts(c, &a, consts)) { + goto error; + } + propagate_line_numbers(&a); + guarantee_lineno_for_exits(&a, c->u->u_firstlineno); + + /* Order of basic blocks must have been determined by now */ + normalize_jumps(&a); /* Can't modify the bytecode after computing jump offsets. */ assemble_jump_offsets(&a, c); - /* Emit code in reverse postorder from dfs. */ - for (i = a.a_nblocks - 1; i >= 0; i--) { - b = a.a_postorder[i]; + /* Emit code. */ + for(b = entryblock; b != NULL; b = b->b_next) { for (j = 0; j < b->b_iused; j++) if (!assemble_emit(&a, &b->b_instr[j])) goto error; } + if (!assemble_line_range(&a)) { + return 0; + } - if (_PyBytes_Resize(&a.a_lnotab, a.a_lnotab_off) < 0) + if (_PyBytes_Resize(&a.a_lnotab, a.a_lnotab_off) < 0) { + goto error; + } + if (!merge_const_one(c, &a.a_lnotab)) { + goto error; + } + if (_PyBytes_Resize(&a.a_bytecode, a.a_offset * sizeof(_Py_CODEUNIT)) < 0) { goto error; - if (_PyBytes_Resize(&a.a_bytecode, a.a_offset * sizeof(_Py_CODEUNIT)) < 0) + } + if (!merge_const_one(c, &a.a_bytecode)) { goto error; + } - co = makecode(c, &a); + co = makecode(c, &a, consts); error: + Py_XDECREF(consts); assemble_free(&a); return co; } -#undef PyAST_Compile -PyCodeObject * -PyAST_Compile(mod_ty mod, const char *filename, PyCompilerFlags *flags, - PyArena *arena) +/* Replace LOAD_CONST c1, LOAD_CONST c2 ... LOAD_CONST cn, BUILD_TUPLE n + with LOAD_CONST (c1, c2, ... cn). + The consts table must still be in list form so that the + new constant (c1, c2, ... cn) can be appended. + Called with codestr pointing to the first LOAD_CONST. +*/ +static int +fold_tuple_on_constants(struct compiler *c, + struct instr *inst, + int n, PyObject *consts) +{ + /* Pre-conditions */ + assert(PyList_CheckExact(consts)); + assert(inst[n].i_opcode == BUILD_TUPLE); + assert(inst[n].i_oparg == n); + + for (int i = 0; i < n; i++) { + if (inst[i].i_opcode != LOAD_CONST) { + return 0; + } + } + + /* Buildup new tuple of constants */ + PyObject *newconst = PyTuple_New(n); + if (newconst == NULL) { + return -1; + } + for (int i = 0; i < n; i++) { + int arg = inst[i].i_oparg; + PyObject *constant = PyList_GET_ITEM(consts, arg); + Py_INCREF(constant); + PyTuple_SET_ITEM(newconst, i, constant); + } + if (merge_const_one(c, &newconst) == 0) { + Py_DECREF(newconst); + return -1; + } + + Py_ssize_t index; + for (index = 0; index < PyList_GET_SIZE(consts); index++) { + if (PyList_GET_ITEM(consts, index) == newconst) { + break; + } + } + if (index == PyList_GET_SIZE(consts)) { + if ((size_t)index >= (size_t)INT_MAX - 1) { + Py_DECREF(newconst); + PyErr_SetString(PyExc_OverflowError, "too many constants"); + return -1; + } + if (PyList_Append(consts, newconst)) { + Py_DECREF(newconst); + return -1; + } + } + Py_DECREF(newconst); + for (int i = 0; i < n; i++) { + inst[i].i_opcode = NOP; + } + inst[n].i_opcode = LOAD_CONST; + inst[n].i_oparg = (int)index; + return 0; +} + + +// Eliminate n * ROT_N(n). +static void +fold_rotations(struct instr *inst, int n) +{ + for (int i = 0; i < n; i++) { + int rot; + switch (inst[i].i_opcode) { + case ROT_N: + rot = inst[i].i_oparg; + break; + case ROT_FOUR: + rot = 4; + break; + case ROT_THREE: + rot = 3; + break; + case ROT_TWO: + rot = 2; + break; + default: + return; + } + if (rot != n) { + return; + } + } + for (int i = 0; i < n; i++) { + inst[i].i_opcode = NOP; + } +} + +// Attempt to eliminate jumps to jumps by updating inst to jump to +// target->i_target using the provided opcode. Return whether or not the +// optimization was successful. +static bool +jump_thread(struct instr *inst, struct instr *target, int opcode) +{ + assert(is_jump(inst)); + assert(is_jump(target)); + // bpo-45773: If inst->i_target == target->i_target, then nothing actually + // changes (and we fall into an infinite loop): + if (inst->i_lineno == target->i_lineno && + inst->i_target != target->i_target) + { + inst->i_target = target->i_target; + inst->i_opcode = opcode; + return true; + } + return false; +} + +/* Maximum size of basic block that should be copied in optimizer */ +#define MAX_COPY_SIZE 4 + +/* Optimization */ +static int +optimize_basic_block(struct compiler *c, basicblock *bb, PyObject *consts) +{ + assert(PyList_CheckExact(consts)); + struct instr nop; + nop.i_opcode = NOP; + struct instr *target; + for (int i = 0; i < bb->b_iused; i++) { + struct instr *inst = &bb->b_instr[i]; + int oparg = inst->i_oparg; + int nextop = i+1 < bb->b_iused ? bb->b_instr[i+1].i_opcode : 0; + if (is_jump(inst)) { + /* Skip over empty basic blocks. */ + while (inst->i_target->b_iused == 0) { + inst->i_target = inst->i_target->b_next; + } + target = &inst->i_target->b_instr[0]; + } + else { + target = &nop; + } + switch (inst->i_opcode) { + /* Remove LOAD_CONST const; conditional jump */ + case LOAD_CONST: + { + PyObject* cnt; + int is_true; + int jump_if_true; + switch(nextop) { + case POP_JUMP_IF_FALSE: + case POP_JUMP_IF_TRUE: + cnt = PyList_GET_ITEM(consts, oparg); + is_true = PyObject_IsTrue(cnt); + if (is_true == -1) { + goto error; + } + inst->i_opcode = NOP; + jump_if_true = nextop == POP_JUMP_IF_TRUE; + if (is_true == jump_if_true) { + bb->b_instr[i+1].i_opcode = JUMP_ABSOLUTE; + bb->b_nofallthrough = 1; + } + else { + bb->b_instr[i+1].i_opcode = NOP; + } + break; + case JUMP_IF_FALSE_OR_POP: + case JUMP_IF_TRUE_OR_POP: + cnt = PyList_GET_ITEM(consts, oparg); + is_true = PyObject_IsTrue(cnt); + if (is_true == -1) { + goto error; + } + jump_if_true = nextop == JUMP_IF_TRUE_OR_POP; + if (is_true == jump_if_true) { + bb->b_instr[i+1].i_opcode = JUMP_ABSOLUTE; + bb->b_nofallthrough = 1; + } + else { + inst->i_opcode = NOP; + bb->b_instr[i+1].i_opcode = NOP; + } + break; + } + break; + } + + /* Try to fold tuples of constants. + Skip over BUILD_SEQN 1 UNPACK_SEQN 1. + Replace BUILD_SEQN 2 UNPACK_SEQN 2 with ROT2. + Replace BUILD_SEQN 3 UNPACK_SEQN 3 with ROT3 ROT2. */ + case BUILD_TUPLE: + if (nextop == UNPACK_SEQUENCE && oparg == bb->b_instr[i+1].i_oparg) { + switch(oparg) { + case 1: + inst->i_opcode = NOP; + bb->b_instr[i+1].i_opcode = NOP; + break; + case 2: + inst->i_opcode = ROT_TWO; + bb->b_instr[i+1].i_opcode = NOP; + break; + case 3: + inst->i_opcode = ROT_THREE; + bb->b_instr[i+1].i_opcode = ROT_TWO; + } + break; + } + if (i >= oparg) { + if (fold_tuple_on_constants(c, inst-oparg, oparg, consts)) { + goto error; + } + } + break; + + /* Simplify conditional jump to conditional jump where the + result of the first test implies the success of a similar + test or the failure of the opposite test. + Arises in code like: + "a and b or c" + "(a and b) and c" + "(a or b) or c" + "(a or b) and c" + x:JUMP_IF_FALSE_OR_POP y y:JUMP_IF_FALSE_OR_POP z + --> x:JUMP_IF_FALSE_OR_POP z + x:JUMP_IF_FALSE_OR_POP y y:JUMP_IF_TRUE_OR_POP z + --> x:POP_JUMP_IF_FALSE y+1 + where y+1 is the instruction following the second test. + */ + case JUMP_IF_FALSE_OR_POP: + switch (target->i_opcode) { + case POP_JUMP_IF_FALSE: + i -= jump_thread(inst, target, POP_JUMP_IF_FALSE); + break; + case JUMP_ABSOLUTE: + case JUMP_FORWARD: + case JUMP_IF_FALSE_OR_POP: + i -= jump_thread(inst, target, JUMP_IF_FALSE_OR_POP); + break; + case JUMP_IF_TRUE_OR_POP: + case POP_JUMP_IF_TRUE: + if (inst->i_lineno == target->i_lineno) { + // We don't need to bother checking for loops here, + // since a block's b_next cannot point to itself: + assert(inst->i_target != inst->i_target->b_next); + inst->i_opcode = POP_JUMP_IF_FALSE; + inst->i_target = inst->i_target->b_next; + --i; + } + break; + } + break; + case JUMP_IF_TRUE_OR_POP: + switch (target->i_opcode) { + case POP_JUMP_IF_TRUE: + i -= jump_thread(inst, target, POP_JUMP_IF_TRUE); + break; + case JUMP_ABSOLUTE: + case JUMP_FORWARD: + case JUMP_IF_TRUE_OR_POP: + i -= jump_thread(inst, target, JUMP_IF_TRUE_OR_POP); + break; + case JUMP_IF_FALSE_OR_POP: + case POP_JUMP_IF_FALSE: + if (inst->i_lineno == target->i_lineno) { + // We don't need to bother checking for loops here, + // since a block's b_next cannot point to itself: + assert(inst->i_target != inst->i_target->b_next); + inst->i_opcode = POP_JUMP_IF_TRUE; + inst->i_target = inst->i_target->b_next; + --i; + } + break; + } + break; + case POP_JUMP_IF_FALSE: + switch (target->i_opcode) { + case JUMP_ABSOLUTE: + case JUMP_FORWARD: + i -= jump_thread(inst, target, POP_JUMP_IF_FALSE); + } + break; + case POP_JUMP_IF_TRUE: + switch (target->i_opcode) { + case JUMP_ABSOLUTE: + case JUMP_FORWARD: + i -= jump_thread(inst, target, POP_JUMP_IF_TRUE); + } + break; + case JUMP_ABSOLUTE: + case JUMP_FORWARD: + switch (target->i_opcode) { + case JUMP_ABSOLUTE: + case JUMP_FORWARD: + i -= jump_thread(inst, target, JUMP_ABSOLUTE); + } + break; + case FOR_ITER: + if (target->i_opcode == JUMP_FORWARD) { + i -= jump_thread(inst, target, FOR_ITER); + } + break; + case ROT_N: + switch (oparg) { + case 0: + case 1: + inst->i_opcode = NOP; + continue; + case 2: + inst->i_opcode = ROT_TWO; + break; + case 3: + inst->i_opcode = ROT_THREE; + break; + case 4: + inst->i_opcode = ROT_FOUR; + break; + } + if (i >= oparg - 1) { + fold_rotations(inst - oparg + 1, oparg); + } + break; + } + } + return 0; +error: + return -1; +} + +/* If this block ends with an unconditional jump to an exit block, + * then remove the jump and extend this block with the target. + */ +static int +extend_block(basicblock *bb) { + if (bb->b_iused == 0) { + return 0; + } + struct instr *last = &bb->b_instr[bb->b_iused-1]; + if (last->i_opcode != JUMP_ABSOLUTE && last->i_opcode != JUMP_FORWARD) { + return 0; + } + if (last->i_target->b_exit && last->i_target->b_iused <= MAX_COPY_SIZE) { + basicblock *to_copy = last->i_target; + last->i_opcode = NOP; + for (int i = 0; i < to_copy->b_iused; i++) { + int index = compiler_next_instr(bb); + if (index < 0) { + return -1; + } + bb->b_instr[index] = to_copy->b_instr[i]; + } + bb->b_exit = 1; + } + return 0; +} + +static void +clean_basic_block(basicblock *bb, int prev_lineno) { + /* Remove NOPs when legal to do so. */ + int dest = 0; + for (int src = 0; src < bb->b_iused; src++) { + int lineno = bb->b_instr[src].i_lineno; + if (bb->b_instr[src].i_opcode == NOP) { + /* Eliminate no-op if it doesn't have a line number */ + if (lineno < 0) { + continue; + } + /* or, if the previous instruction had the same line number. */ + if (prev_lineno == lineno) { + continue; + } + /* or, if the next instruction has same line number or no line number */ + if (src < bb->b_iused - 1) { + int next_lineno = bb->b_instr[src+1].i_lineno; + if (next_lineno < 0 || next_lineno == lineno) { + bb->b_instr[src+1].i_lineno = lineno; + continue; + } + } + else { + basicblock* next = bb->b_next; + while (next && next->b_iused == 0) { + next = next->b_next; + } + /* or if last instruction in BB and next BB has same line number */ + if (next) { + if (lineno == next->b_instr[0].i_lineno) { + continue; + } + } + } + + } + if (dest != src) { + bb->b_instr[dest] = bb->b_instr[src]; + } + dest++; + prev_lineno = lineno; + } + assert(dest <= bb->b_iused); + bb->b_iused = dest; +} + +static int +normalize_basic_block(basicblock *bb) { + /* Mark blocks as exit and/or nofallthrough. + Raise SystemError if CFG is malformed. */ + for (int i = 0; i < bb->b_iused; i++) { + switch(bb->b_instr[i].i_opcode) { + case RETURN_VALUE: + case RAISE_VARARGS: + case RERAISE: + bb->b_exit = 1; + bb->b_nofallthrough = 1; + break; + case JUMP_ABSOLUTE: + case JUMP_FORWARD: + bb->b_nofallthrough = 1; + /* fall through */ + case POP_JUMP_IF_FALSE: + case POP_JUMP_IF_TRUE: + case JUMP_IF_FALSE_OR_POP: + case JUMP_IF_TRUE_OR_POP: + case FOR_ITER: + if (i != bb->b_iused-1) { + PyErr_SetString(PyExc_SystemError, "malformed control flow graph."); + return -1; + } + /* Skip over empty basic blocks. */ + while (bb->b_instr[i].i_target->b_iused == 0) { + bb->b_instr[i].i_target = bb->b_instr[i].i_target->b_next; + } + + } + } + return 0; +} + +static int +mark_reachable(struct assembler *a) { + basicblock **stack, **sp; + sp = stack = (basicblock **)PyObject_Malloc(sizeof(basicblock *) * a->a_nblocks); + if (stack == NULL) { + return -1; + } + a->a_entry->b_predecessors = 1; + *sp++ = a->a_entry; + while (sp > stack) { + basicblock *b = *(--sp); + if (b->b_next && !b->b_nofallthrough) { + if (b->b_next->b_predecessors == 0) { + *sp++ = b->b_next; + } + b->b_next->b_predecessors++; + } + for (int i = 0; i < b->b_iused; i++) { + basicblock *target; + if (is_jump(&b->b_instr[i])) { + target = b->b_instr[i].i_target; + if (target->b_predecessors == 0) { + *sp++ = target; + } + target->b_predecessors++; + } + } + } + PyObject_Free(stack); + return 0; +} + +static void +eliminate_empty_basic_blocks(basicblock *entry) { + /* Eliminate empty blocks */ + for (basicblock *b = entry; b != NULL; b = b->b_next) { + basicblock *next = b->b_next; + if (next) { + while (next->b_iused == 0 && next->b_next) { + next = next->b_next; + } + b->b_next = next; + } + } + for (basicblock *b = entry; b != NULL; b = b->b_next) { + if (b->b_iused == 0) { + continue; + } + if (is_jump(&b->b_instr[b->b_iused-1])) { + basicblock *target = b->b_instr[b->b_iused-1].i_target; + while (target->b_iused == 0) { + target = target->b_next; + } + b->b_instr[b->b_iused-1].i_target = target; + } + } +} + + +/* If an instruction has no line number, but it's predecessor in the BB does, + * then copy the line number. If a successor block has no line number, and only + * one predecessor, then inherit the line number. + * This ensures that all exit blocks (with one predecessor) receive a line number. + * Also reduces the size of the line number table, + * but has no impact on the generated line number events. + */ +static void +propagate_line_numbers(struct assembler *a) { + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { + if (b->b_iused == 0) { + continue; + } + int prev_lineno = -1; + for (int i = 0; i < b->b_iused; i++) { + if (b->b_instr[i].i_lineno < 0) { + b->b_instr[i].i_lineno = prev_lineno; + } + else { + prev_lineno = b->b_instr[i].i_lineno; + } + } + if (!b->b_nofallthrough && b->b_next->b_predecessors == 1) { + assert(b->b_next->b_iused); + if (b->b_next->b_instr[0].i_lineno < 0) { + b->b_next->b_instr[0].i_lineno = prev_lineno; + } + } + if (is_jump(&b->b_instr[b->b_iused-1])) { + switch (b->b_instr[b->b_iused-1].i_opcode) { + /* Note: Only actual jumps, not exception handlers */ + case SETUP_ASYNC_WITH: + case SETUP_WITH: + case SETUP_FINALLY: + continue; + } + basicblock *target = b->b_instr[b->b_iused-1].i_target; + if (target->b_predecessors == 1) { + if (target->b_instr[0].i_lineno < 0) { + target->b_instr[0].i_lineno = prev_lineno; + } + } + } + } +} + +/* Perform optimizations on a control flow graph. + The consts object should still be in list form to allow new constants + to be appended. + + All transformations keep the code size the same or smaller. + For those that reduce size, the gaps are initially filled with + NOPs. Later those NOPs are removed. +*/ + +static int +optimize_cfg(struct compiler *c, struct assembler *a, PyObject *consts) +{ + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { + if (optimize_basic_block(c, b, consts)) { + return -1; + } + clean_basic_block(b, -1); + assert(b->b_predecessors == 0); + } + for (basicblock *b = c->u->u_blocks; b != NULL; b = b->b_list) { + if (extend_block(b)) { + return -1; + } + } + if (mark_reachable(a)) { + return -1; + } + /* Delete unreachable instructions */ + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { + if (b->b_predecessors == 0) { + b->b_iused = 0; + b->b_nofallthrough = 0; + } + } + basicblock *pred = NULL; + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { + int prev_lineno = -1; + if (pred && pred->b_iused) { + prev_lineno = pred->b_instr[pred->b_iused-1].i_lineno; + } + clean_basic_block(b, prev_lineno); + pred = b->b_nofallthrough ? NULL : b; + } + eliminate_empty_basic_blocks(a->a_entry); + /* Delete jump instructions made redundant by previous step. If a non-empty + block ends with a jump instruction, check if the next non-empty block + reached through normal flow control is the target of that jump. If it + is, then the jump instruction is redundant and can be deleted. + */ + int maybe_empty_blocks = 0; + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { + if (b->b_iused > 0) { + struct instr *b_last_instr = &b->b_instr[b->b_iused - 1]; + if (b_last_instr->i_opcode == JUMP_ABSOLUTE || + b_last_instr->i_opcode == JUMP_FORWARD) { + if (b_last_instr->i_target == b->b_next) { + assert(b->b_next->b_iused); + b->b_nofallthrough = 0; + b_last_instr->i_opcode = NOP; + clean_basic_block(b, -1); + maybe_empty_blocks = 1; + } + } + } + } + if (maybe_empty_blocks) { + eliminate_empty_basic_blocks(a->a_entry); + } + return 0; +} + +// Remove trailing unused constants. +static int +trim_unused_consts(struct compiler *c, struct assembler *a, PyObject *consts) +{ + assert(PyList_CheckExact(consts)); + + // The first constant may be docstring; keep it always. + int max_const_index = 0; + for (basicblock *b = a->a_entry; b != NULL; b = b->b_next) { + for (int i = 0; i < b->b_iused; i++) { + if (b->b_instr[i].i_opcode == LOAD_CONST && + b->b_instr[i].i_oparg > max_const_index) { + max_const_index = b->b_instr[i].i_oparg; + } + } + } + if (max_const_index+1 < PyList_GET_SIZE(consts)) { + //fprintf(stderr, "removing trailing consts: max=%d, size=%d\n", + // max_const_index, (int)PyList_GET_SIZE(consts)); + if (PyList_SetSlice(consts, max_const_index+1, + PyList_GET_SIZE(consts), NULL) < 0) { + return 1; + } + } + return 0; +} + +static inline int +is_exit_without_lineno(basicblock *b) { + return b->b_exit && b->b_instr[0].i_lineno < 0; +} + +/* PEP 626 mandates that the f_lineno of a frame is correct + * after a frame terminates. It would be prohibitively expensive + * to continuously update the f_lineno field at runtime, + * so we make sure that all exiting instruction (raises and returns) + * have a valid line number, allowing us to compute f_lineno lazily. + * We can do this by duplicating the exit blocks without line number + * so that none have more than one predecessor. We can then safely + * copy the line number from the sole predecessor block. + */ +static int +duplicate_exits_without_lineno(struct compiler *c) +{ + /* Copy all exit blocks without line number that are targets of a jump. + */ + for (basicblock *b = c->u->u_blocks; b != NULL; b = b->b_list) { + if (b->b_iused > 0 && is_jump(&b->b_instr[b->b_iused-1])) { + switch (b->b_instr[b->b_iused-1].i_opcode) { + /* Note: Only actual jumps, not exception handlers */ + case SETUP_ASYNC_WITH: + case SETUP_WITH: + case SETUP_FINALLY: + continue; + } + basicblock *target = b->b_instr[b->b_iused-1].i_target; + if (is_exit_without_lineno(target) && target->b_predecessors > 1) { + basicblock *new_target = compiler_copy_block(c, target); + if (new_target == NULL) { + return -1; + } + new_target->b_instr[0].i_lineno = b->b_instr[b->b_iused-1].i_lineno; + b->b_instr[b->b_iused-1].i_target = new_target; + target->b_predecessors--; + new_target->b_predecessors = 1; + new_target->b_next = target->b_next; + target->b_next = new_target; + } + } + } + /* Eliminate empty blocks */ + for (basicblock *b = c->u->u_blocks; b != NULL; b = b->b_list) { + while (b->b_next && b->b_next->b_iused == 0) { + b->b_next = b->b_next->b_next; + } + } + /* Any remaining reachable exit blocks without line number can only be reached by + * fall through, and thus can only have a single predecessor */ + for (basicblock *b = c->u->u_blocks; b != NULL; b = b->b_list) { + if (!b->b_nofallthrough && b->b_next && b->b_iused > 0) { + if (is_exit_without_lineno(b->b_next)) { + assert(b->b_next->b_iused > 0); + b->b_next->b_instr[0].i_lineno = b->b_instr[b->b_iused-1].i_lineno; + } + } + } + return 0; +} + + +/* Retained for API compatibility. + * Optimization is now done in optimize_cfg */ + +PyObject * +PyCode_Optimize(PyObject *code, PyObject* Py_UNUSED(consts), + PyObject *Py_UNUSED(names), PyObject *Py_UNUSED(lnotab_obj)) { - return PyAST_CompileEx(mod, filename, flags, -1, arena); + Py_INCREF(code); + return code; } diff --git a/contrib/tools/python3/src/Python/condvar.h b/contrib/tools/python3/src/Python/condvar.h index 8cba19b8461..e5df7ff1328 100644 --- a/contrib/tools/python3/src/Python/condvar.h +++ b/contrib/tools/python3/src/Python/condvar.h @@ -99,7 +99,7 @@ PyCOND_TIMEDWAIT(PyCOND_T *cond, PyMUTEX_T *mut, long long us) http://birrell.org/andrew/papers/ImplementingCVs.pdf Generic emulations of the pthread_cond_* API using - earlier Win32 functions can be found on the Web. + earlier Win32 functions can be found on the web. The following read can be give background information to these issues, but the implementations are all broken in some way. http://www.cse.wustl.edu/~schmidt/win32-cv-1.html diff --git a/contrib/tools/python3/src/Python/context.c b/contrib/tools/python3/src/Python/context.c index bacc7010c45..bf2ba93c14e 100644 --- a/contrib/tools/python3/src/Python/context.c +++ b/contrib/tools/python3/src/Python/context.c @@ -10,8 +10,6 @@ #define CONTEXT_FREELIST_MAXLEN 255 -static PyContext *ctx_freelist = NULL; -static int ctx_freelist_len = 0; #include "clinic/context.c.h" @@ -68,6 +66,14 @@ static int contextvar_del(PyContextVar *var); +static struct _Py_context_state * +get_context_state(void) +{ + PyInterpreterState *interp = _PyInterpreterState_GET(); + return &interp->context; +} + + PyObject * _PyContext_NewHamtForTests(void) { @@ -334,11 +340,16 @@ class _contextvars.Context "PyContext *" "&PyContext_Type" static inline PyContext * _context_alloc(void) { + struct _Py_context_state *state = get_context_state(); PyContext *ctx; - if (ctx_freelist_len) { - ctx_freelist_len--; - ctx = ctx_freelist; - ctx_freelist = (PyContext *)ctx->ctx_weakreflist; +#ifdef Py_DEBUG + // _context_alloc() must not be called after _PyContext_Fini() + assert(state->numfree != -1); +#endif + if (state->numfree) { + state->numfree--; + ctx = state->freelist; + state->freelist = (PyContext *)ctx->ctx_weakreflist; ctx->ctx_weakreflist = NULL; _Py_NewReference((PyObject *)ctx); } @@ -458,10 +469,15 @@ context_tp_dealloc(PyContext *self) } (void)context_tp_clear(self); - if (ctx_freelist_len < CONTEXT_FREELIST_MAXLEN) { - ctx_freelist_len++; - self->ctx_weakreflist = (PyObject *)ctx_freelist; - ctx_freelist = self; + struct _Py_context_state *state = get_context_state(); +#ifdef Py_DEBUG + // _context_alloc() must not be called after _PyContext_Fini() + assert(state->numfree != -1); +#endif + if (state->numfree < CONTEXT_FREELIST_MAXLEN) { + state->numfree++; + self->ctx_weakreflist = (PyObject *)state->freelist; + state->freelist = self; } else { Py_TYPE(self)->tp_free(self); @@ -687,7 +703,7 @@ static PyMappingMethods PyContext_as_mapping = { PyTypeObject PyContext_Type = { PyVarObject_HEAD_INIT(&PyType_Type, 0) - "Context", + "_contextvars.Context", sizeof(PyContext), .tp_methods = PyContext_methods, .tp_as_mapping = &PyContext_as_mapping, @@ -1040,7 +1056,7 @@ static PyMethodDef PyContextVar_methods[] = { PyTypeObject PyContextVar_Type = { PyVarObject_HEAD_INIT(&PyType_Type, 0) - "ContextVar", + "_contextvars.ContextVar", sizeof(PyContextVar), .tp_methods = PyContextVar_methods, .tp_members = PyContextVar_members, @@ -1181,7 +1197,7 @@ static PyMethodDef PyContextTokenType_methods[] = { PyTypeObject PyContextToken_Type = { PyVarObject_HEAD_INIT(&PyType_Type, 0) - "Token", + "_contextvars.Token", sizeof(PyContextToken), .tp_methods = PyContextTokenType_methods, .tp_getset = PyContextTokenType_getsetlist, @@ -1271,11 +1287,12 @@ get_token_missing(void) void -_PyContext_ClearFreeList(void) +_PyContext_ClearFreeList(PyInterpreterState *interp) { - for (; ctx_freelist_len; ctx_freelist_len--) { - PyContext *ctx = ctx_freelist; - ctx_freelist = (PyContext *)ctx->ctx_weakreflist; + struct _Py_context_state *state = &interp->context; + for (; state->numfree; state->numfree--) { + PyContext *ctx = state->freelist; + state->freelist = (PyContext *)ctx->ctx_weakreflist; ctx->ctx_weakreflist = NULL; PyObject_GC_Del(ctx); } @@ -1283,10 +1300,16 @@ _PyContext_ClearFreeList(void) void -_PyContext_Fini(void) +_PyContext_Fini(PyInterpreterState *interp) { - Py_CLEAR(_token_missing); - _PyContext_ClearFreeList(); + if (_Py_IsMainInterpreter(interp)) { + Py_CLEAR(_token_missing); + } + _PyContext_ClearFreeList(interp); +#ifdef Py_DEBUG + struct _Py_context_state *state = &interp->context; + state->numfree = -1; +#endif _PyHamt_Fini(); } diff --git a/contrib/tools/python3/src/Python/dynload_win.c b/contrib/tools/python3/src/Python/dynload_win.c index 81787e5f22a..5702ab2cd71 100644 --- a/contrib/tools/python3/src/Python/dynload_win.c +++ b/contrib/tools/python3/src/Python/dynload_win.c @@ -166,14 +166,14 @@ dl_funcptr _PyImport_FindSharedFuncptrWindows(const char *prefix, { dl_funcptr p; char funcname[258], *import_python; - const wchar_t *wpathname; _Py_CheckPython3(); -_Py_COMP_DIAG_PUSH -_Py_COMP_DIAG_IGNORE_DEPR_DECLS - wpathname = _PyUnicode_AsUnicode(pathname); -_Py_COMP_DIAG_POP +#if USE_UNICODE_WCHAR_CACHE + const wchar_t *wpathname = _PyUnicode_AsUnicode(pathname); +#else /* USE_UNICODE_WCHAR_CACHE */ + wchar_t *wpathname = PyUnicode_AsWideCharString(pathname, NULL); +#endif /* USE_UNICODE_WCHAR_CACHE */ if (wpathname == NULL) return NULL; @@ -195,6 +195,9 @@ _Py_COMP_DIAG_POP LOAD_LIBRARY_SEARCH_DEFAULT_DIRS | LOAD_LIBRARY_SEARCH_DLL_LOAD_DIR); Py_END_ALLOW_THREADS +#if !USE_UNICODE_WCHAR_CACHE + PyMem_Free(wpathname); +#endif /* USE_UNICODE_WCHAR_CACHE */ /* restore old error mode settings */ SetErrorMode(old_mode); diff --git a/contrib/tools/python3/src/Python/errors.c b/contrib/tools/python3/src/Python/errors.c index 79278764cc5..bc1b55e440e 100644 --- a/contrib/tools/python3/src/Python/errors.c +++ b/contrib/tools/python3/src/Python/errors.c @@ -317,14 +317,14 @@ _PyErr_NormalizeException(PyThreadState *tstate, PyObject **exc, PyObject **val, PyObject **tb) { int recursion_depth = 0; - tstate->overflowed++; + tstate->recursion_headroom++; PyObject *type, *value, *initial_tb; restart: type = *exc; if (type == NULL) { /* There was no exception, so nothing to do. */ - tstate->overflowed--; + tstate->recursion_headroom--; return; } @@ -376,7 +376,7 @@ _PyErr_NormalizeException(PyThreadState *tstate, PyObject **exc, } *exc = type; *val = value; - tstate->overflowed--; + tstate->recursion_headroom--; return; error: @@ -1109,7 +1109,6 @@ PyErr_NewException(const char *name, PyObject *base, PyObject *dict) { PyThreadState *tstate = _PyThreadState_GET(); PyObject *modulename = NULL; - PyObject *classname = NULL; PyObject *mydict = NULL; PyObject *bases = NULL; PyObject *result = NULL; @@ -1129,10 +1128,11 @@ PyErr_NewException(const char *name, PyObject *base, PyObject *dict) goto failure; } - if (_PyDict_GetItemIdWithError(dict, &PyId___module__) == NULL) { - if (_PyErr_Occurred(tstate)) { - goto failure; - } + int r = _PyDict_ContainsId(dict, &PyId___module__); + if (r < 0) { + goto failure; + } + if (r == 0) { modulename = PyUnicode_FromStringAndSize(name, (Py_ssize_t)(dot-name)); if (modulename == NULL) @@ -1155,7 +1155,6 @@ PyErr_NewException(const char *name, PyObject *base, PyObject *dict) failure: Py_XDECREF(bases); Py_XDECREF(mydict); - Py_XDECREF(classname); Py_XDECREF(modulename); return result; } @@ -1220,7 +1219,7 @@ static PyStructSequence_Desc UnraisableHookArgs_desc = { PyStatus -_PyErr_Init(void) +_PyErr_InitTypes(void) { if (UnraisableHookArgsType.tp_name == NULL) { if (PyStructSequence_InitType2(&UnraisableHookArgsType, @@ -1561,9 +1560,6 @@ PyErr_WriteUnraisable(PyObject *obj) } -extern PyObject *PyModule_GetWarningsModule(void); - - void PyErr_SyntaxLocation(const char *filename, int lineno) { @@ -1575,14 +1571,17 @@ PyErr_SyntaxLocation(const char *filename, int lineno) If the exception is not a SyntaxError, also sets additional attributes to make printing of exceptions believe it is a syntax error. */ -void -PyErr_SyntaxLocationObject(PyObject *filename, int lineno, int col_offset) +static void +PyErr_SyntaxLocationObjectEx(PyObject *filename, int lineno, int col_offset, + int end_lineno, int end_col_offset) { PyObject *exc, *v, *tb, *tmp; _Py_IDENTIFIER(filename); _Py_IDENTIFIER(lineno); + _Py_IDENTIFIER(end_lineno); _Py_IDENTIFIER(msg); _Py_IDENTIFIER(offset); + _Py_IDENTIFIER(end_offset); _Py_IDENTIFIER(print_file_and_line); _Py_IDENTIFIER(text); PyThreadState *tstate = _PyThreadState_GET(); @@ -1612,6 +1611,32 @@ PyErr_SyntaxLocationObject(PyObject *filename, int lineno, int col_offset) _PyErr_Clear(tstate); } Py_XDECREF(tmp); + + tmp = NULL; + if (end_lineno >= 0) { + tmp = PyLong_FromLong(end_lineno); + if (tmp == NULL) { + _PyErr_Clear(tstate); + } + } + if (_PyObject_SetAttrId(v, &PyId_end_lineno, tmp ? tmp : Py_None)) { + _PyErr_Clear(tstate); + } + Py_XDECREF(tmp); + + tmp = NULL; + if (end_col_offset >= 0) { + tmp = PyLong_FromLong(end_col_offset); + if (tmp == NULL) { + _PyErr_Clear(tstate); + } + } + if (_PyObject_SetAttrId(v, &PyId_end_offset, tmp ? tmp : Py_None)) { + _PyErr_Clear(tstate); + } + Py_XDECREF(tmp); + + tmp = NULL; if (filename != NULL) { if (_PyObject_SetAttrId(v, &PyId_filename, filename)) { _PyErr_Clear(tstate); @@ -1624,9 +1649,18 @@ PyErr_SyntaxLocationObject(PyObject *filename, int lineno, int col_offset) } Py_DECREF(tmp); } + else { + _PyErr_Clear(tstate); + } } if (exc != PyExc_SyntaxError) { - if (!_PyObject_HasAttrId(v, &PyId_msg)) { + if (_PyObject_LookupAttrId(v, &PyId_msg, &tmp) < 0) { + _PyErr_Clear(tstate); + } + else if (tmp) { + Py_DECREF(tmp); + } + else { tmp = PyObject_Str(v); if (tmp) { if (_PyObject_SetAttrId(v, &PyId_msg, tmp)) { @@ -1638,7 +1672,13 @@ PyErr_SyntaxLocationObject(PyObject *filename, int lineno, int col_offset) _PyErr_Clear(tstate); } } - if (!_PyObject_HasAttrId(v, &PyId_print_file_and_line)) { + if (_PyObject_LookupAttrId(v, &PyId_print_file_and_line, &tmp) < 0) { + _PyErr_Clear(tstate); + } + else if (tmp) { + Py_DECREF(tmp); + } + else { if (_PyObject_SetAttrId(v, &PyId_print_file_and_line, Py_None)) { _PyErr_Clear(tstate); @@ -1649,6 +1689,17 @@ PyErr_SyntaxLocationObject(PyObject *filename, int lineno, int col_offset) } void +PyErr_SyntaxLocationObject(PyObject *filename, int lineno, int col_offset) { + PyErr_SyntaxLocationObjectEx(filename, lineno, col_offset, lineno, -1); +} + +void +PyErr_RangedSyntaxLocationObject(PyObject *filename, int lineno, int col_offset, + int end_lineno, int end_col_offset) { + PyErr_SyntaxLocationObjectEx(filename, lineno, col_offset, end_lineno, end_col_offset); +} + +void PyErr_SyntaxLocationEx(const char *filename, int lineno, int col_offset) { PyThreadState *tstate = _PyThreadState_GET(); @@ -1673,7 +1724,7 @@ PyErr_SyntaxLocationEx(const char *filename, int lineno, int col_offset) functionality in tb_displayline() in traceback.c. */ static PyObject * -err_programtext(PyThreadState *tstate, FILE *fp, int lineno) +err_programtext(PyThreadState *tstate, FILE *fp, int lineno, const char* encoding) { int i; char linebuf[1000]; @@ -1701,7 +1752,11 @@ after_loop: fclose(fp); if (i == lineno) { PyObject *res; - res = PyUnicode_FromString(linebuf); + if (encoding != NULL) { + res = PyUnicode_Decode(linebuf, strlen(linebuf), encoding, "replace"); + } else { + res = PyUnicode_FromString(linebuf); + } if (res == NULL) _PyErr_Clear(tstate); return res; @@ -1712,17 +1767,22 @@ after_loop: PyObject * PyErr_ProgramText(const char *filename, int lineno) { - FILE *fp; - if (filename == NULL || *filename == '\0' || lineno <= 0) { + if (filename == NULL) { return NULL; } - PyThreadState *tstate = _PyThreadState_GET(); - fp = _Py_fopen(filename, "r" PY_STDIOTEXTMODE); - return err_programtext(tstate, fp, lineno); + + PyObject *filename_obj = PyUnicode_DecodeFSDefault(filename); + if (filename_obj == NULL) { + PyErr_Clear(); + return NULL; + } + PyObject *res = PyErr_ProgramTextObject(filename_obj, lineno); + Py_DECREF(filename_obj); + return res; } PyObject * -PyErr_ProgramTextObject(PyObject *filename, int lineno) +_PyErr_ProgramDecodedTextObject(PyObject *filename, int lineno, const char* encoding) { if (filename == NULL || lineno <= 0) { return NULL; @@ -1734,7 +1794,13 @@ PyErr_ProgramTextObject(PyObject *filename, int lineno) _PyErr_Clear(tstate); return NULL; } - return err_programtext(tstate, fp, lineno); + return err_programtext(tstate, fp, lineno, encoding); +} + +PyObject * +PyErr_ProgramTextObject(PyObject *filename, int lineno) +{ + return _PyErr_ProgramDecodedTextObject(filename, lineno, NULL); } #ifdef __cplusplus diff --git a/contrib/tools/python3/src/Python/fileutils.c b/contrib/tools/python3/src/Python/fileutils.c index 26e97df4ef3..c3144ee4078 100644 --- a/contrib/tools/python3/src/Python/fileutils.c +++ b/contrib/tools/python3/src/Python/fileutils.c @@ -1,5 +1,6 @@ #include "Python.h" -#include "pycore_fileutils.h" +#include "pycore_fileutils.h" // fileutils definitions +#include "pycore_runtime.h" // _PyRuntime #include "osdefs.h" // SEP #include <locale.h> @@ -65,9 +66,6 @@ get_surrogateescape(_Py_error_handler errors, int *surrogateescape) PyObject * _Py_device_encoding(int fd) { -#if defined(MS_WINDOWS) - UINT cp; -#endif int valid; Py_BEGIN_ALLOW_THREADS _Py_BEGIN_SUPPRESS_IPH @@ -78,6 +76,7 @@ _Py_device_encoding(int fd) Py_RETURN_NONE; #if defined(MS_WINDOWS) + UINT cp; if (fd == 0) cp = GetConsoleCP(); else if (fd == 1 || fd == 2) @@ -86,16 +85,14 @@ _Py_device_encoding(int fd) cp = 0; /* GetConsoleCP() and GetConsoleOutputCP() return 0 if the application has no console */ - if (cp != 0) - return PyUnicode_FromFormat("cp%u", (unsigned int)cp); -#elif defined(CODESET) - { - char *codeset = nl_langinfo(CODESET); - if (codeset != NULL && codeset[0] != 0) - return PyUnicode_FromString(codeset); + if (cp == 0) { + Py_RETURN_NONE; } + + return PyUnicode_FromFormat("cp%u", (unsigned int)cp); +#else + return _Py_GetLocaleEncodingObject(); #endif - Py_RETURN_NONE; } @@ -871,6 +868,72 @@ _Py_EncodeLocaleEx(const wchar_t *text, char **str, current_locale, errors); } + +// Get the current locale encoding name: +// +// - Return "UTF-8" if _Py_FORCE_UTF8_LOCALE macro is defined (ex: on Android) +// - Return "UTF-8" if the UTF-8 Mode is enabled +// - On Windows, return the ANSI code page (ex: "cp1250") +// - Return "UTF-8" if nl_langinfo(CODESET) returns an empty string. +// - Otherwise, return nl_langinfo(CODESET). +// +// Return NULL on memory allocation failure. +// +// See also config_get_locale_encoding() +wchar_t* +_Py_GetLocaleEncoding(void) +{ +#ifdef _Py_FORCE_UTF8_LOCALE + // On Android langinfo.h and CODESET are missing, + // and UTF-8 is always used in mbstowcs() and wcstombs(). + return _PyMem_RawWcsdup(L"UTF-8"); +#else + const PyPreConfig *preconfig = &_PyRuntime.preconfig; + if (preconfig->utf8_mode) { + return _PyMem_RawWcsdup(L"UTF-8"); + } + +#ifdef MS_WINDOWS + wchar_t encoding[23]; + unsigned int ansi_codepage = GetACP(); + swprintf(encoding, Py_ARRAY_LENGTH(encoding), L"cp%u", ansi_codepage); + encoding[Py_ARRAY_LENGTH(encoding) - 1] = 0; + return _PyMem_RawWcsdup(encoding); +#else + const char *encoding = nl_langinfo(CODESET); + if (!encoding || encoding[0] == '\0') { + // Use UTF-8 if nl_langinfo() returns an empty string. It can happen on + // macOS if the LC_CTYPE locale is not supported. + return _PyMem_RawWcsdup(L"UTF-8"); + } + + wchar_t *wstr; + int res = decode_current_locale(encoding, &wstr, NULL, + NULL, _Py_ERROR_SURROGATEESCAPE); + if (res < 0) { + return NULL; + } + return wstr; +#endif // !MS_WINDOWS + +#endif // !_Py_FORCE_UTF8_LOCALE +} + + +PyObject * +_Py_GetLocaleEncodingObject(void) +{ + wchar_t *encoding = _Py_GetLocaleEncoding(); + if (encoding == NULL) { + PyErr_NoMemory(); + return NULL; + } + + PyObject *str = PyUnicode_FromWideChar(encoding, -1); + PyMem_RawFree(encoding); + return str; +} + #ifdef HAVE_NON_UNICODE_WCHAR_T_REPRESENTATION /* Check whether current locale uses Unicode as internal wchar_t form. */ @@ -1061,9 +1124,7 @@ _Py_fstat_noraise(int fd, struct _Py_stat_struct *status) HANDLE h; int type; - _Py_BEGIN_SUPPRESS_IPH - h = (HANDLE)_get_osfhandle(fd); - _Py_END_SUPPRESS_IPH + h = _Py_get_osfhandle_noraise(fd); if (h == INVALID_HANDLE_VALUE) { /* errno is already set by _get_osfhandle, but we also set @@ -1156,18 +1217,21 @@ _Py_stat(PyObject *path, struct stat *statbuf) #ifdef MS_WINDOWS int err; struct _stat wstatbuf; - const wchar_t *wpath; -_Py_COMP_DIAG_PUSH -_Py_COMP_DIAG_IGNORE_DEPR_DECLS - wpath = _PyUnicode_AsUnicode(path); -_Py_COMP_DIAG_POP +#if USE_UNICODE_WCHAR_CACHE + const wchar_t *wpath = _PyUnicode_AsUnicode(path); +#else /* USE_UNICODE_WCHAR_CACHE */ + wchar_t *wpath = PyUnicode_AsWideCharString(path, NULL); +#endif /* USE_UNICODE_WCHAR_CACHE */ if (wpath == NULL) return -2; err = _wstat(wpath, &wstatbuf); if (!err) statbuf->st_mode = wstatbuf.st_mode; +#if !USE_UNICODE_WCHAR_CACHE + PyMem_Free(wpath); +#endif /* USE_UNICODE_WCHAR_CACHE */ return err; #else int ret; @@ -1199,9 +1263,7 @@ get_inheritable(int fd, int raise) HANDLE handle; DWORD flags; - _Py_BEGIN_SUPPRESS_IPH - handle = (HANDLE)_get_osfhandle(fd); - _Py_END_SUPPRESS_IPH + handle = _Py_get_osfhandle_noraise(fd); if (handle == INVALID_HANDLE_VALUE) { if (raise) PyErr_SetFromErrno(PyExc_OSError); @@ -1272,9 +1334,7 @@ set_inheritable(int fd, int inheritable, int raise, int *atomic_flag_works) } #ifdef MS_WINDOWS - _Py_BEGIN_SUPPRESS_IPH - handle = (HANDLE)_get_osfhandle(fd); - _Py_END_SUPPRESS_IPH + handle = _Py_get_osfhandle_noraise(fd); if (handle == INVALID_HANDLE_VALUE) { if (raise) PyErr_SetFromErrno(PyExc_OSError); @@ -1545,33 +1605,6 @@ _Py_wfopen(const wchar_t *path, const wchar_t *mode) return f; } -/* Wrapper to fopen(). - - The file descriptor is created non-inheritable. - - If interrupted by a signal, fail with EINTR. */ -FILE* -_Py_fopen(const char *pathname, const char *mode) -{ - PyObject *pathname_obj = PyUnicode_DecodeFSDefault(pathname); - if (pathname_obj == NULL) { - return NULL; - } - if (PySys_Audit("open", "Osi", pathname_obj, mode, 0) < 0) { - Py_DECREF(pathname_obj); - return NULL; - } - Py_DECREF(pathname_obj); - - FILE *f = fopen(pathname, mode); - if (f == NULL) - return NULL; - if (make_non_inheritable(fileno(f)) < 0) { - fclose(f); - return NULL; - } - return f; -} /* Open a file. Call _wfopen() on Windows, or encode the path to the filesystem encoding and call fopen() otherwise. @@ -1592,7 +1625,6 @@ _Py_fopen_obj(PyObject *path, const char *mode) FILE *f; int async_err = 0; #ifdef MS_WINDOWS - const wchar_t *wpath; wchar_t wmode[10]; int usize; @@ -1607,10 +1639,11 @@ _Py_fopen_obj(PyObject *path, const char *mode) Py_TYPE(path)); return NULL; } -_Py_COMP_DIAG_PUSH -_Py_COMP_DIAG_IGNORE_DEPR_DECLS - wpath = _PyUnicode_AsUnicode(path); -_Py_COMP_DIAG_POP +#if USE_UNICODE_WCHAR_CACHE + const wchar_t *wpath = _PyUnicode_AsUnicode(path); +#else /* USE_UNICODE_WCHAR_CACHE */ + wchar_t *wpath = PyUnicode_AsWideCharString(path, NULL); +#endif /* USE_UNICODE_WCHAR_CACHE */ if (wpath == NULL) return NULL; @@ -1618,6 +1651,9 @@ _Py_COMP_DIAG_POP wmode, Py_ARRAY_LENGTH(wmode)); if (usize == 0) { PyErr_SetFromWindowsErr(0); +#if !USE_UNICODE_WCHAR_CACHE + PyMem_Free(wpath); +#endif /* USE_UNICODE_WCHAR_CACHE */ return NULL; } @@ -1627,6 +1663,9 @@ _Py_COMP_DIAG_POP Py_END_ALLOW_THREADS } while (f == NULL && errno == EINTR && !(async_err = PyErr_CheckSignals())); +#if !USE_UNICODE_WCHAR_CACHE + PyMem_Free(wpath); +#endif /* USE_UNICODE_WCHAR_CACHE */ #else PyObject *bytes; const char *path_bytes; @@ -2080,13 +2119,9 @@ _Py_dup(int fd) assert(PyGILState_Check()); #ifdef MS_WINDOWS - _Py_BEGIN_SUPPRESS_IPH - handle = (HANDLE)_get_osfhandle(fd); - _Py_END_SUPPRESS_IPH - if (handle == INVALID_HANDLE_VALUE) { - PyErr_SetFromErrno(PyExc_OSError); + handle = _Py_get_osfhandle(fd); + if (handle == INVALID_HANDLE_VALUE) return -1; - } Py_BEGIN_ALLOW_THREADS _Py_BEGIN_SUPPRESS_IPH @@ -2164,7 +2199,9 @@ _Py_get_blocking(int fd) int _Py_set_blocking(int fd, int blocking) { -#if defined(HAVE_SYS_IOCTL_H) && defined(FIONBIO) +/* bpo-41462: On VxWorks, ioctl(FIONBIO) only works on sockets. + Use fcntl() instead. */ +#if defined(HAVE_SYS_IOCTL_H) && defined(FIONBIO) && !defined(__VXWORKS__) int arg = !blocking; if (ioctl(fd, FIONBIO, &arg) < 0) goto error; @@ -2194,8 +2231,47 @@ error: PyErr_SetFromErrno(PyExc_OSError); return -1; } -#endif +#else /* MS_WINDOWS */ +void* +_Py_get_osfhandle_noraise(int fd) +{ + void *handle; + _Py_BEGIN_SUPPRESS_IPH + handle = (void*)_get_osfhandle(fd); + _Py_END_SUPPRESS_IPH + return handle; +} + +void* +_Py_get_osfhandle(int fd) +{ + void *handle = _Py_get_osfhandle_noraise(fd); + if (handle == INVALID_HANDLE_VALUE) + PyErr_SetFromErrno(PyExc_OSError); + return handle; +} + +int +_Py_open_osfhandle_noraise(void *handle, int flags) +{ + int fd; + _Py_BEGIN_SUPPRESS_IPH + fd = _open_osfhandle((intptr_t)handle, flags); + _Py_END_SUPPRESS_IPH + return fd; +} + +int +_Py_open_osfhandle(void *handle, int flags) +{ + int fd = _Py_open_osfhandle_noraise(handle, flags); + if (fd == -1) + PyErr_SetFromErrno(PyExc_OSError); + + return fd; +} +#endif /* MS_WINDOWS */ int _Py_GetLocaleconvNumeric(struct lconv *lc, @@ -2274,3 +2350,79 @@ done: #undef GET_LOCALE_STRING } + +/* Our selection logic for which function to use is as follows: + * 1. If close_range(2) is available, always prefer that; it's better for + * contiguous ranges like this than fdwalk(3) which entails iterating over + * the entire fd space and simply doing nothing for those outside the range. + * 2. If closefrom(2) is available, we'll attempt to use that next if we're + * closing up to sysconf(_SC_OPEN_MAX). + * 2a. Fallback to fdwalk(3) if we're not closing up to sysconf(_SC_OPEN_MAX), + * as that will be more performant if the range happens to have any chunk of + * non-opened fd in the middle. + * 2b. If fdwalk(3) isn't available, just do a plain close(2) loop. + */ +#ifdef __FreeBSD__ +# define USE_CLOSEFROM +#endif /* __FreeBSD__ */ + +#ifdef HAVE_FDWALK +# define USE_FDWALK +#endif /* HAVE_FDWALK */ + +#ifdef USE_FDWALK +static int +_fdwalk_close_func(void *lohi, int fd) +{ + int lo = ((int *)lohi)[0]; + int hi = ((int *)lohi)[1]; + + if (fd >= hi) { + return 1; + } + else if (fd >= lo) { + /* Ignore errors */ + (void)close(fd); + } + return 0; +} +#endif /* USE_FDWALK */ + +/* Closes all file descriptors in [first, last], ignoring errors. */ +void +_Py_closerange(int first, int last) +{ + first = Py_MAX(first, 0); + _Py_BEGIN_SUPPRESS_IPH +#ifdef HAVE_CLOSE_RANGE + if (close_range(first, last, 0) == 0 || errno != ENOSYS) { + /* Any errors encountered while closing file descriptors are ignored; + * ENOSYS means no kernel support, though, + * so we'll fallback to the other methods. */ + } + else +#endif /* HAVE_CLOSE_RANGE */ +#ifdef USE_CLOSEFROM + if (last >= sysconf(_SC_OPEN_MAX)) { + /* Any errors encountered while closing file descriptors are ignored */ + closefrom(first); + } + else +#endif /* USE_CLOSEFROM */ +#ifdef USE_FDWALK + { + int lohi[2]; + lohi[0] = first; + lohi[1] = last + 1; + fdwalk(_fdwalk_close_func, lohi); + } +#else + { + for (int i = first; i <= last; i++) { + /* Ignore errors */ + (void)close(i); + } + } +#endif /* USE_FDWALK */ + _Py_END_SUPPRESS_IPH +} diff --git a/contrib/tools/python3/src/Python/formatter_unicode.c b/contrib/tools/python3/src/Python/formatter_unicode.c index e7ec4dd5cb4..7b5a7bd04eb 100644 --- a/contrib/tools/python3/src/Python/formatter_unicode.c +++ b/contrib/tools/python3/src/Python/formatter_unicode.c @@ -219,7 +219,7 @@ parse_internal_render_format_spec(PyObject *format_spec, /* The special case for 0-padding (backwards compat) */ if (!fill_char_specified && end-pos >= 1 && READ_spec(pos) == '0') { format->fill_char = '0'; - if (!align_specified) { + if (!align_specified && default_align == '>') { format->align = '='; } ++pos; diff --git a/contrib/tools/python3/src/Python/frozen.c b/contrib/tools/python3/src/Python/frozen.c index 228a11019cf..7f433ff80ca 100644 --- a/contrib/tools/python3/src/Python/frozen.c +++ b/contrib/tools/python3/src/Python/frozen.c @@ -1,5 +1,5 @@ -/* Dummy frozen modules initializer */ +/* Frozen modules initializer */ #include "Python.h" #include "importlib.h" @@ -10,23 +10,12 @@ define a single frozen module, __hello__. Loading it will print some famous words... */ -/* To regenerate this data after the bytecode or marshal format has changed, - go to ../Tools/freeze/ and freeze the flag.py file; then copy and paste - the appropriate bytes from M___main__.c. */ - -static unsigned char M___hello__[] = { - 227,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,2,0,0,0,64,0,0,0,115,16,0,0,0,100,0, - 90,0,101,1,100,1,131,1,1,0,100,2,83,0,41,3, - 84,122,12,72,101,108,108,111,32,119,111,114,108,100,33,78, - 41,2,218,11,105,110,105,116,105,97,108,105,122,101,100,218, - 5,112,114,105,110,116,169,0,114,3,0,0,0,114,3,0, - 0,0,250,20,84,111,111,108,115,47,102,114,101,101,122,101, - 47,102,108,97,103,46,112,121,218,8,60,109,111,100,117,108, - 101,62,1,0,0,0,115,2,0,0,0,4,1, -}; +/* Run "make regen-frozen" to regen the file below (e.g. after a bytecode + * format change). The include file defines _Py_M__hello as an array of bytes. + */ +#include "frozen_hello.h" -#define SIZE (int)sizeof(M___hello__) +#define SIZE (int)sizeof(_Py_M__hello) static const struct _frozen _PyImport_FrozenModules[] = { /* importlib */ @@ -37,10 +26,10 @@ static const struct _frozen _PyImport_FrozenModules[] = { {"zipimport", _Py_M__zipimport, (int)sizeof(_Py_M__zipimport)}, /* Test module */ - {"__hello__", M___hello__, SIZE}, + {"__hello__", _Py_M__hello, SIZE}, /* Test package (negative size indicates package-ness) */ - {"__phello__", M___hello__, -SIZE}, - {"__phello__.spam", M___hello__, SIZE}, + {"__phello__", _Py_M__hello, -SIZE}, + {"__phello__.spam", _Py_M__hello, SIZE}, {0, 0, 0} /* sentinel */ }; diff --git a/contrib/tools/python3/src/Python/frozen_hello.h b/contrib/tools/python3/src/Python/frozen_hello.h new file mode 100644 index 00000000000..5448c80daa4 --- /dev/null +++ b/contrib/tools/python3/src/Python/frozen_hello.h @@ -0,0 +1,12 @@ +/* Auto-generated by Programs/_freeze_importlib.c */ +const unsigned char _Py_M__hello[] = { + 99,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, + 0,2,0,0,0,64,0,0,0,115,16,0,0,0,100,0, + 90,0,101,1,100,1,131,1,1,0,100,2,83,0,41,3, + 84,122,12,72,101,108,108,111,32,119,111,114,108,100,33,78, + 41,2,90,11,105,110,105,116,105,97,108,105,122,101,100,218, + 5,112,114,105,110,116,169,0,114,1,0,0,0,114,1,0, + 0,0,122,14,60,102,114,111,122,101,110,32,104,101,108,108, + 111,62,218,8,60,109,111,100,117,108,101,62,1,0,0,0, + 115,4,0,0,0,4,0,12,1, +}; diff --git a/contrib/tools/python3/src/Python/future.c b/contrib/tools/python3/src/Python/future.c index 1663a38a6fd..d465608ca45 100644 --- a/contrib/tools/python3/src/Python/future.c +++ b/contrib/tools/python3/src/Python/future.c @@ -1,11 +1,5 @@ #include "Python.h" -#include "Python-ast.h" -#include "node.h" -#include "token.h" -#include "graminit.h" -#include "code.h" -#include "symtable.h" -#include "ast.h" +#include "pycore_ast.h" // _PyAST_GetDocString() #define UNDEFINED_FUTURE_FEATURE "future feature %.100s is not defined" #define ERR_LATE_FUTURE \ @@ -15,11 +9,10 @@ static int future_check_features(PyFutureFeatures *ff, stmt_ty s, PyObject *filename) { int i; - asdl_seq *names; assert(s->kind == ImportFrom_kind); - names = s->v.ImportFrom.names; + asdl_alias_seq *names = s->v.ImportFrom.names; for (i = 0; i < asdl_seq_LEN(names); i++) { alias_ty name = (alias_ty)asdl_seq_GET(names, i); const char *feature = PyUnicode_AsUTF8(name->name); @@ -123,7 +116,7 @@ future_parse(PyFutureFeatures *ff, mod_ty mod, PyObject *filename) PyFutureFeatures * -PyFuture_FromASTObject(mod_ty mod, PyObject *filename) +_PyFuture_FromAST(mod_ty mod, PyObject *filename) { PyFutureFeatures *ff; @@ -141,18 +134,3 @@ PyFuture_FromASTObject(mod_ty mod, PyObject *filename) } return ff; } - - -PyFutureFeatures * -PyFuture_FromAST(mod_ty mod, const char *filename_str) -{ - PyFutureFeatures *ff; - PyObject *filename; - - filename = PyUnicode_DecodeFSDefault(filename_str); - if (filename == NULL) - return NULL; - ff = PyFuture_FromASTObject(mod, filename); - Py_DECREF(filename); - return ff; -} diff --git a/contrib/tools/python3/src/Python/getargs.c b/contrib/tools/python3/src/Python/getargs.c index d4a531a5efb..d5e083509ef 100644 --- a/contrib/tools/python3/src/Python/getargs.c +++ b/contrib/tools/python3/src/Python/getargs.c @@ -2,7 +2,7 @@ /* New getargs implementation */ #include "Python.h" -#include "pycore_tupleobject.h" +#include "pycore_tuple.h" // _PyTuple_ITEMS() #include <ctype.h> #include <float.h> @@ -202,7 +202,7 @@ static int cleanup_ptr(PyObject *self, void *ptr) { if (ptr) { - PyMem_FREE(ptr); + PyMem_Free(ptr); } return 0; } @@ -246,7 +246,7 @@ cleanreturn(int retval, freelist_t *freelist) } } if (freelist->entries_malloced) - PyMem_FREE(freelist->entries); + PyMem_Free(freelist->entries); return retval; } @@ -452,7 +452,7 @@ seterror(Py_ssize_t iarg, const char *msg, int *levels, const char *fname, } if (iarg != 0) { PyOS_snprintf(p, sizeof(buf) - (p - buf), - "argument %" PY_FORMAT_SIZE_T "d", iarg); + "argument %zd", iarg); i = 0; p += strlen(p); while (i < 32 && levels[i] > 0 && (int)(p-buf) < 220) { @@ -540,15 +540,14 @@ converttuple(PyObject *arg, const char **p_format, va_list *p_va, int flags, levels[0] = 0; if (toplevel) { PyOS_snprintf(msgbuf, bufsize, - "expected %d argument%s, not %" PY_FORMAT_SIZE_T "d", + "expected %d argument%s, not %zd", n, n == 1 ? "" : "s", len); } else { PyOS_snprintf(msgbuf, bufsize, - "must be sequence of length %d, " - "not %" PY_FORMAT_SIZE_T "d", + "must be sequence of length %d, not %zd", n, len); } return msgbuf; @@ -643,22 +642,6 @@ converterr(const char *expected, PyObject *arg, char *msgbuf, size_t bufsize) #define CONV_UNICODE "(unicode conversion error)" -/* Explicitly check for float arguments when integers are expected. - Return 1 for error, 0 if ok. - XXX Should be removed after the end of the deprecation period in - _PyLong_FromNbIndexOrNbInt. */ -static int -float_argument_error(PyObject *arg) -{ - if (PyFloat_Check(arg)) { - PyErr_SetString(PyExc_TypeError, - "integer argument expected, got float" ); - return 1; - } - else - return 0; -} - /* Convert a non-tuple argument. Return NULL if conversion went OK, or a string with a message describing the failure. The message is formatted as "must be <desired type>, not <actual type>". @@ -672,29 +655,14 @@ static const char * convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, char *msgbuf, size_t bufsize, freelist_t *freelist) { - /* For # codes */ -#define FETCH_SIZE int *q=NULL;Py_ssize_t *q2=NULL;\ - if (flags & FLAG_SIZE_T) q2=va_arg(*p_va, Py_ssize_t*); \ - else { \ - if (PyErr_WarnEx(PyExc_DeprecationWarning, \ - "PY_SSIZE_T_CLEAN will be required for '#' formats", 1)) { \ - return NULL; \ - } \ - q=va_arg(*p_va, int*); \ - } -#define STORE_SIZE(s) \ - if (flags & FLAG_SIZE_T) \ - *q2=s; \ - else { \ - if (INT_MAX < s) { \ - PyErr_SetString(PyExc_OverflowError, \ - "size does not fit in an int"); \ - return converterr("", arg, msgbuf, bufsize); \ - } \ - *q = (int)s; \ - } -#define BUFFER_LEN ((flags & FLAG_SIZE_T) ? *q2:*q) #define RETURN_ERR_OCCURRED return msgbuf + /* For # codes */ +#define REQUIRE_PY_SSIZE_T_CLEAN \ + if (!(flags & FLAG_SIZE_T)) { \ + PyErr_SetString(PyExc_SystemError, \ + "PY_SSIZE_T_CLEAN macro must be defined for '#' formats"); \ + RETURN_ERR_OCCURRED; \ + } const char *format = *p_format; char c = *format++; @@ -704,10 +672,7 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, case 'b': { /* unsigned byte -- very short int */ char *p = va_arg(*p_va, char *); - long ival; - if (float_argument_error(arg)) - RETURN_ERR_OCCURRED; - ival = PyLong_AsLong(arg); + long ival = PyLong_AsLong(arg); if (ival == -1 && PyErr_Occurred()) RETURN_ERR_OCCURRED; else if (ival < 0) { @@ -728,11 +693,8 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, case 'B': {/* byte sized bitfield - both signed and unsigned values allowed */ char *p = va_arg(*p_va, char *); - long ival; - if (float_argument_error(arg)) - RETURN_ERR_OCCURRED; - ival = PyLong_AsUnsignedLongMask(arg); - if (ival == -1 && PyErr_Occurred()) + unsigned long ival = PyLong_AsUnsignedLongMask(arg); + if (ival == (unsigned long)-1 && PyErr_Occurred()) RETURN_ERR_OCCURRED; else *p = (unsigned char) ival; @@ -741,10 +703,7 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, case 'h': {/* signed short int */ short *p = va_arg(*p_va, short *); - long ival; - if (float_argument_error(arg)) - RETURN_ERR_OCCURRED; - ival = PyLong_AsLong(arg); + long ival = PyLong_AsLong(arg); if (ival == -1 && PyErr_Occurred()) RETURN_ERR_OCCURRED; else if (ival < SHRT_MIN) { @@ -765,11 +724,8 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, case 'H': { /* short int sized bitfield, both signed and unsigned allowed */ unsigned short *p = va_arg(*p_va, unsigned short *); - long ival; - if (float_argument_error(arg)) - RETURN_ERR_OCCURRED; - ival = PyLong_AsUnsignedLongMask(arg); - if (ival == -1 && PyErr_Occurred()) + unsigned long ival = PyLong_AsUnsignedLongMask(arg); + if (ival == (unsigned long)-1 && PyErr_Occurred()) RETURN_ERR_OCCURRED; else *p = (unsigned short) ival; @@ -778,10 +734,7 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, case 'i': {/* signed int */ int *p = va_arg(*p_va, int *); - long ival; - if (float_argument_error(arg)) - RETURN_ERR_OCCURRED; - ival = PyLong_AsLong(arg); + long ival = PyLong_AsLong(arg); if (ival == -1 && PyErr_Occurred()) RETURN_ERR_OCCURRED; else if (ival > INT_MAX) { @@ -802,14 +755,11 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, case 'I': { /* int sized bitfield, both signed and unsigned allowed */ unsigned int *p = va_arg(*p_va, unsigned int *); - unsigned int ival; - if (float_argument_error(arg)) - RETURN_ERR_OCCURRED; - ival = (unsigned int)PyLong_AsUnsignedLongMask(arg); - if (ival == (unsigned int)-1 && PyErr_Occurred()) + unsigned long ival = PyLong_AsUnsignedLongMask(arg); + if (ival == (unsigned long)-1 && PyErr_Occurred()) RETURN_ERR_OCCURRED; else - *p = ival; + *p = (unsigned int) ival; break; } @@ -818,9 +768,7 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, PyObject *iobj; Py_ssize_t *p = va_arg(*p_va, Py_ssize_t *); Py_ssize_t ival = -1; - if (float_argument_error(arg)) - RETURN_ERR_OCCURRED; - iobj = PyNumber_Index(arg); + iobj = _PyNumber_Index(arg); if (iobj != NULL) { ival = PyLong_AsSsize_t(iobj); Py_DECREF(iobj); @@ -832,10 +780,7 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, } case 'l': {/* long int */ long *p = va_arg(*p_va, long *); - long ival; - if (float_argument_error(arg)) - RETURN_ERR_OCCURRED; - ival = PyLong_AsLong(arg); + long ival = PyLong_AsLong(arg); if (ival == -1 && PyErr_Occurred()) RETURN_ERR_OCCURRED; else @@ -856,10 +801,7 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, case 'L': {/* long long */ long long *p = va_arg( *p_va, long long * ); - long long ival; - if (float_argument_error(arg)) - RETURN_ERR_OCCURRED; - ival = PyLong_AsLongLong(arg); + long long ival = PyLong_AsLongLong(arg); if (ival == (long long)-1 && PyErr_Occurred()) RETURN_ERR_OCCURRED; else @@ -974,8 +916,9 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, if (count < 0) return converterr(buf, arg, msgbuf, bufsize); if (*format == '#') { - FETCH_SIZE; - STORE_SIZE(count); + REQUIRE_PY_SSIZE_T_CLEAN; + Py_ssize_t *psize = va_arg(*p_va, Py_ssize_t*); + *psize = count; format++; } else { if (strlen(*p) != (size_t)count) { @@ -1017,11 +960,12 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, } else if (*format == '#') { /* a string or read-only bytes-like object */ /* "s#" or "z#" */ const void **p = (const void **)va_arg(*p_va, const char **); - FETCH_SIZE; + REQUIRE_PY_SSIZE_T_CLEAN; + Py_ssize_t *psize = va_arg(*p_va, Py_ssize_t*); if (c == 'z' && arg == Py_None) { *p = NULL; - STORE_SIZE(0); + *psize = 0; } else if (PyUnicode_Check(arg)) { Py_ssize_t len; @@ -1030,7 +974,7 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, return converterr(CONV_UNICODE, arg, msgbuf, bufsize); *p = sarg; - STORE_SIZE(len); + *psize = len; } else { /* read-only bytes-like object */ /* XXX Really? */ @@ -1038,7 +982,7 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, Py_ssize_t count = convertbuffer(arg, p, &buf); if (count < 0) return converterr(buf, arg, msgbuf, bufsize); - STORE_SIZE(count); + *psize = count; } format++; } else { @@ -1070,25 +1014,29 @@ convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags, case 'u': /* raw unicode buffer (Py_UNICODE *) */ case 'Z': /* raw unicode buffer or None */ { - // TODO: Raise DeprecationWarning + if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1, + "getargs: The '%c' format is deprecated. Use 'U' instead.", c)) { + return NULL; + } _Py_COMP_DIAG_PUSH _Py_COMP_DIAG_IGNORE_DEPR_DECLS Py_UNICODE **p = va_arg(*p_va, Py_UNICODE **); if (*format == '#') { /* "u#" or "Z#" */ - FETCH_SIZE; + REQUIRE_PY_SSIZE_T_CLEAN; + Py_ssize_t *psize = va_arg(*p_va, Py_ssize_t*); if (c == 'Z' && arg == Py_None) { *p = NULL; - STORE_SIZE(0); + *psize = 0; } else if (PyUnicode_Check(arg)) { Py_ssize_t len; *p = PyUnicode_AsUnicodeAndSize(arg, &len); if (*p == NULL) RETURN_ERR_OCCURRED; - STORE_SIZE(len); + *psize = len; } else return converterr(c == 'Z' ? "str or None" : "str", @@ -1203,22 +1151,11 @@ _Py_COMP_DIAG_POP trailing 0-byte */ - int *q = NULL; Py_ssize_t *q2 = NULL; - if (flags & FLAG_SIZE_T) { - q2 = va_arg(*p_va, Py_ssize_t*); - } - else { - if (PyErr_WarnEx(PyExc_DeprecationWarning, - "PY_SSIZE_T_CLEAN will be required for '#' formats", 1)) - { - Py_DECREF(s); - return NULL; - } - q = va_arg(*p_va, int*); - } + REQUIRE_PY_SSIZE_T_CLEAN; + Py_ssize_t *psize = va_arg(*p_va, Py_ssize_t*); format++; - if (q == NULL && q2 == NULL) { + if (psize == NULL) { Py_DECREF(s); return converterr( "(buffer_len is NULL)", @@ -1238,30 +1175,20 @@ _Py_COMP_DIAG_POP arg, msgbuf, bufsize); } } else { - if (size + 1 > BUFFER_LEN) { + if (size + 1 > *psize) { Py_DECREF(s); PyErr_Format(PyExc_ValueError, "encoded string too long " "(%zd, maximum length %zd)", - (Py_ssize_t)size, (Py_ssize_t)(BUFFER_LEN-1)); + (Py_ssize_t)size, (Py_ssize_t)(*psize - 1)); RETURN_ERR_OCCURRED; } } memcpy(*buffer, ptr, size+1); - if (flags & FLAG_SIZE_T) { - *q2 = size; - } - else { - if (INT_MAX < size) { - Py_DECREF(s); - PyErr_SetString(PyExc_OverflowError, - "size does not fit in an int"); - return converterr("", arg, msgbuf, bufsize); - } - *q = (int)size; - } - } else { + *psize = size; + } + else { /* Using a 0-terminated buffer: - the encoded string has to be 0-terminated @@ -1399,9 +1326,7 @@ _Py_COMP_DIAG_POP *p_format = format; return NULL; -#undef FETCH_SIZE -#undef STORE_SIZE -#undef BUFFER_LEN +#undef REQUIRE_PY_SSIZE_T_CLEAN #undef RETURN_ERR_OCCURRED } @@ -2607,15 +2532,12 @@ skipitem(const char **p_format, va_list *p_va, int flags) } if (*format == '#') { if (p_va != NULL) { - if (flags & FLAG_SIZE_T) - (void) va_arg(*p_va, Py_ssize_t *); - else { - if (PyErr_WarnEx(PyExc_DeprecationWarning, - "PY_SSIZE_T_CLEAN will be required for '#' formats", 1)) { - return NULL; - } - (void) va_arg(*p_va, int *); + if (!(flags & FLAG_SIZE_T)) { + PyErr_SetString(PyExc_SystemError, + "PY_SSIZE_T_CLEAN macro must be defined for '#' formats"); + return NULL; } + (void) va_arg(*p_va, Py_ssize_t *); } format++; } else if ((c == 's' || c == 'z' || c == 'y' || c == 'w') diff --git a/contrib/tools/python3/src/Python/getcompiler.c b/contrib/tools/python3/src/Python/getcompiler.c index 59c0dbf92ae..a5d26239e87 100644 --- a/contrib/tools/python3/src/Python/getcompiler.c +++ b/contrib/tools/python3/src/Python/getcompiler.c @@ -8,9 +8,9 @@ // Note the __clang__ conditional has to come before the __GNUC__ one because // clang pretends to be GCC. #if defined(__clang__) -#define COMPILER "\n[Clang " __clang_version__ "]" +#define COMPILER "[Clang " __clang_version__ "]" #elif defined(__GNUC__) -#define COMPILER "\n[GCC " __VERSION__ "]" +#define COMPILER "[GCC " __VERSION__ "]" // Generic fallbacks. #elif defined(__cplusplus) #define COMPILER "[C++]" diff --git a/contrib/tools/python3/src/Python/graminit.c b/contrib/tools/python3/src/Python/graminit.c deleted file mode 100644 index b7aa52895f8..00000000000 --- a/contrib/tools/python3/src/Python/graminit.c +++ /dev/null @@ -1,2688 +0,0 @@ -/* Generated by Parser/pgen */ - -#include "exports.h" -#include "grammar.h" -Py_EXPORTED_SYMBOL grammar _PyParser_Grammar; -static const arc arcs_0_0[3] = { - {2, 1}, - {3, 2}, - {4, 1}, -}; -static const arc arcs_0_1[1] = { - {0, 1}, -}; -static const arc arcs_0_2[1] = { - {2, 1}, -}; -static state states_0[3] = { - {3, arcs_0_0}, - {1, arcs_0_1}, - {1, arcs_0_2}, -}; -static const arc arcs_1_0[3] = { - {44, 1}, - {2, 0}, - {45, 0}, -}; -static const arc arcs_1_1[1] = { - {0, 1}, -}; -static state states_1[2] = { - {3, arcs_1_0}, - {1, arcs_1_1}, -}; -static const arc arcs_2_0[1] = { - {47, 1}, -}; -static const arc arcs_2_1[2] = { - {44, 2}, - {2, 1}, -}; -static const arc arcs_2_2[1] = { - {0, 2}, -}; -static state states_2[3] = { - {1, arcs_2_0}, - {2, arcs_2_1}, - {1, arcs_2_2}, -}; -static const arc arcs_3_0[1] = { - {10, 1}, -}; -static const arc arcs_3_1[1] = { - {49, 2}, -}; -static const arc arcs_3_2[1] = { - {2, 3}, -}; -static const arc arcs_3_3[1] = { - {0, 3}, -}; -static state states_3[4] = { - {1, arcs_3_0}, - {1, arcs_3_1}, - {1, arcs_3_2}, - {1, arcs_3_3}, -}; -static const arc arcs_4_0[1] = { - {48, 1}, -}; -static const arc arcs_4_1[2] = { - {48, 1}, - {0, 1}, -}; -static state states_4[2] = { - {1, arcs_4_0}, - {2, arcs_4_1}, -}; -static const arc arcs_5_0[1] = { - {50, 1}, -}; -static const arc arcs_5_1[3] = { - {52, 2}, - {53, 2}, - {54, 2}, -}; -static const arc arcs_5_2[1] = { - {0, 2}, -}; -static state states_5[3] = { - {1, arcs_5_0}, - {3, arcs_5_1}, - {1, arcs_5_2}, -}; -static const arc arcs_6_0[1] = { - {38, 1}, -}; -static const arc arcs_6_1[1] = { - {54, 2}, -}; -static const arc arcs_6_2[1] = { - {0, 2}, -}; -static state states_6[3] = { - {1, arcs_6_0}, - {1, arcs_6_1}, - {1, arcs_6_2}, -}; -static const arc arcs_7_0[1] = { - {19, 1}, -}; -static const arc arcs_7_1[1] = { - {40, 2}, -}; -static const arc arcs_7_2[1] = { - {55, 3}, -}; -static const arc arcs_7_3[2] = { - {56, 4}, - {57, 5}, -}; -static const arc arcs_7_4[1] = { - {58, 6}, -}; -static const arc arcs_7_5[2] = { - {59, 7}, - {60, 8}, -}; -static const arc arcs_7_6[1] = { - {57, 5}, -}; -static const arc arcs_7_7[1] = { - {60, 8}, -}; -static const arc arcs_7_8[1] = { - {0, 8}, -}; -static state states_7[9] = { - {1, arcs_7_0}, - {1, arcs_7_1}, - {1, arcs_7_2}, - {2, arcs_7_3}, - {1, arcs_7_4}, - {2, arcs_7_5}, - {1, arcs_7_6}, - {1, arcs_7_7}, - {1, arcs_7_8}, -}; -static const arc arcs_8_0[1] = { - {5, 1}, -}; -static const arc arcs_8_1[2] = { - {61, 2}, - {62, 3}, -}; -static const arc arcs_8_2[1] = { - {0, 2}, -}; -static const arc arcs_8_3[1] = { - {61, 2}, -}; -static state states_8[4] = { - {1, arcs_8_0}, - {2, arcs_8_1}, - {1, arcs_8_2}, - {1, arcs_8_3}, -}; -static const arc arcs_9_0[3] = { - {6, 1}, - {63, 2}, - {64, 3}, -}; -static const arc arcs_9_1[4] = { - {65, 4}, - {59, 5}, - {64, 6}, - {0, 1}, -}; -static const arc arcs_9_2[1] = { - {64, 7}, -}; -static const arc arcs_9_3[4] = { - {65, 8}, - {66, 9}, - {59, 5}, - {0, 3}, -}; -static const arc arcs_9_4[4] = { - {63, 2}, - {59, 10}, - {64, 11}, - {0, 4}, -}; -static const arc arcs_9_5[1] = { - {0, 5}, -}; -static const arc arcs_9_6[3] = { - {65, 4}, - {59, 5}, - {0, 6}, -}; -static const arc arcs_9_7[3] = { - {65, 12}, - {59, 5}, - {0, 7}, -}; -static const arc arcs_9_8[6] = { - {6, 13}, - {63, 2}, - {67, 14}, - {59, 15}, - {64, 3}, - {0, 8}, -}; -static const arc arcs_9_9[1] = { - {58, 16}, -}; -static const arc arcs_9_10[3] = { - {63, 2}, - {64, 11}, - {0, 10}, -}; -static const arc arcs_9_11[4] = { - {65, 4}, - {66, 17}, - {59, 5}, - {0, 11}, -}; -static const arc arcs_9_12[2] = { - {59, 5}, - {0, 12}, -}; -static const arc arcs_9_13[4] = { - {65, 18}, - {59, 5}, - {64, 19}, - {0, 13}, -}; -static const arc arcs_9_14[2] = { - {65, 20}, - {0, 14}, -}; -static const arc arcs_9_15[5] = { - {6, 13}, - {63, 2}, - {67, 14}, - {64, 3}, - {0, 15}, -}; -static const arc arcs_9_16[3] = { - {65, 8}, - {59, 5}, - {0, 16}, -}; -static const arc arcs_9_17[1] = { - {58, 6}, -}; -static const arc arcs_9_18[4] = { - {63, 2}, - {59, 21}, - {64, 22}, - {0, 18}, -}; -static const arc arcs_9_19[3] = { - {65, 18}, - {59, 5}, - {0, 19}, -}; -static const arc arcs_9_20[5] = { - {6, 23}, - {63, 2}, - {59, 24}, - {64, 25}, - {0, 20}, -}; -static const arc arcs_9_21[3] = { - {63, 2}, - {64, 22}, - {0, 21}, -}; -static const arc arcs_9_22[4] = { - {65, 18}, - {66, 26}, - {59, 5}, - {0, 22}, -}; -static const arc arcs_9_23[4] = { - {65, 27}, - {59, 5}, - {64, 28}, - {0, 23}, -}; -static const arc arcs_9_24[1] = { - {64, 25}, -}; -static const arc arcs_9_25[4] = { - {65, 29}, - {66, 30}, - {59, 5}, - {0, 25}, -}; -static const arc arcs_9_26[1] = { - {58, 19}, -}; -static const arc arcs_9_27[4] = { - {63, 2}, - {59, 31}, - {64, 32}, - {0, 27}, -}; -static const arc arcs_9_28[3] = { - {65, 27}, - {59, 5}, - {0, 28}, -}; -static const arc arcs_9_29[5] = { - {6, 33}, - {63, 2}, - {59, 34}, - {64, 25}, - {0, 29}, -}; -static const arc arcs_9_30[1] = { - {58, 35}, -}; -static const arc arcs_9_31[3] = { - {63, 2}, - {64, 32}, - {0, 31}, -}; -static const arc arcs_9_32[4] = { - {65, 27}, - {66, 36}, - {59, 5}, - {0, 32}, -}; -static const arc arcs_9_33[4] = { - {65, 37}, - {59, 5}, - {64, 38}, - {0, 33}, -}; -static const arc arcs_9_34[4] = { - {6, 33}, - {63, 2}, - {64, 25}, - {0, 34}, -}; -static const arc arcs_9_35[3] = { - {65, 29}, - {59, 5}, - {0, 35}, -}; -static const arc arcs_9_36[1] = { - {58, 28}, -}; -static const arc arcs_9_37[4] = { - {63, 2}, - {59, 39}, - {64, 40}, - {0, 37}, -}; -static const arc arcs_9_38[3] = { - {65, 37}, - {59, 5}, - {0, 38}, -}; -static const arc arcs_9_39[3] = { - {63, 2}, - {64, 40}, - {0, 39}, -}; -static const arc arcs_9_40[4] = { - {65, 37}, - {66, 41}, - {59, 5}, - {0, 40}, -}; -static const arc arcs_9_41[1] = { - {58, 38}, -}; -static state states_9[42] = { - {3, arcs_9_0}, - {4, arcs_9_1}, - {1, arcs_9_2}, - {4, arcs_9_3}, - {4, arcs_9_4}, - {1, arcs_9_5}, - {3, arcs_9_6}, - {3, arcs_9_7}, - {6, arcs_9_8}, - {1, arcs_9_9}, - {3, arcs_9_10}, - {4, arcs_9_11}, - {2, arcs_9_12}, - {4, arcs_9_13}, - {2, arcs_9_14}, - {5, arcs_9_15}, - {3, arcs_9_16}, - {1, arcs_9_17}, - {4, arcs_9_18}, - {3, arcs_9_19}, - {5, arcs_9_20}, - {3, arcs_9_21}, - {4, arcs_9_22}, - {4, arcs_9_23}, - {1, arcs_9_24}, - {4, arcs_9_25}, - {1, arcs_9_26}, - {4, arcs_9_27}, - {3, arcs_9_28}, - {5, arcs_9_29}, - {1, arcs_9_30}, - {3, arcs_9_31}, - {4, arcs_9_32}, - {4, arcs_9_33}, - {4, arcs_9_34}, - {3, arcs_9_35}, - {1, arcs_9_36}, - {4, arcs_9_37}, - {3, arcs_9_38}, - {3, arcs_9_39}, - {4, arcs_9_40}, - {1, arcs_9_41}, -}; -static const arc arcs_10_0[1] = { - {40, 1}, -}; -static const arc arcs_10_1[2] = { - {57, 2}, - {0, 1}, -}; -static const arc arcs_10_2[1] = { - {58, 3}, -}; -static const arc arcs_10_3[1] = { - {0, 3}, -}; -static state states_10[4] = { - {1, arcs_10_0}, - {2, arcs_10_1}, - {1, arcs_10_2}, - {1, arcs_10_3}, -}; -static const arc arcs_11_0[3] = { - {6, 1}, - {63, 2}, - {69, 3}, -}; -static const arc arcs_11_1[3] = { - {65, 4}, - {69, 5}, - {0, 1}, -}; -static const arc arcs_11_2[1] = { - {69, 6}, -}; -static const arc arcs_11_3[3] = { - {65, 7}, - {66, 8}, - {0, 3}, -}; -static const arc arcs_11_4[3] = { - {63, 2}, - {69, 9}, - {0, 4}, -}; -static const arc arcs_11_5[2] = { - {65, 4}, - {0, 5}, -}; -static const arc arcs_11_6[2] = { - {65, 10}, - {0, 6}, -}; -static const arc arcs_11_7[5] = { - {6, 11}, - {63, 2}, - {67, 12}, - {69, 3}, - {0, 7}, -}; -static const arc arcs_11_8[1] = { - {58, 13}, -}; -static const arc arcs_11_9[3] = { - {65, 4}, - {66, 14}, - {0, 9}, -}; -static const arc arcs_11_10[1] = { - {0, 10}, -}; -static const arc arcs_11_11[3] = { - {65, 15}, - {69, 16}, - {0, 11}, -}; -static const arc arcs_11_12[2] = { - {65, 17}, - {0, 12}, -}; -static const arc arcs_11_13[2] = { - {65, 7}, - {0, 13}, -}; -static const arc arcs_11_14[1] = { - {58, 5}, -}; -static const arc arcs_11_15[3] = { - {63, 2}, - {69, 18}, - {0, 15}, -}; -static const arc arcs_11_16[2] = { - {65, 15}, - {0, 16}, -}; -static const arc arcs_11_17[4] = { - {6, 19}, - {63, 2}, - {69, 20}, - {0, 17}, -}; -static const arc arcs_11_18[3] = { - {65, 15}, - {66, 21}, - {0, 18}, -}; -static const arc arcs_11_19[3] = { - {65, 22}, - {69, 23}, - {0, 19}, -}; -static const arc arcs_11_20[3] = { - {65, 24}, - {66, 25}, - {0, 20}, -}; -static const arc arcs_11_21[1] = { - {58, 16}, -}; -static const arc arcs_11_22[3] = { - {63, 2}, - {69, 26}, - {0, 22}, -}; -static const arc arcs_11_23[2] = { - {65, 22}, - {0, 23}, -}; -static const arc arcs_11_24[4] = { - {6, 27}, - {63, 2}, - {69, 20}, - {0, 24}, -}; -static const arc arcs_11_25[1] = { - {58, 28}, -}; -static const arc arcs_11_26[3] = { - {65, 22}, - {66, 29}, - {0, 26}, -}; -static const arc arcs_11_27[3] = { - {65, 30}, - {69, 31}, - {0, 27}, -}; -static const arc arcs_11_28[2] = { - {65, 24}, - {0, 28}, -}; -static const arc arcs_11_29[1] = { - {58, 23}, -}; -static const arc arcs_11_30[3] = { - {63, 2}, - {69, 32}, - {0, 30}, -}; -static const arc arcs_11_31[2] = { - {65, 30}, - {0, 31}, -}; -static const arc arcs_11_32[3] = { - {65, 30}, - {66, 33}, - {0, 32}, -}; -static const arc arcs_11_33[1] = { - {58, 31}, -}; -static state states_11[34] = { - {3, arcs_11_0}, - {3, arcs_11_1}, - {1, arcs_11_2}, - {3, arcs_11_3}, - {3, arcs_11_4}, - {2, arcs_11_5}, - {2, arcs_11_6}, - {5, arcs_11_7}, - {1, arcs_11_8}, - {3, arcs_11_9}, - {1, arcs_11_10}, - {3, arcs_11_11}, - {2, arcs_11_12}, - {2, arcs_11_13}, - {1, arcs_11_14}, - {3, arcs_11_15}, - {2, arcs_11_16}, - {4, arcs_11_17}, - {3, arcs_11_18}, - {3, arcs_11_19}, - {3, arcs_11_20}, - {1, arcs_11_21}, - {3, arcs_11_22}, - {2, arcs_11_23}, - {4, arcs_11_24}, - {1, arcs_11_25}, - {3, arcs_11_26}, - {3, arcs_11_27}, - {2, arcs_11_28}, - {1, arcs_11_29}, - {3, arcs_11_30}, - {2, arcs_11_31}, - {3, arcs_11_32}, - {1, arcs_11_33}, -}; -static const arc arcs_12_0[1] = { - {40, 1}, -}; -static const arc arcs_12_1[1] = { - {0, 1}, -}; -static state states_12[2] = { - {1, arcs_12_0}, - {1, arcs_12_1}, -}; -static const arc arcs_13_0[2] = { - {3, 1}, - {4, 1}, -}; -static const arc arcs_13_1[1] = { - {0, 1}, -}; -static state states_13[2] = { - {2, arcs_13_0}, - {1, arcs_13_1}, -}; -static const arc arcs_14_0[1] = { - {70, 1}, -}; -static const arc arcs_14_1[2] = { - {71, 2}, - {2, 3}, -}; -static const arc arcs_14_2[2] = { - {2, 3}, - {70, 1}, -}; -static const arc arcs_14_3[1] = { - {0, 3}, -}; -static state states_14[4] = { - {1, arcs_14_0}, - {2, arcs_14_1}, - {2, arcs_14_2}, - {1, arcs_14_3}, -}; -static const arc arcs_15_0[8] = { - {72, 1}, - {73, 1}, - {74, 1}, - {75, 1}, - {76, 1}, - {77, 1}, - {78, 1}, - {79, 1}, -}; -static const arc arcs_15_1[1] = { - {0, 1}, -}; -static state states_15[2] = { - {8, arcs_15_0}, - {1, arcs_15_1}, -}; -static const arc arcs_16_0[1] = { - {80, 1}, -}; -static const arc arcs_16_1[4] = { - {66, 2}, - {81, 3}, - {82, 4}, - {0, 1}, -}; -static const arc arcs_16_2[2] = { - {80, 5}, - {83, 5}, -}; -static const arc arcs_16_3[1] = { - {0, 3}, -}; -static const arc arcs_16_4[2] = { - {47, 3}, - {83, 3}, -}; -static const arc arcs_16_5[3] = { - {66, 2}, - {59, 3}, - {0, 5}, -}; -static state states_16[6] = { - {1, arcs_16_0}, - {4, arcs_16_1}, - {2, arcs_16_2}, - {1, arcs_16_3}, - {2, arcs_16_4}, - {3, arcs_16_5}, -}; -static const arc arcs_17_0[1] = { - {57, 1}, -}; -static const arc arcs_17_1[1] = { - {58, 2}, -}; -static const arc arcs_17_2[2] = { - {66, 3}, - {0, 2}, -}; -static const arc arcs_17_3[2] = { - {80, 4}, - {83, 4}, -}; -static const arc arcs_17_4[1] = { - {0, 4}, -}; -static state states_17[5] = { - {1, arcs_17_0}, - {1, arcs_17_1}, - {2, arcs_17_2}, - {2, arcs_17_3}, - {1, arcs_17_4}, -}; -static const arc arcs_18_0[2] = { - {84, 1}, - {58, 1}, -}; -static const arc arcs_18_1[2] = { - {65, 2}, - {0, 1}, -}; -static const arc arcs_18_2[3] = { - {84, 1}, - {58, 1}, - {0, 2}, -}; -static state states_18[3] = { - {2, arcs_18_0}, - {2, arcs_18_1}, - {3, arcs_18_2}, -}; -static const arc arcs_19_0[13] = { - {85, 1}, - {86, 1}, - {87, 1}, - {88, 1}, - {89, 1}, - {90, 1}, - {91, 1}, - {92, 1}, - {93, 1}, - {94, 1}, - {95, 1}, - {96, 1}, - {97, 1}, -}; -static const arc arcs_19_1[1] = { - {0, 1}, -}; -static state states_19[2] = { - {13, arcs_19_0}, - {1, arcs_19_1}, -}; -static const arc arcs_20_0[1] = { - {20, 1}, -}; -static const arc arcs_20_1[1] = { - {98, 2}, -}; -static const arc arcs_20_2[1] = { - {0, 2}, -}; -static state states_20[3] = { - {1, arcs_20_0}, - {1, arcs_20_1}, - {1, arcs_20_2}, -}; -static const arc arcs_21_0[1] = { - {29, 1}, -}; -static const arc arcs_21_1[1] = { - {0, 1}, -}; -static state states_21[2] = { - {1, arcs_21_0}, - {1, arcs_21_1}, -}; -static const arc arcs_22_0[5] = { - {99, 1}, - {100, 1}, - {101, 1}, - {102, 1}, - {103, 1}, -}; -static const arc arcs_22_1[1] = { - {0, 1}, -}; -static state states_22[2] = { - {5, arcs_22_0}, - {1, arcs_22_1}, -}; -static const arc arcs_23_0[1] = { - {16, 1}, -}; -static const arc arcs_23_1[1] = { - {0, 1}, -}; -static state states_23[2] = { - {1, arcs_23_0}, - {1, arcs_23_1}, -}; -static const arc arcs_24_0[1] = { - {18, 1}, -}; -static const arc arcs_24_1[1] = { - {0, 1}, -}; -static state states_24[2] = { - {1, arcs_24_0}, - {1, arcs_24_1}, -}; -static const arc arcs_25_0[1] = { - {31, 1}, -}; -static const arc arcs_25_1[2] = { - {80, 2}, - {0, 1}, -}; -static const arc arcs_25_2[1] = { - {0, 2}, -}; -static state states_25[3] = { - {1, arcs_25_0}, - {2, arcs_25_1}, - {1, arcs_25_2}, -}; -static const arc arcs_26_0[1] = { - {83, 1}, -}; -static const arc arcs_26_1[1] = { - {0, 1}, -}; -static state states_26[2] = { - {1, arcs_26_0}, - {1, arcs_26_1}, -}; -static const arc arcs_27_0[1] = { - {30, 1}, -}; -static const arc arcs_27_1[2] = { - {58, 2}, - {0, 1}, -}; -static const arc arcs_27_2[2] = { - {22, 3}, - {0, 2}, -}; -static const arc arcs_27_3[1] = { - {58, 4}, -}; -static const arc arcs_27_4[1] = { - {0, 4}, -}; -static state states_27[5] = { - {1, arcs_27_0}, - {2, arcs_27_1}, - {2, arcs_27_2}, - {1, arcs_27_3}, - {1, arcs_27_4}, -}; -static const arc arcs_28_0[2] = { - {104, 1}, - {105, 1}, -}; -static const arc arcs_28_1[1] = { - {0, 1}, -}; -static state states_28[2] = { - {2, arcs_28_0}, - {1, arcs_28_1}, -}; -static const arc arcs_29_0[1] = { - {25, 1}, -}; -static const arc arcs_29_1[1] = { - {106, 2}, -}; -static const arc arcs_29_2[1] = { - {0, 2}, -}; -static state states_29[3] = { - {1, arcs_29_0}, - {1, arcs_29_1}, - {1, arcs_29_2}, -}; -static const arc arcs_30_0[1] = { - {22, 1}, -}; -static const arc arcs_30_1[3] = { - {107, 2}, - {9, 2}, - {108, 3}, -}; -static const arc arcs_30_2[4] = { - {107, 2}, - {9, 2}, - {25, 4}, - {108, 3}, -}; -static const arc arcs_30_3[1] = { - {25, 4}, -}; -static const arc arcs_30_4[3] = { - {5, 5}, - {6, 6}, - {109, 6}, -}; -static const arc arcs_30_5[1] = { - {109, 7}, -}; -static const arc arcs_30_6[1] = { - {0, 6}, -}; -static const arc arcs_30_7[1] = { - {61, 6}, -}; -static state states_30[8] = { - {1, arcs_30_0}, - {3, arcs_30_1}, - {4, arcs_30_2}, - {1, arcs_30_3}, - {3, arcs_30_4}, - {1, arcs_30_5}, - {1, arcs_30_6}, - {1, arcs_30_7}, -}; -static const arc arcs_31_0[1] = { - {40, 1}, -}; -static const arc arcs_31_1[2] = { - {111, 2}, - {0, 1}, -}; -static const arc arcs_31_2[1] = { - {40, 3}, -}; -static const arc arcs_31_3[1] = { - {0, 3}, -}; -static state states_31[4] = { - {1, arcs_31_0}, - {2, arcs_31_1}, - {1, arcs_31_2}, - {1, arcs_31_3}, -}; -static const arc arcs_32_0[1] = { - {108, 1}, -}; -static const arc arcs_32_1[2] = { - {111, 2}, - {0, 1}, -}; -static const arc arcs_32_2[1] = { - {40, 3}, -}; -static const arc arcs_32_3[1] = { - {0, 3}, -}; -static state states_32[4] = { - {1, arcs_32_0}, - {2, arcs_32_1}, - {1, arcs_32_2}, - {1, arcs_32_3}, -}; -static const arc arcs_33_0[1] = { - {110, 1}, -}; -static const arc arcs_33_1[2] = { - {65, 2}, - {0, 1}, -}; -static const arc arcs_33_2[2] = { - {110, 1}, - {0, 2}, -}; -static state states_33[3] = { - {1, arcs_33_0}, - {2, arcs_33_1}, - {2, arcs_33_2}, -}; -static const arc arcs_34_0[1] = { - {112, 1}, -}; -static const arc arcs_34_1[2] = { - {65, 0}, - {0, 1}, -}; -static state states_34[2] = { - {1, arcs_34_0}, - {2, arcs_34_1}, -}; -static const arc arcs_35_0[1] = { - {40, 1}, -}; -static const arc arcs_35_1[2] = { - {107, 0}, - {0, 1}, -}; -static state states_35[2] = { - {1, arcs_35_0}, - {2, arcs_35_1}, -}; -static const arc arcs_36_0[1] = { - {23, 1}, -}; -static const arc arcs_36_1[1] = { - {40, 2}, -}; -static const arc arcs_36_2[2] = { - {65, 1}, - {0, 2}, -}; -static state states_36[3] = { - {1, arcs_36_0}, - {1, arcs_36_1}, - {2, arcs_36_2}, -}; -static const arc arcs_37_0[1] = { - {27, 1}, -}; -static const arc arcs_37_1[1] = { - {40, 2}, -}; -static const arc arcs_37_2[2] = { - {65, 1}, - {0, 2}, -}; -static state states_37[3] = { - {1, arcs_37_0}, - {1, arcs_37_1}, - {2, arcs_37_2}, -}; -static const arc arcs_38_0[1] = { - {15, 1}, -}; -static const arc arcs_38_1[1] = { - {58, 2}, -}; -static const arc arcs_38_2[2] = { - {65, 3}, - {0, 2}, -}; -static const arc arcs_38_3[1] = { - {58, 4}, -}; -static const arc arcs_38_4[1] = { - {0, 4}, -}; -static state states_38[5] = { - {1, arcs_38_0}, - {1, arcs_38_1}, - {2, arcs_38_2}, - {1, arcs_38_3}, - {1, arcs_38_4}, -}; -static const arc arcs_39_0[9] = { - {113, 1}, - {53, 1}, - {51, 1}, - {114, 1}, - {54, 1}, - {115, 1}, - {116, 1}, - {117, 1}, - {118, 1}, -}; -static const arc arcs_39_1[1] = { - {0, 1}, -}; -static state states_39[2] = { - {9, arcs_39_0}, - {1, arcs_39_1}, -}; -static const arc arcs_40_0[1] = { - {38, 1}, -}; -static const arc arcs_40_1[3] = { - {114, 2}, - {54, 2}, - {118, 2}, -}; -static const arc arcs_40_2[1] = { - {0, 2}, -}; -static state states_40[3] = { - {1, arcs_40_0}, - {3, arcs_40_1}, - {1, arcs_40_2}, -}; -static const arc arcs_41_0[1] = { - {24, 1}, -}; -static const arc arcs_41_1[1] = { - {49, 2}, -}; -static const arc arcs_41_2[1] = { - {57, 3}, -}; -static const arc arcs_41_3[1] = { - {119, 4}, -}; -static const arc arcs_41_4[3] = { - {120, 1}, - {121, 5}, - {0, 4}, -}; -static const arc arcs_41_5[1] = { - {57, 6}, -}; -static const arc arcs_41_6[1] = { - {119, 7}, -}; -static const arc arcs_41_7[1] = { - {0, 7}, -}; -static state states_41[8] = { - {1, arcs_41_0}, - {1, arcs_41_1}, - {1, arcs_41_2}, - {1, arcs_41_3}, - {3, arcs_41_4}, - {1, arcs_41_5}, - {1, arcs_41_6}, - {1, arcs_41_7}, -}; -static const arc arcs_42_0[1] = { - {33, 1}, -}; -static const arc arcs_42_1[1] = { - {49, 2}, -}; -static const arc arcs_42_2[1] = { - {57, 3}, -}; -static const arc arcs_42_3[1] = { - {119, 4}, -}; -static const arc arcs_42_4[2] = { - {121, 5}, - {0, 4}, -}; -static const arc arcs_42_5[1] = { - {57, 6}, -}; -static const arc arcs_42_6[1] = { - {119, 7}, -}; -static const arc arcs_42_7[1] = { - {0, 7}, -}; -static state states_42[8] = { - {1, arcs_42_0}, - {1, arcs_42_1}, - {1, arcs_42_2}, - {1, arcs_42_3}, - {2, arcs_42_4}, - {1, arcs_42_5}, - {1, arcs_42_6}, - {1, arcs_42_7}, -}; -static const arc arcs_43_0[1] = { - {21, 1}, -}; -static const arc arcs_43_1[1] = { - {98, 2}, -}; -static const arc arcs_43_2[1] = { - {122, 3}, -}; -static const arc arcs_43_3[1] = { - {47, 4}, -}; -static const arc arcs_43_4[1] = { - {57, 5}, -}; -static const arc arcs_43_5[2] = { - {59, 6}, - {119, 7}, -}; -static const arc arcs_43_6[1] = { - {119, 7}, -}; -static const arc arcs_43_7[2] = { - {121, 8}, - {0, 7}, -}; -static const arc arcs_43_8[1] = { - {57, 9}, -}; -static const arc arcs_43_9[1] = { - {119, 10}, -}; -static const arc arcs_43_10[1] = { - {0, 10}, -}; -static state states_43[11] = { - {1, arcs_43_0}, - {1, arcs_43_1}, - {1, arcs_43_2}, - {1, arcs_43_3}, - {1, arcs_43_4}, - {2, arcs_43_5}, - {1, arcs_43_6}, - {2, arcs_43_7}, - {1, arcs_43_8}, - {1, arcs_43_9}, - {1, arcs_43_10}, -}; -static const arc arcs_44_0[1] = { - {32, 1}, -}; -static const arc arcs_44_1[1] = { - {57, 2}, -}; -static const arc arcs_44_2[1] = { - {119, 3}, -}; -static const arc arcs_44_3[2] = { - {123, 4}, - {124, 5}, -}; -static const arc arcs_44_4[1] = { - {57, 6}, -}; -static const arc arcs_44_5[1] = { - {57, 7}, -}; -static const arc arcs_44_6[1] = { - {119, 8}, -}; -static const arc arcs_44_7[1] = { - {119, 9}, -}; -static const arc arcs_44_8[1] = { - {0, 8}, -}; -static const arc arcs_44_9[4] = { - {121, 10}, - {123, 4}, - {124, 5}, - {0, 9}, -}; -static const arc arcs_44_10[1] = { - {57, 11}, -}; -static const arc arcs_44_11[1] = { - {119, 12}, -}; -static const arc arcs_44_12[2] = { - {123, 4}, - {0, 12}, -}; -static state states_44[13] = { - {1, arcs_44_0}, - {1, arcs_44_1}, - {1, arcs_44_2}, - {2, arcs_44_3}, - {1, arcs_44_4}, - {1, arcs_44_5}, - {1, arcs_44_6}, - {1, arcs_44_7}, - {1, arcs_44_8}, - {4, arcs_44_9}, - {1, arcs_44_10}, - {1, arcs_44_11}, - {2, arcs_44_12}, -}; -static const arc arcs_45_0[1] = { - {34, 1}, -}; -static const arc arcs_45_1[1] = { - {125, 2}, -}; -static const arc arcs_45_2[2] = { - {65, 1}, - {57, 3}, -}; -static const arc arcs_45_3[2] = { - {59, 4}, - {119, 5}, -}; -static const arc arcs_45_4[1] = { - {119, 5}, -}; -static const arc arcs_45_5[1] = { - {0, 5}, -}; -static state states_45[6] = { - {1, arcs_45_0}, - {1, arcs_45_1}, - {2, arcs_45_2}, - {2, arcs_45_3}, - {1, arcs_45_4}, - {1, arcs_45_5}, -}; -static const arc arcs_46_0[1] = { - {58, 1}, -}; -static const arc arcs_46_1[2] = { - {111, 2}, - {0, 1}, -}; -static const arc arcs_46_2[1] = { - {126, 3}, -}; -static const arc arcs_46_3[1] = { - {0, 3}, -}; -static state states_46[4] = { - {1, arcs_46_0}, - {2, arcs_46_1}, - {1, arcs_46_2}, - {1, arcs_46_3}, -}; -static const arc arcs_47_0[1] = { - {127, 1}, -}; -static const arc arcs_47_1[2] = { - {58, 2}, - {0, 1}, -}; -static const arc arcs_47_2[2] = { - {111, 3}, - {0, 2}, -}; -static const arc arcs_47_3[1] = { - {40, 4}, -}; -static const arc arcs_47_4[1] = { - {0, 4}, -}; -static state states_47[5] = { - {1, arcs_47_0}, - {2, arcs_47_1}, - {2, arcs_47_2}, - {1, arcs_47_3}, - {1, arcs_47_4}, -}; -static const arc arcs_48_0[2] = { - {2, 1}, - {4, 2}, -}; -static const arc arcs_48_1[1] = { - {128, 3}, -}; -static const arc arcs_48_2[1] = { - {0, 2}, -}; -static const arc arcs_48_3[1] = { - {45, 4}, -}; -static const arc arcs_48_4[2] = { - {129, 2}, - {45, 4}, -}; -static state states_48[5] = { - {2, arcs_48_0}, - {1, arcs_48_1}, - {1, arcs_48_2}, - {1, arcs_48_3}, - {2, arcs_48_4}, -}; -static const arc arcs_49_0[1] = { - {58, 1}, -}; -static const arc arcs_49_1[2] = { - {130, 2}, - {0, 1}, -}; -static const arc arcs_49_2[1] = { - {58, 3}, -}; -static const arc arcs_49_3[1] = { - {0, 3}, -}; -static state states_49[4] = { - {1, arcs_49_0}, - {2, arcs_49_1}, - {1, arcs_49_2}, - {1, arcs_49_3}, -}; -static const arc arcs_50_0[2] = { - {131, 1}, - {132, 2}, -}; -static const arc arcs_50_1[1] = { - {0, 1}, -}; -static const arc arcs_50_2[2] = { - {24, 3}, - {0, 2}, -}; -static const arc arcs_50_3[1] = { - {132, 4}, -}; -static const arc arcs_50_4[1] = { - {121, 5}, -}; -static const arc arcs_50_5[1] = { - {58, 1}, -}; -static state states_50[6] = { - {2, arcs_50_0}, - {1, arcs_50_1}, - {2, arcs_50_2}, - {1, arcs_50_3}, - {1, arcs_50_4}, - {1, arcs_50_5}, -}; -static const arc arcs_51_0[2] = { - {134, 1}, - {132, 1}, -}; -static const arc arcs_51_1[1] = { - {0, 1}, -}; -static state states_51[2] = { - {2, arcs_51_0}, - {1, arcs_51_1}, -}; -static const arc arcs_52_0[1] = { - {26, 1}, -}; -static const arc arcs_52_1[2] = { - {57, 2}, - {68, 3}, -}; -static const arc arcs_52_2[1] = { - {58, 4}, -}; -static const arc arcs_52_3[1] = { - {57, 2}, -}; -static const arc arcs_52_4[1] = { - {0, 4}, -}; -static state states_52[5] = { - {1, arcs_52_0}, - {2, arcs_52_1}, - {1, arcs_52_2}, - {1, arcs_52_3}, - {1, arcs_52_4}, -}; -static const arc arcs_53_0[1] = { - {26, 1}, -}; -static const arc arcs_53_1[2] = { - {57, 2}, - {68, 3}, -}; -static const arc arcs_53_2[1] = { - {133, 4}, -}; -static const arc arcs_53_3[1] = { - {57, 2}, -}; -static const arc arcs_53_4[1] = { - {0, 4}, -}; -static state states_53[5] = { - {1, arcs_53_0}, - {2, arcs_53_1}, - {1, arcs_53_2}, - {1, arcs_53_3}, - {1, arcs_53_4}, -}; -static const arc arcs_54_0[1] = { - {135, 1}, -}; -static const arc arcs_54_1[2] = { - {136, 0}, - {0, 1}, -}; -static state states_54[2] = { - {1, arcs_54_0}, - {2, arcs_54_1}, -}; -static const arc arcs_55_0[1] = { - {137, 1}, -}; -static const arc arcs_55_1[2] = { - {138, 0}, - {0, 1}, -}; -static state states_55[2] = { - {1, arcs_55_0}, - {2, arcs_55_1}, -}; -static const arc arcs_56_0[2] = { - {28, 1}, - {139, 2}, -}; -static const arc arcs_56_1[1] = { - {137, 2}, -}; -static const arc arcs_56_2[1] = { - {0, 2}, -}; -static state states_56[3] = { - {2, arcs_56_0}, - {1, arcs_56_1}, - {1, arcs_56_2}, -}; -static const arc arcs_57_0[1] = { - {126, 1}, -}; -static const arc arcs_57_1[2] = { - {140, 0}, - {0, 1}, -}; -static state states_57[2] = { - {1, arcs_57_0}, - {2, arcs_57_1}, -}; -static const arc arcs_58_0[10] = { - {141, 1}, - {142, 1}, - {143, 1}, - {141, 1}, - {144, 1}, - {145, 1}, - {146, 1}, - {122, 1}, - {147, 2}, - {28, 3}, -}; -static const arc arcs_58_1[1] = { - {0, 1}, -}; -static const arc arcs_58_2[2] = { - {28, 1}, - {0, 2}, -}; -static const arc arcs_58_3[1] = { - {122, 1}, -}; -static state states_58[4] = { - {10, arcs_58_0}, - {1, arcs_58_1}, - {2, arcs_58_2}, - {1, arcs_58_3}, -}; -static const arc arcs_59_0[1] = { - {6, 1}, -}; -static const arc arcs_59_1[1] = { - {126, 2}, -}; -static const arc arcs_59_2[1] = { - {0, 2}, -}; -static state states_59[3] = { - {1, arcs_59_0}, - {1, arcs_59_1}, - {1, arcs_59_2}, -}; -static const arc arcs_60_0[1] = { - {148, 1}, -}; -static const arc arcs_60_1[2] = { - {149, 0}, - {0, 1}, -}; -static state states_60[2] = { - {1, arcs_60_0}, - {2, arcs_60_1}, -}; -static const arc arcs_61_0[1] = { - {150, 1}, -}; -static const arc arcs_61_1[2] = { - {151, 0}, - {0, 1}, -}; -static state states_61[2] = { - {1, arcs_61_0}, - {2, arcs_61_1}, -}; -static const arc arcs_62_0[1] = { - {152, 1}, -}; -static const arc arcs_62_1[2] = { - {153, 0}, - {0, 1}, -}; -static state states_62[2] = { - {1, arcs_62_0}, - {2, arcs_62_1}, -}; -static const arc arcs_63_0[1] = { - {154, 1}, -}; -static const arc arcs_63_1[3] = { - {155, 0}, - {156, 0}, - {0, 1}, -}; -static state states_63[2] = { - {1, arcs_63_0}, - {3, arcs_63_1}, -}; -static const arc arcs_64_0[1] = { - {157, 1}, -}; -static const arc arcs_64_1[3] = { - {7, 0}, - {8, 0}, - {0, 1}, -}; -static state states_64[2] = { - {1, arcs_64_0}, - {3, arcs_64_1}, -}; -static const arc arcs_65_0[1] = { - {158, 1}, -}; -static const arc arcs_65_1[6] = { - {159, 0}, - {6, 0}, - {67, 0}, - {160, 0}, - {10, 0}, - {0, 1}, -}; -static state states_65[2] = { - {1, arcs_65_0}, - {6, arcs_65_1}, -}; -static const arc arcs_66_0[4] = { - {7, 1}, - {8, 1}, - {37, 1}, - {161, 2}, -}; -static const arc arcs_66_1[1] = { - {158, 2}, -}; -static const arc arcs_66_2[1] = { - {0, 2}, -}; -static state states_66[3] = { - {4, arcs_66_0}, - {1, arcs_66_1}, - {1, arcs_66_2}, -}; -static const arc arcs_67_0[1] = { - {162, 1}, -}; -static const arc arcs_67_1[2] = { - {63, 2}, - {0, 1}, -}; -static const arc arcs_67_2[1] = { - {158, 3}, -}; -static const arc arcs_67_3[1] = { - {0, 3}, -}; -static state states_67[4] = { - {1, arcs_67_0}, - {2, arcs_67_1}, - {1, arcs_67_2}, - {1, arcs_67_3}, -}; -static const arc arcs_68_0[2] = { - {39, 1}, - {163, 2}, -}; -static const arc arcs_68_1[1] = { - {163, 2}, -}; -static const arc arcs_68_2[2] = { - {164, 2}, - {0, 2}, -}; -static state states_68[3] = { - {2, arcs_68_0}, - {1, arcs_68_1}, - {2, arcs_68_2}, -}; -static const arc arcs_69_0[10] = { - {5, 1}, - {9, 2}, - {11, 2}, - {12, 2}, - {13, 2}, - {14, 3}, - {36, 4}, - {40, 2}, - {41, 2}, - {42, 5}, -}; -static const arc arcs_69_1[3] = { - {61, 2}, - {165, 6}, - {83, 6}, -}; -static const arc arcs_69_2[1] = { - {0, 2}, -}; -static const arc arcs_69_3[2] = { - {166, 2}, - {165, 7}, -}; -static const arc arcs_69_4[2] = { - {167, 2}, - {168, 8}, -}; -static const arc arcs_69_5[2] = { - {42, 5}, - {0, 5}, -}; -static const arc arcs_69_6[1] = { - {61, 2}, -}; -static const arc arcs_69_7[1] = { - {166, 2}, -}; -static const arc arcs_69_8[1] = { - {167, 2}, -}; -static state states_69[9] = { - {10, arcs_69_0}, - {3, arcs_69_1}, - {1, arcs_69_2}, - {2, arcs_69_3}, - {2, arcs_69_4}, - {2, arcs_69_5}, - {1, arcs_69_6}, - {1, arcs_69_7}, - {1, arcs_69_8}, -}; -static const arc arcs_70_0[2] = { - {49, 1}, - {84, 1}, -}; -static const arc arcs_70_1[3] = { - {65, 2}, - {169, 3}, - {0, 1}, -}; -static const arc arcs_70_2[3] = { - {49, 4}, - {84, 4}, - {0, 2}, -}; -static const arc arcs_70_3[1] = { - {0, 3}, -}; -static const arc arcs_70_4[2] = { - {65, 2}, - {0, 4}, -}; -static state states_70[5] = { - {2, arcs_70_0}, - {3, arcs_70_1}, - {3, arcs_70_2}, - {1, arcs_70_3}, - {2, arcs_70_4}, -}; -static const arc arcs_71_0[3] = { - {5, 1}, - {107, 2}, - {14, 3}, -}; -static const arc arcs_71_1[2] = { - {61, 4}, - {170, 5}, -}; -static const arc arcs_71_2[1] = { - {40, 4}, -}; -static const arc arcs_71_3[1] = { - {171, 6}, -}; -static const arc arcs_71_4[1] = { - {0, 4}, -}; -static const arc arcs_71_5[1] = { - {61, 4}, -}; -static const arc arcs_71_6[1] = { - {166, 4}, -}; -static state states_71[7] = { - {3, arcs_71_0}, - {2, arcs_71_1}, - {1, arcs_71_2}, - {1, arcs_71_3}, - {1, arcs_71_4}, - {1, arcs_71_5}, - {1, arcs_71_6}, -}; -static const arc arcs_72_0[1] = { - {172, 1}, -}; -static const arc arcs_72_1[2] = { - {65, 2}, - {0, 1}, -}; -static const arc arcs_72_2[2] = { - {172, 1}, - {0, 2}, -}; -static state states_72[3] = { - {1, arcs_72_0}, - {2, arcs_72_1}, - {2, arcs_72_2}, -}; -static const arc arcs_73_0[2] = { - {57, 1}, - {58, 2}, -}; -static const arc arcs_73_1[3] = { - {173, 3}, - {58, 4}, - {0, 1}, -}; -static const arc arcs_73_2[2] = { - {57, 1}, - {0, 2}, -}; -static const arc arcs_73_3[1] = { - {0, 3}, -}; -static const arc arcs_73_4[2] = { - {173, 3}, - {0, 4}, -}; -static state states_73[5] = { - {2, arcs_73_0}, - {3, arcs_73_1}, - {2, arcs_73_2}, - {1, arcs_73_3}, - {2, arcs_73_4}, -}; -static const arc arcs_74_0[1] = { - {57, 1}, -}; -static const arc arcs_74_1[2] = { - {58, 2}, - {0, 1}, -}; -static const arc arcs_74_2[1] = { - {0, 2}, -}; -static state states_74[3] = { - {1, arcs_74_0}, - {2, arcs_74_1}, - {1, arcs_74_2}, -}; -static const arc arcs_75_0[2] = { - {126, 1}, - {84, 1}, -}; -static const arc arcs_75_1[2] = { - {65, 2}, - {0, 1}, -}; -static const arc arcs_75_2[3] = { - {126, 1}, - {84, 1}, - {0, 2}, -}; -static state states_75[3] = { - {2, arcs_75_0}, - {2, arcs_75_1}, - {3, arcs_75_2}, -}; -static const arc arcs_76_0[1] = { - {58, 1}, -}; -static const arc arcs_76_1[2] = { - {65, 2}, - {0, 1}, -}; -static const arc arcs_76_2[2] = { - {58, 1}, - {0, 2}, -}; -static state states_76[3] = { - {1, arcs_76_0}, - {2, arcs_76_1}, - {2, arcs_76_2}, -}; -static const arc arcs_77_0[3] = { - {63, 1}, - {84, 2}, - {58, 3}, -}; -static const arc arcs_77_1[1] = { - {126, 4}, -}; -static const arc arcs_77_2[3] = { - {65, 5}, - {169, 6}, - {0, 2}, -}; -static const arc arcs_77_3[4] = { - {65, 5}, - {57, 7}, - {169, 6}, - {0, 3}, -}; -static const arc arcs_77_4[3] = { - {65, 8}, - {169, 6}, - {0, 4}, -}; -static const arc arcs_77_5[3] = { - {84, 9}, - {58, 9}, - {0, 5}, -}; -static const arc arcs_77_6[1] = { - {0, 6}, -}; -static const arc arcs_77_7[1] = { - {58, 4}, -}; -static const arc arcs_77_8[3] = { - {63, 10}, - {58, 11}, - {0, 8}, -}; -static const arc arcs_77_9[2] = { - {65, 5}, - {0, 9}, -}; -static const arc arcs_77_10[1] = { - {126, 12}, -}; -static const arc arcs_77_11[1] = { - {57, 13}, -}; -static const arc arcs_77_12[2] = { - {65, 8}, - {0, 12}, -}; -static const arc arcs_77_13[1] = { - {58, 12}, -}; -static state states_77[14] = { - {3, arcs_77_0}, - {1, arcs_77_1}, - {3, arcs_77_2}, - {4, arcs_77_3}, - {3, arcs_77_4}, - {3, arcs_77_5}, - {1, arcs_77_6}, - {1, arcs_77_7}, - {3, arcs_77_8}, - {2, arcs_77_9}, - {1, arcs_77_10}, - {1, arcs_77_11}, - {2, arcs_77_12}, - {1, arcs_77_13}, -}; -static const arc arcs_78_0[1] = { - {17, 1}, -}; -static const arc arcs_78_1[1] = { - {40, 2}, -}; -static const arc arcs_78_2[2] = { - {5, 3}, - {57, 4}, -}; -static const arc arcs_78_3[2] = { - {61, 5}, - {170, 6}, -}; -static const arc arcs_78_4[1] = { - {119, 7}, -}; -static const arc arcs_78_5[1] = { - {57, 4}, -}; -static const arc arcs_78_6[1] = { - {61, 5}, -}; -static const arc arcs_78_7[1] = { - {0, 7}, -}; -static state states_78[8] = { - {1, arcs_78_0}, - {1, arcs_78_1}, - {2, arcs_78_2}, - {2, arcs_78_3}, - {1, arcs_78_4}, - {1, arcs_78_5}, - {1, arcs_78_6}, - {1, arcs_78_7}, -}; -static const arc arcs_79_0[1] = { - {174, 1}, -}; -static const arc arcs_79_1[2] = { - {65, 2}, - {0, 1}, -}; -static const arc arcs_79_2[2] = { - {174, 1}, - {0, 2}, -}; -static state states_79[3] = { - {1, arcs_79_0}, - {2, arcs_79_1}, - {2, arcs_79_2}, -}; -static const arc arcs_80_0[3] = { - {6, 1}, - {63, 1}, - {58, 2}, -}; -static const arc arcs_80_1[1] = { - {58, 3}, -}; -static const arc arcs_80_2[4] = { - {130, 1}, - {66, 1}, - {169, 3}, - {0, 2}, -}; -static const arc arcs_80_3[1] = { - {0, 3}, -}; -static state states_80[4] = { - {3, arcs_80_0}, - {1, arcs_80_1}, - {4, arcs_80_2}, - {1, arcs_80_3}, -}; -static const arc arcs_81_0[2] = { - {169, 1}, - {176, 1}, -}; -static const arc arcs_81_1[1] = { - {0, 1}, -}; -static state states_81[2] = { - {2, arcs_81_0}, - {1, arcs_81_1}, -}; -static const arc arcs_82_0[1] = { - {21, 1}, -}; -static const arc arcs_82_1[1] = { - {98, 2}, -}; -static const arc arcs_82_2[1] = { - {122, 3}, -}; -static const arc arcs_82_3[1] = { - {132, 4}, -}; -static const arc arcs_82_4[2] = { - {175, 5}, - {0, 4}, -}; -static const arc arcs_82_5[1] = { - {0, 5}, -}; -static state states_82[6] = { - {1, arcs_82_0}, - {1, arcs_82_1}, - {1, arcs_82_2}, - {1, arcs_82_3}, - {2, arcs_82_4}, - {1, arcs_82_5}, -}; -static const arc arcs_83_0[2] = { - {38, 1}, - {177, 2}, -}; -static const arc arcs_83_1[1] = { - {177, 2}, -}; -static const arc arcs_83_2[1] = { - {0, 2}, -}; -static state states_83[3] = { - {2, arcs_83_0}, - {1, arcs_83_1}, - {1, arcs_83_2}, -}; -static const arc arcs_84_0[1] = { - {24, 1}, -}; -static const arc arcs_84_1[1] = { - {133, 2}, -}; -static const arc arcs_84_2[2] = { - {175, 3}, - {0, 2}, -}; -static const arc arcs_84_3[1] = { - {0, 3}, -}; -static state states_84[4] = { - {1, arcs_84_0}, - {1, arcs_84_1}, - {2, arcs_84_2}, - {1, arcs_84_3}, -}; -static const arc arcs_85_0[1] = { - {40, 1}, -}; -static const arc arcs_85_1[1] = { - {0, 1}, -}; -static state states_85[2] = { - {1, arcs_85_0}, - {1, arcs_85_1}, -}; -static const arc arcs_86_0[1] = { - {35, 1}, -}; -static const arc arcs_86_1[2] = { - {179, 2}, - {0, 1}, -}; -static const arc arcs_86_2[1] = { - {0, 2}, -}; -static state states_86[3] = { - {1, arcs_86_0}, - {2, arcs_86_1}, - {1, arcs_86_2}, -}; -static const arc arcs_87_0[2] = { - {22, 1}, - {80, 2}, -}; -static const arc arcs_87_1[1] = { - {58, 2}, -}; -static const arc arcs_87_2[1] = { - {0, 2}, -}; -static state states_87[3] = { - {2, arcs_87_0}, - {1, arcs_87_1}, - {1, arcs_87_2}, -}; -static const arc arcs_88_0[2] = { - {2, 1}, - {4, 2}, -}; -static const arc arcs_88_1[2] = { - {128, 3}, - {59, 4}, -}; -static const arc arcs_88_2[1] = { - {0, 2}, -}; -static const arc arcs_88_3[1] = { - {45, 5}, -}; -static const arc arcs_88_4[1] = { - {2, 6}, -}; -static const arc arcs_88_5[2] = { - {129, 2}, - {45, 5}, -}; -static const arc arcs_88_6[1] = { - {128, 3}, -}; -static state states_88[7] = { - {2, arcs_88_0}, - {2, arcs_88_1}, - {1, arcs_88_2}, - {1, arcs_88_3}, - {1, arcs_88_4}, - {2, arcs_88_5}, - {1, arcs_88_6}, -}; -static const arc arcs_89_0[1] = { - {181, 1}, -}; -static const arc arcs_89_1[2] = { - {44, 2}, - {2, 1}, -}; -static const arc arcs_89_2[1] = { - {0, 2}, -}; -static state states_89[3] = { - {1, arcs_89_0}, - {2, arcs_89_1}, - {1, arcs_89_2}, -}; -static const arc arcs_90_0[1] = { - {5, 1}, -}; -static const arc arcs_90_1[2] = { - {61, 2}, - {182, 3}, -}; -static const arc arcs_90_2[1] = { - {56, 4}, -}; -static const arc arcs_90_3[1] = { - {61, 2}, -}; -static const arc arcs_90_4[1] = { - {58, 5}, -}; -static const arc arcs_90_5[1] = { - {0, 5}, -}; -static state states_90[6] = { - {1, arcs_90_0}, - {2, arcs_90_1}, - {1, arcs_90_2}, - {1, arcs_90_3}, - {1, arcs_90_4}, - {1, arcs_90_5}, -}; -static const arc arcs_91_0[3] = { - {6, 1}, - {63, 2}, - {58, 3}, -}; -static const arc arcs_91_1[3] = { - {65, 4}, - {58, 5}, - {0, 1}, -}; -static const arc arcs_91_2[1] = { - {58, 6}, -}; -static const arc arcs_91_3[2] = { - {65, 7}, - {0, 3}, -}; -static const arc arcs_91_4[2] = { - {63, 2}, - {58, 5}, -}; -static const arc arcs_91_5[2] = { - {65, 4}, - {0, 5}, -}; -static const arc arcs_91_6[1] = { - {0, 6}, -}; -static const arc arcs_91_7[4] = { - {6, 8}, - {63, 2}, - {58, 3}, - {0, 7}, -}; -static const arc arcs_91_8[3] = { - {65, 9}, - {58, 10}, - {0, 8}, -}; -static const arc arcs_91_9[2] = { - {63, 2}, - {58, 10}, -}; -static const arc arcs_91_10[2] = { - {65, 9}, - {0, 10}, -}; -static state states_91[11] = { - {3, arcs_91_0}, - {3, arcs_91_1}, - {1, arcs_91_2}, - {2, arcs_91_3}, - {2, arcs_91_4}, - {2, arcs_91_5}, - {1, arcs_91_6}, - {4, arcs_91_7}, - {3, arcs_91_8}, - {2, arcs_91_9}, - {2, arcs_91_10}, -}; -static const dfa dfas[92] = { - {256, "single_input", 3, states_0, - "\344\377\377\377\377\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {257, "file_input", 2, states_1, - "\344\377\377\377\377\027\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {258, "eval_input", 3, states_2, - "\240\173\000\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {259, "decorator", 4, states_3, - "\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {260, "decorators", 2, states_4, - "\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {261, "decorated", 3, states_5, - "\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {262, "async_funcdef", 3, states_6, - "\000\000\000\000\100\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {263, "funcdef", 9, states_7, - "\000\000\010\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {264, "parameters", 4, states_8, - "\040\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {265, "typedargslist", 42, states_9, - "\100\000\000\000\000\001\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {266, "tfpdef", 4, states_10, - "\000\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {267, "varargslist", 34, states_11, - "\100\000\000\000\000\001\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {268, "vfpdef", 2, states_12, - "\000\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {269, "stmt", 2, states_13, - "\340\377\377\377\377\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {270, "simple_stmt", 4, states_14, - "\340\373\325\376\270\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {271, "small_stmt", 2, states_15, - "\340\373\325\376\270\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {272, "expr_stmt", 6, states_16, - "\340\173\000\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {273, "annassign", 5, states_17, - "\000\000\000\000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {274, "testlist_star_expr", 3, states_18, - "\340\173\000\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {275, "augassign", 2, states_19, - "\000\000\000\000\000\000\000\000\000\000\340\377\003\000\000\000\000\000\000\000\000\000\000"}, - {276, "del_stmt", 3, states_20, - "\000\000\020\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {277, "pass_stmt", 2, states_21, - "\000\000\000\040\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {278, "flow_stmt", 2, states_22, - "\000\000\005\300\010\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {279, "break_stmt", 2, states_23, - "\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {280, "continue_stmt", 2, states_24, - "\000\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {281, "return_stmt", 3, states_25, - "\000\000\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {282, "yield_stmt", 2, states_26, - "\000\000\000\000\010\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {283, "raise_stmt", 5, states_27, - "\000\000\000\100\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {284, "import_stmt", 2, states_28, - "\000\000\100\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {285, "import_name", 3, states_29, - "\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {286, "import_from", 8, states_30, - "\000\000\100\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {287, "import_as_name", 4, states_31, - "\000\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {288, "dotted_as_name", 4, states_32, - "\000\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {289, "import_as_names", 3, states_33, - "\000\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {290, "dotted_as_names", 2, states_34, - "\000\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {291, "dotted_name", 2, states_35, - "\000\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {292, "global_stmt", 3, states_36, - "\000\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {293, "nonlocal_stmt", 3, states_37, - "\000\000\000\010\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {294, "assert_stmt", 5, states_38, - "\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {295, "compound_stmt", 2, states_39, - "\000\004\052\001\107\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {296, "async_stmt", 3, states_40, - "\000\000\000\000\100\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {297, "if_stmt", 8, states_41, - "\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {298, "while_stmt", 8, states_42, - "\000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {299, "for_stmt", 11, states_43, - "\000\000\040\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {300, "try_stmt", 13, states_44, - "\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {301, "with_stmt", 6, states_45, - "\000\000\000\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {302, "with_item", 4, states_46, - "\240\173\000\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {303, "except_clause", 5, states_47, - "\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\200\000\000\000\000\000\000\000"}, - {304, "suite", 5, states_48, - "\344\373\325\376\270\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {305, "namedexpr_test", 4, states_49, - "\240\173\000\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {306, "test", 6, states_50, - "\240\173\000\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {307, "test_nocond", 2, states_51, - "\240\173\000\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {308, "lambdef", 5, states_52, - "\000\000\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {309, "lambdef_nocond", 5, states_53, - "\000\000\000\004\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {310, "or_test", 2, states_54, - "\240\173\000\020\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {311, "and_test", 2, states_55, - "\240\173\000\020\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {312, "not_test", 3, states_56, - "\240\173\000\020\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {313, "comparison", 2, states_57, - "\240\173\000\000\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {314, "comp_op", 4, states_58, - "\000\000\000\020\000\000\000\000\000\000\000\000\000\000\000\004\000\340\017\000\000\000\000"}, - {315, "star_expr", 3, states_59, - "\100\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {316, "expr", 2, states_60, - "\240\173\000\000\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {317, "xor_expr", 2, states_61, - "\240\173\000\000\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {318, "and_expr", 2, states_62, - "\240\173\000\000\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {319, "shift_expr", 2, states_63, - "\240\173\000\000\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {320, "arith_expr", 2, states_64, - "\240\173\000\000\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {321, "term", 2, states_65, - "\240\173\000\000\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {322, "factor", 3, states_66, - "\240\173\000\000\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {323, "power", 4, states_67, - "\040\172\000\000\220\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {324, "atom_expr", 3, states_68, - "\040\172\000\000\220\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {325, "atom", 9, states_69, - "\040\172\000\000\020\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {326, "testlist_comp", 5, states_70, - "\340\173\000\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {327, "trailer", 7, states_71, - "\040\100\000\000\000\000\000\000\000\000\000\000\000\010\000\000\000\000\000\000\000\000\000"}, - {328, "subscriptlist", 3, states_72, - "\240\173\000\024\260\007\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {329, "subscript", 5, states_73, - "\240\173\000\024\260\007\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {330, "sliceop", 3, states_74, - "\000\000\000\000\000\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {331, "exprlist", 3, states_75, - "\340\173\000\000\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {332, "testlist", 3, states_76, - "\240\173\000\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {333, "dictorsetmaker", 14, states_77, - "\340\173\000\024\260\007\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {334, "classdef", 8, states_78, - "\000\000\002\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {335, "arglist", 3, states_79, - "\340\173\000\024\260\007\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {336, "argument", 4, states_80, - "\340\173\000\024\260\007\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {337, "comp_iter", 2, states_81, - "\000\000\040\001\100\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {338, "sync_comp_for", 6, states_82, - "\000\000\040\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {339, "comp_for", 3, states_83, - "\000\000\040\000\100\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {340, "comp_if", 4, states_84, - "\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {341, "encoding_decl", 2, states_85, - "\000\000\000\000\000\001\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {342, "yield_expr", 3, states_86, - "\000\000\000\000\010\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {343, "yield_arg", 3, states_87, - "\340\173\100\024\260\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {344, "func_body_suite", 7, states_88, - "\344\373\325\376\270\007\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {345, "func_type_input", 3, states_89, - "\040\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {346, "func_type", 6, states_90, - "\040\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, - {347, "typelist", 11, states_91, - "\340\173\000\024\260\007\000\200\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000"}, -}; -static const label labels[183] = { - {0, "EMPTY"}, - {256, 0}, - {4, 0}, - {295, 0}, - {270, 0}, - {7, 0}, - {16, 0}, - {14, 0}, - {15, 0}, - {52, 0}, - {49, 0}, - {1, "False"}, - {1, "None"}, - {1, "True"}, - {9, 0}, - {1, "assert"}, - {1, "break"}, - {1, "class"}, - {1, "continue"}, - {1, "def"}, - {1, "del"}, - {1, "for"}, - {1, "from"}, - {1, "global"}, - {1, "if"}, - {1, "import"}, - {1, "lambda"}, - {1, "nonlocal"}, - {1, "not"}, - {1, "pass"}, - {1, "raise"}, - {1, "return"}, - {1, "try"}, - {1, "while"}, - {1, "with"}, - {1, "yield"}, - {25, 0}, - {31, 0}, - {56, 0}, - {55, 0}, - {1, 0}, - {2, 0}, - {3, 0}, - {257, 0}, - {0, 0}, - {269, 0}, - {258, 0}, - {332, 0}, - {259, 0}, - {305, 0}, - {260, 0}, - {261, 0}, - {262, 0}, - {334, 0}, - {263, 0}, - {264, 0}, - {51, 0}, - {11, 0}, - {306, 0}, - {58, 0}, - {344, 0}, - {8, 0}, - {265, 0}, - {35, 0}, - {266, 0}, - {12, 0}, - {22, 0}, - {17, 0}, - {267, 0}, - {268, 0}, - {271, 0}, - {13, 0}, - {294, 0}, - {276, 0}, - {272, 0}, - {278, 0}, - {292, 0}, - {284, 0}, - {293, 0}, - {277, 0}, - {274, 0}, - {273, 0}, - {275, 0}, - {342, 0}, - {315, 0}, - {40, 0}, - {41, 0}, - {46, 0}, - {38, 0}, - {36, 0}, - {37, 0}, - {48, 0}, - {39, 0}, - {44, 0}, - {45, 0}, - {50, 0}, - {43, 0}, - {42, 0}, - {331, 0}, - {279, 0}, - {280, 0}, - {283, 0}, - {281, 0}, - {282, 0}, - {286, 0}, - {285, 0}, - {290, 0}, - {23, 0}, - {291, 0}, - {289, 0}, - {287, 0}, - {1, "as"}, - {288, 0}, - {296, 0}, - {299, 0}, - {297, 0}, - {300, 0}, - {298, 0}, - {301, 0}, - {304, 0}, - {1, "elif"}, - {1, "else"}, - {1, "in"}, - {1, "finally"}, - {303, 0}, - {302, 0}, - {316, 0}, - {1, "except"}, - {5, 0}, - {6, 0}, - {53, 0}, - {308, 0}, - {310, 0}, - {307, 0}, - {309, 0}, - {311, 0}, - {1, "or"}, - {312, 0}, - {1, "and"}, - {313, 0}, - {314, 0}, - {28, 0}, - {20, 0}, - {29, 0}, - {27, 0}, - {21, 0}, - {30, 0}, - {1, "is"}, - {317, 0}, - {18, 0}, - {318, 0}, - {32, 0}, - {319, 0}, - {19, 0}, - {320, 0}, - {33, 0}, - {34, 0}, - {321, 0}, - {322, 0}, - {24, 0}, - {47, 0}, - {323, 0}, - {324, 0}, - {325, 0}, - {327, 0}, - {326, 0}, - {10, 0}, - {26, 0}, - {333, 0}, - {339, 0}, - {335, 0}, - {328, 0}, - {329, 0}, - {330, 0}, - {336, 0}, - {337, 0}, - {340, 0}, - {338, 0}, - {341, 0}, - {343, 0}, - {345, 0}, - {346, 0}, - {347, 0}, -}; -Py_EXPORTED_SYMBOL grammar _PyParser_Grammar = { - 92, - dfas, - {183, labels}, - 256 -}; diff --git a/contrib/tools/python3/src/Python/hamt.c b/contrib/tools/python3/src/Python/hamt.c index 8801c5ea418..e272e8808fd 100644 --- a/contrib/tools/python3/src/Python/hamt.c +++ b/contrib/tools/python3/src/Python/hamt.c @@ -1,5 +1,6 @@ #include "Python.h" +#include "pycore_bitutils.h" // _Py_popcount32 #include "pycore_hamt.h" #include "pycore_object.h" // _PyObject_GC_TRACK() #include <stddef.h> // offsetof() @@ -434,29 +435,9 @@ hamt_bitpos(int32_t hash, uint32_t shift) } static inline uint32_t -hamt_bitcount(uint32_t i) -{ - /* We could use native popcount instruction but that would - require to either add configure flags to enable SSE4.2 - support or to detect it dynamically. Otherwise, we have - a risk of CPython not working properly on older hardware. - - In practice, there's no observable difference in - performance between using a popcount instruction or the - following fallback code. - - The algorithm is copied from: - https://graphics.stanford.edu/~seander/bithacks.html - */ - i = i - ((i >> 1) & 0x55555555); - i = (i & 0x33333333) + ((i >> 2) & 0x33333333); - return (((i + (i >> 4)) & 0xF0F0F0F) * 0x1010101) >> 24; -} - -static inline uint32_t hamt_bitindex(uint32_t bitmap, uint32_t bit) { - return hamt_bitcount(bitmap & (bit - 1)); + return (uint32_t)_Py_popcount32(bitmap & (bit - 1)); } @@ -820,7 +801,7 @@ hamt_node_bitmap_assoc(PyHamtNode_Bitmap *self, else { /* There was no key before with the same (shift,hash). */ - uint32_t n = hamt_bitcount(self->b_bitmap); + uint32_t n = (uint32_t)_Py_popcount32(self->b_bitmap); if (n >= 16) { /* When we have a situation where we want to store more diff --git a/contrib/tools/python3/src/Python/import.c b/contrib/tools/python3/src/Python/import.c index e4dbf4b0d8c..bd33fa184ab 100644 --- a/contrib/tools/python3/src/Python/import.c +++ b/contrib/tools/python3/src/Python/import.c @@ -2,8 +2,7 @@ #include "Python.h" -#include "Python-ast.h" -#undef Yield /* undefine macro conflicting with <winbase.h> */ +#include "pycore_import.h" // _PyImport_BootstrapImp() #include "pycore_initconfig.h" #include "pycore_pyerrors.h" #include "pycore_pyhash.h" @@ -52,43 +51,6 @@ module _imp /* Initialize things */ PyStatus -_PyImportHooks_Init(PyThreadState *tstate) -{ - PyObject *v, *path_hooks = NULL; - int err = 0; - - /* adding sys.path_hooks and sys.path_importer_cache */ - v = PyList_New(0); - if (v == NULL) - goto error; - err = PySys_SetObject("meta_path", v); - Py_DECREF(v); - if (err) - goto error; - v = PyDict_New(); - if (v == NULL) - goto error; - err = PySys_SetObject("path_importer_cache", v); - Py_DECREF(v); - if (err) - goto error; - path_hooks = PyList_New(0); - if (path_hooks == NULL) - goto error; - err = PySys_SetObject("path_hooks", path_hooks); - if (err) { - goto error; - } - Py_DECREF(path_hooks); - return _PyStatus_OK(); - - error: - _PyErr_Print(tstate); - return _PyStatus_ERR("initializing sys.meta_path, sys.path_hooks, " - "or path_importer_cache failed"); -} - -PyStatus _PyImportZip_Init(PyThreadState *tstate) { PyObject *path_hooks, *zipimport; @@ -148,7 +110,7 @@ _PyImportZip_Init(PyThreadState *tstate) in different threads to return with a partially loaded module. These calls are serialized by the global interpreter lock. */ -static PyThread_type_lock import_lock = 0; +static PyThread_type_lock import_lock = NULL; static unsigned long import_lock_thread = PYTHREAD_INVALID_THREAD_ID; static int import_lock_level = 0; @@ -171,7 +133,7 @@ _PyImport_AcquireLock(void) !PyThread_acquire_lock(import_lock, 0)) { PyThreadState *tstate = PyEval_SaveThread(); - PyThread_acquire_lock(import_lock, 1); + PyThread_acquire_lock(import_lock, WAIT_LOCK); PyEval_RestoreThread(tstate); } assert(import_lock_level == 0); @@ -197,33 +159,30 @@ _PyImport_ReleaseLock(void) } #ifdef HAVE_FORK -/* This function is called from PyOS_AfterFork_Child to ensure that newly +/* This function is called from PyOS_AfterFork_Child() to ensure that newly created child processes do not share locks with the parent. We now acquire the import lock around fork() calls but on some platforms (Solaris 9 and earlier? see isue7242) that still left us with problems. */ - -void +PyStatus _PyImport_ReInitLock(void) { if (import_lock != NULL) { if (_PyThread_at_fork_reinit(&import_lock) < 0) { - _Py_FatalErrorFunc(__func__, "failed to create a new lock"); + return _PyStatus_ERR("failed to create a new lock"); } } + if (import_lock_level > 1) { /* Forked as a side effect of import */ unsigned long me = PyThread_get_thread_ident(); - /* The following could fail if the lock is already held, but forking as - a side-effect of an import is a) rare, b) nuts, and c) difficult to - do thanks to the lock only being held when doing individual module - locks per import. */ - PyThread_acquire_lock(import_lock, NOWAIT_LOCK); + PyThread_acquire_lock(import_lock, WAIT_LOCK); import_lock_thread = me; import_lock_level--; } else { import_lock_thread = PYTHREAD_INVALID_THREAD_ID; import_lock_level = 0; } + return _PyStatus_OK(); } #endif @@ -343,16 +302,16 @@ _PyImport_GetModuleId(struct _Py_Identifier *nameid) int _PyImport_SetModule(PyObject *name, PyObject *m) { - PyThreadState *tstate = _PyThreadState_GET(); - PyObject *modules = tstate->interp->modules; + PyInterpreterState *interp = _PyInterpreterState_GET(); + PyObject *modules = interp->modules; return PyObject_SetItem(modules, name, m); } int _PyImport_SetModuleString(const char *name, PyObject *m) { - PyThreadState *tstate = _PyThreadState_GET(); - PyObject *modules = tstate->interp->modules; + PyInterpreterState *interp = _PyInterpreterState_GET(); + PyObject *modules = interp->modules; return PyMapping_SetItemString(modules, name, m); } @@ -384,9 +343,8 @@ import_get_module(PyThreadState *tstate, PyObject *name) static int -import_ensure_initialized(PyThreadState *tstate, PyObject *mod, PyObject *name) +import_ensure_initialized(PyInterpreterState *interp, PyObject *mod, PyObject *name) { - PyInterpreterState *interp = tstate->interp; PyObject *spec; _Py_IDENTIFIER(_lock_unlock_module); @@ -412,233 +370,6 @@ import_ensure_initialized(PyThreadState *tstate, PyObject *mod, PyObject *name) } -/* List of names to clear in sys */ -static const char * const sys_deletes[] = { - "path", "argv", "ps1", "ps2", - "last_type", "last_value", "last_traceback", - "path_hooks", "path_importer_cache", "meta_path", - "__interactivehook__", - NULL -}; - -static const char * const sys_files[] = { - "stdin", "__stdin__", - "stdout", "__stdout__", - "stderr", "__stderr__", - NULL -}; - -/* Un-initialize things, as good as we can */ - -void -_PyImport_Cleanup(PyThreadState *tstate) -{ - PyInterpreterState *interp = tstate->interp; - PyObject *modules = interp->modules; - if (modules == NULL) { - /* Already done */ - return; - } - - /* Delete some special variables first. These are common - places where user values hide and people complain when their - destructors fail. Since the modules containing them are - deleted *last* of all, they would come too late in the normal - destruction order. Sigh. */ - - /* XXX Perhaps these precautions are obsolete. Who knows? */ - - int verbose = _PyInterpreterState_GetConfig(interp)->verbose; - if (verbose) { - PySys_WriteStderr("# clear builtins._\n"); - } - if (PyDict_SetItemString(interp->builtins, "_", Py_None) < 0) { - PyErr_WriteUnraisable(NULL); - } - - const char * const *p; - for (p = sys_deletes; *p != NULL; p++) { - if (verbose) { - PySys_WriteStderr("# clear sys.%s\n", *p); - } - if (PyDict_SetItemString(interp->sysdict, *p, Py_None) < 0) { - PyErr_WriteUnraisable(NULL); - } - } - for (p = sys_files; *p != NULL; p+=2) { - if (verbose) { - PySys_WriteStderr("# restore sys.%s\n", *p); - } - PyObject *value = _PyDict_GetItemStringWithError(interp->sysdict, - *(p+1)); - if (value == NULL) { - if (_PyErr_Occurred(tstate)) { - PyErr_WriteUnraisable(NULL); - } - value = Py_None; - } - if (PyDict_SetItemString(interp->sysdict, *p, value) < 0) { - PyErr_WriteUnraisable(NULL); - } - } - - /* We prepare a list which will receive (name, weakref) tuples of - modules when they are removed from sys.modules. The name is used - for diagnosis messages (in verbose mode), while the weakref helps - detect those modules which have been held alive. */ - PyObject *weaklist = PyList_New(0); - if (weaklist == NULL) { - PyErr_WriteUnraisable(NULL); - } - -#define STORE_MODULE_WEAKREF(name, mod) \ - if (weaklist != NULL) { \ - PyObject *wr = PyWeakref_NewRef(mod, NULL); \ - if (wr) { \ - PyObject *tup = PyTuple_Pack(2, name, wr); \ - if (!tup || PyList_Append(weaklist, tup) < 0) { \ - PyErr_WriteUnraisable(NULL); \ - } \ - Py_XDECREF(tup); \ - Py_DECREF(wr); \ - } \ - else { \ - PyErr_WriteUnraisable(NULL); \ - } \ - } -#define CLEAR_MODULE(name, mod) \ - if (PyModule_Check(mod)) { \ - if (verbose && PyUnicode_Check(name)) { \ - PySys_FormatStderr("# cleanup[2] removing %U\n", name); \ - } \ - STORE_MODULE_WEAKREF(name, mod); \ - if (PyObject_SetItem(modules, name, Py_None) < 0) { \ - PyErr_WriteUnraisable(NULL); \ - } \ - } - - /* Remove all modules from sys.modules, hoping that garbage collection - can reclaim most of them. */ - if (PyDict_CheckExact(modules)) { - Py_ssize_t pos = 0; - PyObject *key, *value; - while (PyDict_Next(modules, &pos, &key, &value)) { - CLEAR_MODULE(key, value); - } - } - else { - PyObject *iterator = PyObject_GetIter(modules); - if (iterator == NULL) { - PyErr_WriteUnraisable(NULL); - } - else { - PyObject *key; - while ((key = PyIter_Next(iterator))) { - PyObject *value = PyObject_GetItem(modules, key); - if (value == NULL) { - PyErr_WriteUnraisable(NULL); - continue; - } - CLEAR_MODULE(key, value); - Py_DECREF(value); - Py_DECREF(key); - } - if (PyErr_Occurred()) { - PyErr_WriteUnraisable(NULL); - } - Py_DECREF(iterator); - } - } - - /* Clear the modules dict. */ - if (PyDict_CheckExact(modules)) { - PyDict_Clear(modules); - } - else { - _Py_IDENTIFIER(clear); - if (_PyObject_CallMethodIdNoArgs(modules, &PyId_clear) == NULL) { - PyErr_WriteUnraisable(NULL); - } - } - /* Restore the original builtins dict, to ensure that any - user data gets cleared. */ - PyObject *dict = PyDict_Copy(interp->builtins); - if (dict == NULL) { - PyErr_WriteUnraisable(NULL); - } - PyDict_Clear(interp->builtins); - if (PyDict_Update(interp->builtins, interp->builtins_copy)) { - _PyErr_Clear(tstate); - } - Py_XDECREF(dict); - /* Collect references */ - _PyGC_CollectNoFail(); - /* Dump GC stats before it's too late, since it uses the warnings - machinery. */ - _PyGC_DumpShutdownStats(tstate); - - /* Now, if there are any modules left alive, clear their globals to - minimize potential leaks. All C extension modules actually end - up here, since they are kept alive in the interpreter state. - - The special treatment of "builtins" here is because even - when it's not referenced as a module, its dictionary is - referenced by almost every module's __builtins__. Since - deleting a module clears its dictionary (even if there are - references left to it), we need to delete the "builtins" - module last. Likewise, we don't delete sys until the very - end because it is implicitly referenced (e.g. by print). */ - if (weaklist != NULL) { - Py_ssize_t i; - /* Since dict is ordered in CPython 3.6+, modules are saved in - importing order. First clear modules imported later. */ - for (i = PyList_GET_SIZE(weaklist) - 1; i >= 0; i--) { - PyObject *tup = PyList_GET_ITEM(weaklist, i); - PyObject *name = PyTuple_GET_ITEM(tup, 0); - PyObject *mod = PyWeakref_GET_OBJECT(PyTuple_GET_ITEM(tup, 1)); - if (mod == Py_None) - continue; - assert(PyModule_Check(mod)); - dict = PyModule_GetDict(mod); - if (dict == interp->builtins || dict == interp->sysdict) - continue; - Py_INCREF(mod); - if (verbose && PyUnicode_Check(name)) { - PySys_FormatStderr("# cleanup[3] wiping %U\n", name); - } - _PyModule_Clear(mod); - Py_DECREF(mod); - } - Py_DECREF(weaklist); - } - - /* Next, delete sys and builtins (in that order) */ - if (verbose) { - PySys_FormatStderr("# cleanup[3] wiping sys\n"); - } - _PyModule_ClearDict(interp->sysdict); - if (verbose) { - PySys_FormatStderr("# cleanup[3] wiping builtins\n"); - } - _PyModule_ClearDict(interp->builtins); - - /* Clear module dict copies stored in the interpreter state */ - _PyInterpreterState_ClearModules(interp); - - /* Clear and delete the modules directory. Actual modules will - still be there only if imported during the execution of some - destructor. */ - interp->modules = NULL; - Py_DECREF(modules); - - /* Once more */ - _PyGC_CollectNoFail(); - -#undef CLEAR_MODULE -#undef STORE_MODULE_WEAKREF -} - - /* Helper for pythonrun.c -- return magic number and tag. */ long @@ -678,7 +409,7 @@ PyImport_GetMagicTag(void) modules. A copy of the module's dictionary is stored by calling _PyImport_FixupExtensionObject() immediately after the module initialization function succeeds. A copy can be retrieved from there by calling - _PyImport_FindExtensionObject(). + import_find_extension(). Modules which do support multiple initialization set their m_size field to a non-negative number (indicating the size of the @@ -712,7 +443,7 @@ _PyImport_FixupExtensionObject(PyObject *mod, PyObject *name, // bpo-44050: Extensions and def->m_base.m_copy can be updated // when the extension module doesn't support sub-interpreters. - if (_Py_IsMainInterpreter(tstate) || def->m_size == -1) { + if (_Py_IsMainInterpreter(tstate->interp) || def->m_size == -1) { if (def->m_size == -1) { if (def->m_base.m_copy) { /* Somebody already imported the module, @@ -793,10 +524,14 @@ import_find_extension(PyThreadState *tstate, PyObject *name, if (mod == NULL) return NULL; mdict = PyModule_GetDict(mod); - if (mdict == NULL) + if (mdict == NULL) { + Py_DECREF(mod); return NULL; - if (PyDict_Update(mdict, def->m_base.m_copy)) + } + if (PyDict_Update(mdict, def->m_base.m_copy)) { + Py_DECREF(mod); return NULL; + } } else { if (def->m_base.m_init == NULL) @@ -808,10 +543,10 @@ import_find_extension(PyThreadState *tstate, PyObject *name, Py_DECREF(mod); return NULL; } - Py_DECREF(mod); } if (_PyState_AddModule(tstate, mod, def) < 0) { PyMapping_DelItem(modules, name); + Py_DECREF(mod); return NULL; } @@ -827,27 +562,23 @@ PyObject * _PyImport_FindExtensionObject(PyObject *name, PyObject *filename) { PyThreadState *tstate = _PyThreadState_GET(); - return import_find_extension(tstate, name, filename); + PyObject *mod = import_find_extension(tstate, name, filename); + if (mod) { + PyObject *ref = PyWeakref_NewRef(mod, NULL); + Py_DECREF(mod); + if (ref == NULL) { + return NULL; + } + mod = PyWeakref_GetObject(ref); + Py_DECREF(ref); + } + return mod; /* borrowed reference */ } -PyObject * -_PyImport_FindBuiltin(PyThreadState *tstate, const char *name) -{ - PyObject *res, *nameobj; - nameobj = PyUnicode_InternFromString(name); - if (nameobj == NULL) - return NULL; - res = import_find_extension(tstate, nameobj, nameobj); - Py_DECREF(nameobj); - return res; -} - /* Get the module object corresponding to a module name. First check the modules dictionary if there's one there, - if not, create a new one and insert it in the modules dictionary. - Because the former action is most common, THIS DOES NOT RETURN A - 'NEW' REFERENCE! */ + if not, create a new one and insert it in the modules dictionary. */ static PyObject * import_add_module(PyThreadState *tstate, PyObject *name) @@ -862,6 +593,7 @@ import_add_module(PyThreadState *tstate, PyObject *name) PyObject *m; if (PyDict_CheckExact(modules)) { m = PyDict_GetItemWithError(modules, name); + Py_XINCREF(m); } else { m = PyObject_GetItem(modules, name); @@ -877,6 +609,7 @@ import_add_module(PyThreadState *tstate, PyObject *name) if (m != NULL && PyModule_Check(m)) { return m; } + Py_XDECREF(m); m = PyModule_NewObject(name); if (m == NULL) return NULL; @@ -884,7 +617,6 @@ import_add_module(PyThreadState *tstate, PyObject *name) Py_DECREF(m); return NULL; } - Py_DECREF(m); /* Yes, it still exists, in modules! */ return m; } @@ -893,7 +625,17 @@ PyObject * PyImport_AddModuleObject(PyObject *name) { PyThreadState *tstate = _PyThreadState_GET(); - return import_add_module(tstate, name); + PyObject *mod = import_add_module(tstate, name); + if (mod) { + PyObject *ref = PyWeakref_NewRef(mod, NULL); + Py_DECREF(mod); + if (ref == NULL) { + return NULL; + } + mod = PyWeakref_GetObject(ref); + Py_DECREF(ref); + } + return mod; /* borrowed reference */ } @@ -1018,7 +760,7 @@ static PyObject * module_dict_for_exec(PyThreadState *tstate, PyObject *name) { _Py_IDENTIFIER(__builtins__); - PyObject *m, *d = NULL; + PyObject *m, *d; m = import_add_module(tstate, name); if (m == NULL) @@ -1026,17 +768,20 @@ module_dict_for_exec(PyThreadState *tstate, PyObject *name) /* If the module is being reloaded, we get the old module back and re-use its dict to exec the new code. */ d = PyModule_GetDict(m); - if (_PyDict_GetItemIdWithError(d, &PyId___builtins__) == NULL) { - if (_PyErr_Occurred(tstate) || - _PyDict_SetItemId(d, &PyId___builtins__, - PyEval_GetBuiltins()) != 0) - { - remove_module(tstate, name); - return NULL; - } + int r = _PyDict_ContainsId(d, &PyId___builtins__); + if (r == 0) { + r = _PyDict_SetItemId(d, &PyId___builtins__, + PyEval_GetBuiltins()); + } + if (r < 0) { + remove_module(tstate, name); + Py_DECREF(m); + return NULL; } - return d; /* Return a borrowed reference. */ + Py_INCREF(d); + Py_DECREF(m); + return d; } static PyObject * @@ -1080,8 +825,10 @@ PyImport_ExecCodeModuleObject(PyObject *name, PyObject *co, PyObject *pathname, } external = PyObject_GetAttrString(tstate->interp->importlib, "_bootstrap_external"); - if (external == NULL) + if (external == NULL) { + Py_DECREF(d); return NULL; + } res = _PyObject_CallMethodIdObjArgs(external, &PyId__fix_up_module, d, name, pathname, cpathname, NULL); @@ -1090,6 +837,7 @@ PyImport_ExecCodeModuleObject(PyObject *name, PyObject *co, PyObject *pathname, Py_DECREF(res); res = exec_code_in_module(tstate, name, d, co); } + Py_DECREF(d); return res; } @@ -1183,8 +931,7 @@ is_builtin(PyObject *name) that can handle the path item. Return None if no hook could; this tells our caller that the path based finder could not find a finder for this path item. Cache the result in - path_importer_cache. - Returns a borrowed reference. */ + path_importer_cache. */ static PyObject * get_path_importer(PyThreadState *tstate, PyObject *path_importer_cache, @@ -1202,8 +949,10 @@ get_path_importer(PyThreadState *tstate, PyObject *path_importer_cache, return NULL; /* Shouldn't happen */ importer = PyDict_GetItemWithError(path_importer_cache, p); - if (importer != NULL || _PyErr_Occurred(tstate)) + if (importer != NULL || _PyErr_Occurred(tstate)) { + Py_XINCREF(importer); return importer; + } /* set path_importer_cache[p] to None to avoid recursion */ if (PyDict_SetItem(path_importer_cache, p, Py_None) != 0) @@ -1223,13 +972,11 @@ get_path_importer(PyThreadState *tstate, PyObject *path_importer_cache, _PyErr_Clear(tstate); } if (importer == NULL) { - return Py_None; + Py_RETURN_NONE; } - if (importer != NULL) { - int err = PyDict_SetItem(path_importer_cache, p, importer); + if (PyDict_SetItem(path_importer_cache, p, importer) < 0) { Py_DECREF(importer); - if (err != 0) - return NULL; + return NULL; } return importer; } @@ -1238,96 +985,87 @@ PyObject * PyImport_GetImporter(PyObject *path) { PyThreadState *tstate = _PyThreadState_GET(); - PyObject *importer=NULL, *path_importer_cache=NULL, *path_hooks=NULL; - - path_importer_cache = PySys_GetObject("path_importer_cache"); - path_hooks = PySys_GetObject("path_hooks"); - if (path_importer_cache != NULL && path_hooks != NULL) { - importer = get_path_importer(tstate, path_importer_cache, - path_hooks, path); + PyObject *path_importer_cache = PySys_GetObject("path_importer_cache"); + PyObject *path_hooks = PySys_GetObject("path_hooks"); + if (path_importer_cache == NULL || path_hooks == NULL) { + return NULL; } - Py_XINCREF(importer); /* get_path_importer returns a borrowed reference */ - return importer; + return get_path_importer(tstate, path_importer_cache, path_hooks, path); } -/*[clinic input] -_imp.create_builtin - - spec: object - / - -Create an extension module. -[clinic start generated code]*/ - -static PyObject * -_imp_create_builtin(PyObject *module, PyObject *spec) -/*[clinic end generated code: output=ace7ff22271e6f39 input=37f966f890384e47]*/ +static PyObject* +create_builtin(PyThreadState *tstate, PyObject *name, PyObject *spec) { - PyThreadState *tstate = _PyThreadState_GET(); - struct _inittab *p; - PyObject *name; - const char *namestr; - PyObject *mod; - - name = PyObject_GetAttrString(spec, "name"); - if (name == NULL) { - return NULL; - } - - mod = _PyImport_FindExtensionObject(name, name); + PyObject *mod = import_find_extension(tstate, name, name); if (mod || _PyErr_Occurred(tstate)) { - Py_DECREF(name); - Py_XINCREF(mod); return mod; } - namestr = PyUnicode_AsUTF8(name); - if (namestr == NULL) { - Py_DECREF(name); - return NULL; - } - PyObject *modules = tstate->interp->modules; - for (p = PyImport_Inittab; p->name != NULL; p++) { - PyModuleDef *def; + for (struct _inittab *p = PyImport_Inittab; p->name != NULL; p++) { if (_PyUnicode_EqualToASCIIString(name, p->name)) { if (p->initfunc == NULL) { /* Cannot re-init internal module ("sys" or "builtins") */ - mod = PyImport_AddModule(namestr); - Py_DECREF(name); - return mod; + return PyImport_AddModuleObject(name); } + mod = (*p->initfunc)(); if (mod == NULL) { - Py_DECREF(name); return NULL; } + if (PyObject_TypeCheck(mod, &PyModuleDef_Type)) { - Py_DECREF(name); return PyModule_FromDefAndSpec((PyModuleDef*)mod, spec); - } else { + } + else { /* Remember pointer to module init function. */ - def = PyModule_GetDef(mod); + PyModuleDef *def = PyModule_GetDef(mod); if (def == NULL) { - Py_DECREF(name); return NULL; } + def->m_base.m_init = p->initfunc; if (_PyImport_FixupExtensionObject(mod, name, name, modules) < 0) { - Py_DECREF(name); return NULL; } - Py_DECREF(name); return mod; } } } - Py_DECREF(name); + + // not found Py_RETURN_NONE; } + +/*[clinic input] +_imp.create_builtin + + spec: object + / + +Create an extension module. +[clinic start generated code]*/ + +static PyObject * +_imp_create_builtin(PyObject *module, PyObject *spec) +/*[clinic end generated code: output=ace7ff22271e6f39 input=37f966f890384e47]*/ +{ + PyThreadState *tstate = _PyThreadState_GET(); + + PyObject *name = PyObject_GetAttrString(spec, "name"); + if (name == NULL) { + return NULL; + } + + PyObject *mod = create_builtin(tstate, name, spec); + Py_DECREF(name); + return mod; +} + + /* Frozen modules */ static const struct _frozen * @@ -1440,10 +1178,12 @@ PyImport_ImportFrozenModuleObject(PyObject *name) d = PyModule_GetDict(m); l = PyList_New(0); if (l == NULL) { + Py_DECREF(m); goto err_return; } err = PyDict_SetItemString(d, "__path__", l); Py_DECREF(l); + Py_DECREF(m); if (err != 0) goto err_return; } @@ -1452,6 +1192,7 @@ PyImport_ImportFrozenModuleObject(PyObject *name) goto err_return; } m = exec_code_in_module(tstate, name, d, co); + Py_DECREF(d); if (m == NULL) { goto err_return; } @@ -1670,10 +1411,14 @@ resolve_name(PyThreadState *tstate, PyObject *name, PyObject *globals, int level goto error; } - if (_PyDict_GetItemIdWithError(globals, &PyId___path__) == NULL) { + int haspath = _PyDict_ContainsId(globals, &PyId___path__); + if (haspath < 0) { + goto error; + } + if (!haspath) { Py_ssize_t dot; - if (_PyErr_Occurred(tstate) || PyUnicode_READY(package) < 0) { + if (PyUnicode_READY(package) < 0) { goto error; } @@ -1806,7 +1551,7 @@ PyImport_GetModule(PyObject *name) mod = import_get_module(tstate, name); if (mod != NULL && mod != Py_None) { - if (import_ensure_initialized(tstate, mod, name) < 0) { + if (import_ensure_initialized(tstate->interp, mod, name) < 0) { Py_DECREF(mod); remove_importlib_frames(tstate); return NULL; @@ -1870,7 +1615,7 @@ PyImport_ImportModuleLevelObject(PyObject *name, PyObject *globals, } if (mod != NULL && mod != Py_None) { - if (import_ensure_initialized(tstate, mod, abs_name) < 0) { + if (import_ensure_initialized(tstate->interp, mod, abs_name) < 0) { goto error; } } @@ -2021,26 +1766,29 @@ PyImport_ReloadModule(PyObject *m) PyObject * PyImport_Import(PyObject *module_name) { + _Py_IDENTIFIER(__import__); + _Py_IDENTIFIER(__builtins__); + PyThreadState *tstate = _PyThreadState_GET(); - static PyObject *silly_list = NULL; - static PyObject *builtins_str = NULL; - static PyObject *import_str = NULL; PyObject *globals = NULL; PyObject *import = NULL; PyObject *builtins = NULL; PyObject *r = NULL; /* Initialize constant string objects */ - if (silly_list == NULL) { - import_str = PyUnicode_InternFromString("__import__"); - if (import_str == NULL) - return NULL; - builtins_str = PyUnicode_InternFromString("__builtins__"); - if (builtins_str == NULL) - return NULL; - silly_list = PyList_New(0); - if (silly_list == NULL) - return NULL; + PyObject *import_str = _PyUnicode_FromId(&PyId___import__); // borrowed ref + if (import_str == NULL) { + return NULL; + } + + PyObject *builtins_str = _PyUnicode_FromId(&PyId___builtins__); // borrowed ref + if (builtins_str == NULL) { + return NULL; + } + + PyObject *from_list = PyList_New(0); + if (from_list == NULL) { + goto err; } /* Get the builtins from current globals */ @@ -2055,8 +1803,9 @@ PyImport_Import(PyObject *module_name) /* No globals -- use standard builtins, and fake globals */ builtins = PyImport_ImportModuleLevel("builtins", NULL, NULL, NULL, 0); - if (builtins == NULL) - return NULL; + if (builtins == NULL) { + goto err; + } globals = Py_BuildValue("{OO}", builtins_str, builtins); if (globals == NULL) goto err; @@ -2078,7 +1827,7 @@ PyImport_Import(PyObject *module_name) Always use absolute import here. Calling for side-effect of import. */ r = PyObject_CallFunction(import, "OOOOi", module_name, globals, - globals, silly_list, 0, NULL); + globals, from_list, 0, NULL); if (r == NULL) goto err; Py_DECREF(r); @@ -2092,6 +1841,7 @@ PyImport_Import(PyObject *module_name) Py_XDECREF(globals); Py_XDECREF(builtins); Py_XDECREF(import); + Py_XDECREF(from_list); return r; } @@ -2148,7 +1898,6 @@ _imp_init_frozen_impl(PyObject *module, PyObject *name) { PyThreadState *tstate = _PyThreadState_GET(); int ret; - PyObject *m; ret = PyImport_ImportFrozenModuleObject(name); if (ret < 0) @@ -2156,9 +1905,7 @@ _imp_init_frozen_impl(PyObject *module, PyObject *name) if (ret == 0) { Py_RETURN_NONE; } - m = import_add_module(tstate, name); - Py_XINCREF(m); - return m; + return import_add_module(tstate, name); } /*[clinic input] @@ -2282,11 +2029,11 @@ _imp_create_dynamic_impl(PyObject *module, PyObject *spec, PyObject *file) return NULL; } - mod = _PyImport_FindExtensionObject(name, path); + PyThreadState *tstate = _PyThreadState_GET(); + mod = import_find_extension(tstate, name, path); if (mod != NULL || PyErr_Occurred()) { Py_DECREF(name); Py_DECREF(path); - Py_XINCREF(mod); return mod; } @@ -2397,46 +2144,88 @@ static PyMethodDef imp_methods[] = { }; -static struct PyModuleDef impmodule = { +static int +imp_module_exec(PyObject *module) +{ + const wchar_t *mode = _Py_GetConfig()->check_hash_pycs_mode; + PyObject *pyc_mode = PyUnicode_FromWideChar(mode, -1); + if (pyc_mode == NULL) { + return -1; + } + if (PyModule_AddObjectRef(module, "check_hash_based_pycs", pyc_mode) < 0) { + Py_DECREF(pyc_mode); + return -1; + } + Py_DECREF(pyc_mode); + + return 0; +} + + +static PyModuleDef_Slot imp_slots[] = { + {Py_mod_exec, imp_module_exec}, + {0, NULL} +}; + +static struct PyModuleDef imp_module = { PyModuleDef_HEAD_INIT, - "_imp", - doc_imp, - 0, - imp_methods, - NULL, - NULL, - NULL, - NULL + .m_name = "_imp", + .m_doc = doc_imp, + .m_size = 0, + .m_methods = imp_methods, + .m_slots = imp_slots, }; PyMODINIT_FUNC PyInit__imp(void) { - PyObject *m, *d; + return PyModuleDef_Init(&imp_module); +} - m = PyModule_Create(&impmodule); - if (m == NULL) { - goto failure; + +// Import the _imp extension by calling manually _imp.create_builtin() and +// _imp.exec_builtin() since importlib is not initialized yet. Initializing +// importlib requires the _imp module: this function fix the bootstrap issue. +PyObject* +_PyImport_BootstrapImp(PyThreadState *tstate) +{ + PyObject *name = PyUnicode_FromString("_imp"); + if (name == NULL) { + return NULL; } - d = PyModule_GetDict(m); - if (d == NULL) { - goto failure; + + // Mock a ModuleSpec object just good enough for PyModule_FromDefAndSpec(): + // an object with just a name attribute. + // + // _imp.__spec__ is overridden by importlib._bootstrap._instal() anyway. + PyObject *attrs = Py_BuildValue("{sO}", "name", name); + if (attrs == NULL) { + goto error; + } + PyObject *spec = _PyNamespace_New(attrs); + Py_DECREF(attrs); + if (spec == NULL) { + goto error; } - const wchar_t *mode = _Py_GetConfig()->check_hash_pycs_mode; - PyObject *pyc_mode = PyUnicode_FromWideChar(mode, -1); - if (pyc_mode == NULL) { - goto failure; + // Create the _imp module from its definition. + PyObject *mod = create_builtin(tstate, name, spec); + Py_CLEAR(name); + Py_DECREF(spec); + if (mod == NULL) { + goto error; } - if (PyDict_SetItemString(d, "check_hash_based_pycs", pyc_mode) < 0) { - Py_DECREF(pyc_mode); - goto failure; + assert(mod != Py_None); // not found + + // Execute the _imp module: call imp_module_exec(). + if (exec_builtin_or_dynamic(mod) < 0) { + Py_DECREF(mod); + goto error; } - Py_DECREF(pyc_mode); + return mod; - return m; - failure: - Py_XDECREF(m); +error: + Py_XDECREF(name); return NULL; } diff --git a/contrib/tools/python3/src/Python/importdl.c b/contrib/tools/python3/src/Python/importdl.c index 134f6680c44..6d2554741f9 100644 --- a/contrib/tools/python3/src/Python/importdl.c +++ b/contrib/tools/python3/src/Python/importdl.c @@ -223,10 +223,9 @@ _PyImport_LoadDynamicModuleWithSpec(PyObject *spec, FILE *fp) def->m_base.m_init = p0; /* Remember the filename as the __file__ attribute */ - if (PyModule_AddObject(m, "__file__", path) < 0) + if (PyModule_AddObjectRef(m, "__file__", path) < 0) { PyErr_Clear(); /* Not important enough to report */ - else - Py_INCREF(path); + } PyObject *modules = PyImport_GetModuleDict(); if (_PyImport_FixupExtensionObject(m, name_unicode, path, modules) < 0) diff --git a/contrib/tools/python3/src/Python/importlib.h b/contrib/tools/python3/src/Python/importlib.h index 1fb877a7534..dd1a9f172c0 100644 --- a/contrib/tools/python3/src/Python/importlib.h +++ b/contrib/tools/python3/src/Python/importlib.h @@ -1,537 +1,561 @@ /* Auto-generated by Programs/_freeze_importlib.c */ const unsigned char _Py_M__importlib_bootstrap[] = { 99,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,4,0,0,0,64,0,0,0,115,194,1,0,0,100,0, - 90,0,100,1,97,1,100,2,100,3,132,0,90,2,100,4, - 100,5,132,0,90,3,105,0,90,4,105,0,90,5,71,0, - 100,6,100,7,132,0,100,7,101,6,131,3,90,7,71,0, - 100,8,100,9,132,0,100,9,131,2,90,8,71,0,100,10, - 100,11,132,0,100,11,131,2,90,9,71,0,100,12,100,13, - 132,0,100,13,131,2,90,10,100,14,100,15,132,0,90,11, - 100,16,100,17,132,0,90,12,100,18,100,19,132,0,90,13, - 100,20,100,21,156,1,100,22,100,23,132,2,90,14,100,24, - 100,25,132,0,90,15,100,26,100,27,132,0,90,16,100,28, - 100,29,132,0,90,17,100,30,100,31,132,0,90,18,71,0, - 100,32,100,33,132,0,100,33,131,2,90,19,100,1,100,1, - 100,34,156,2,100,35,100,36,132,2,90,20,100,94,100,37, - 100,38,132,1,90,21,100,39,100,40,156,1,100,41,100,42, - 132,2,90,22,100,43,100,44,132,0,90,23,100,45,100,46, - 132,0,90,24,100,47,100,48,132,0,90,25,100,49,100,50, - 132,0,90,26,100,51,100,52,132,0,90,27,100,53,100,54, - 132,0,90,28,71,0,100,55,100,56,132,0,100,56,131,2, - 90,29,71,0,100,57,100,58,132,0,100,58,131,2,90,30, - 71,0,100,59,100,60,132,0,100,60,131,2,90,31,100,61, - 100,62,132,0,90,32,100,63,100,64,132,0,90,33,100,95, - 100,65,100,66,132,1,90,34,100,67,100,68,132,0,90,35, - 100,69,90,36,101,36,100,70,23,0,90,37,100,71,100,72, - 132,0,90,38,101,39,131,0,90,40,100,73,100,74,132,0, - 90,41,100,96,100,76,100,77,132,1,90,42,100,39,100,78, - 156,1,100,79,100,80,132,2,90,43,100,81,100,82,132,0, - 90,44,100,97,100,84,100,85,132,1,90,45,100,86,100,87, - 132,0,90,46,100,88,100,89,132,0,90,47,100,90,100,91, - 132,0,90,48,100,92,100,93,132,0,90,49,100,1,83,0, - 41,98,97,83,1,0,0,67,111,114,101,32,105,109,112,108, - 101,109,101,110,116,97,116,105,111,110,32,111,102,32,105,109, - 112,111,114,116,46,10,10,84,104,105,115,32,109,111,100,117, - 108,101,32,105,115,32,78,79,84,32,109,101,97,110,116,32, - 116,111,32,98,101,32,100,105,114,101,99,116,108,121,32,105, - 109,112,111,114,116,101,100,33,32,73,116,32,104,97,115,32, - 98,101,101,110,32,100,101,115,105,103,110,101,100,32,115,117, - 99,104,10,116,104,97,116,32,105,116,32,99,97,110,32,98, - 101,32,98,111,111,116,115,116,114,97,112,112,101,100,32,105, - 110,116,111,32,80,121,116,104,111,110,32,97,115,32,116,104, - 101,32,105,109,112,108,101,109,101,110,116,97,116,105,111,110, - 32,111,102,32,105,109,112,111,114,116,46,32,65,115,10,115, - 117,99,104,32,105,116,32,114,101,113,117,105,114,101,115,32, - 116,104,101,32,105,110,106,101,99,116,105,111,110,32,111,102, - 32,115,112,101,99,105,102,105,99,32,109,111,100,117,108,101, - 115,32,97,110,100,32,97,116,116,114,105,98,117,116,101,115, - 32,105,110,32,111,114,100,101,114,32,116,111,10,119,111,114, - 107,46,32,79,110,101,32,115,104,111,117,108,100,32,117,115, - 101,32,105,109,112,111,114,116,108,105,98,32,97,115,32,116, - 104,101,32,112,117,98,108,105,99,45,102,97,99,105,110,103, - 32,118,101,114,115,105,111,110,32,111,102,32,116,104,105,115, - 32,109,111,100,117,108,101,46,10,10,78,99,2,0,0,0, - 0,0,0,0,0,0,0,0,3,0,0,0,7,0,0,0, - 67,0,0,0,115,56,0,0,0,100,1,68,0,93,32,125, - 2,116,0,124,1,124,2,131,2,114,4,116,1,124,0,124, - 2,116,2,124,1,124,2,131,2,131,3,1,0,113,4,124, - 0,106,3,160,4,124,1,106,3,161,1,1,0,100,2,83, - 0,41,3,122,47,83,105,109,112,108,101,32,115,117,98,115, - 116,105,116,117,116,101,32,102,111,114,32,102,117,110,99,116, - 111,111,108,115,46,117,112,100,97,116,101,95,119,114,97,112, - 112,101,114,46,41,4,218,10,95,95,109,111,100,117,108,101, - 95,95,218,8,95,95,110,97,109,101,95,95,218,12,95,95, - 113,117,97,108,110,97,109,101,95,95,218,7,95,95,100,111, - 99,95,95,78,41,5,218,7,104,97,115,97,116,116,114,218, - 7,115,101,116,97,116,116,114,218,7,103,101,116,97,116,116, - 114,218,8,95,95,100,105,99,116,95,95,218,6,117,112,100, - 97,116,101,41,3,90,3,110,101,119,90,3,111,108,100,218, - 7,114,101,112,108,97,99,101,169,0,114,10,0,0,0,250, - 29,60,102,114,111,122,101,110,32,105,109,112,111,114,116,108, - 105,98,46,95,98,111,111,116,115,116,114,97,112,62,218,5, - 95,119,114,97,112,27,0,0,0,115,8,0,0,0,0,2, - 8,1,10,1,20,1,114,12,0,0,0,99,1,0,0,0, - 0,0,0,0,0,0,0,0,1,0,0,0,2,0,0,0, - 67,0,0,0,115,12,0,0,0,116,0,116,1,131,1,124, - 0,131,1,83,0,169,1,78,41,2,218,4,116,121,112,101, - 218,3,115,121,115,169,1,218,4,110,97,109,101,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,218,11,95,110, - 101,119,95,109,111,100,117,108,101,35,0,0,0,115,2,0, - 0,0,0,1,114,18,0,0,0,99,0,0,0,0,0,0, - 0,0,0,0,0,0,0,0,0,0,1,0,0,0,64,0, - 0,0,115,12,0,0,0,101,0,90,1,100,0,90,2,100, - 1,83,0,41,2,218,14,95,68,101,97,100,108,111,99,107, - 69,114,114,111,114,78,41,3,114,1,0,0,0,114,0,0, - 0,0,114,2,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,114,19,0,0,0, - 48,0,0,0,115,2,0,0,0,8,1,114,19,0,0,0, + 0,4,0,0,0,64,0,0,0,115,214,1,0,0,100,0, + 90,0,100,1,100,2,132,0,90,1,100,3,90,2,100,3, + 90,3,100,3,90,4,100,3,97,5,100,4,100,5,132,0, + 90,6,100,6,100,7,132,0,90,7,105,0,90,8,105,0, + 90,9,71,0,100,8,100,9,132,0,100,9,101,10,131,3, + 90,11,71,0,100,10,100,11,132,0,100,11,131,2,90,12, + 71,0,100,12,100,13,132,0,100,13,131,2,90,13,71,0, + 100,14,100,15,132,0,100,15,131,2,90,14,100,16,100,17, + 132,0,90,15,100,18,100,19,132,0,90,16,100,20,100,21, + 132,0,90,17,100,22,100,23,156,1,100,24,100,25,132,2, + 90,18,100,26,100,27,132,0,90,19,100,28,100,29,132,0, + 90,20,100,30,100,31,132,0,90,21,100,32,100,33,132,0, + 90,22,71,0,100,34,100,35,132,0,100,35,131,2,90,23, + 100,3,100,3,100,36,156,2,100,37,100,38,132,2,90,24, + 100,96,100,39,100,40,132,1,90,25,100,41,100,42,156,1, + 100,43,100,44,132,2,90,26,100,45,100,46,132,0,90,27, + 100,47,100,48,132,0,90,28,100,49,100,50,132,0,90,29, + 100,51,100,52,132,0,90,30,100,53,100,54,132,0,90,31, + 100,55,100,56,132,0,90,32,71,0,100,57,100,58,132,0, + 100,58,131,2,90,33,71,0,100,59,100,60,132,0,100,60, + 131,2,90,34,71,0,100,61,100,62,132,0,100,62,131,2, + 90,35,100,63,100,64,132,0,90,36,100,65,100,66,132,0, + 90,37,100,97,100,67,100,68,132,1,90,38,100,69,100,70, + 132,0,90,39,100,71,90,40,101,40,100,72,23,0,90,41, + 100,73,100,74,132,0,90,42,101,43,131,0,90,44,100,75, + 100,76,132,0,90,45,100,98,100,78,100,79,132,1,90,46, + 100,41,100,80,156,1,100,81,100,82,132,2,90,47,100,83, + 100,84,132,0,90,48,100,99,100,86,100,87,132,1,90,49, + 100,88,100,89,132,0,90,50,100,90,100,91,132,0,90,51, + 100,92,100,93,132,0,90,52,100,94,100,95,132,0,90,53, + 100,3,83,0,41,100,97,83,1,0,0,67,111,114,101,32, + 105,109,112,108,101,109,101,110,116,97,116,105,111,110,32,111, + 102,32,105,109,112,111,114,116,46,10,10,84,104,105,115,32, + 109,111,100,117,108,101,32,105,115,32,78,79,84,32,109,101, + 97,110,116,32,116,111,32,98,101,32,100,105,114,101,99,116, + 108,121,32,105,109,112,111,114,116,101,100,33,32,73,116,32, + 104,97,115,32,98,101,101,110,32,100,101,115,105,103,110,101, + 100,32,115,117,99,104,10,116,104,97,116,32,105,116,32,99, + 97,110,32,98,101,32,98,111,111,116,115,116,114,97,112,112, + 101,100,32,105,110,116,111,32,80,121,116,104,111,110,32,97, + 115,32,116,104,101,32,105,109,112,108,101,109,101,110,116,97, + 116,105,111,110,32,111,102,32,105,109,112,111,114,116,46,32, + 65,115,10,115,117,99,104,32,105,116,32,114,101,113,117,105, + 114,101,115,32,116,104,101,32,105,110,106,101,99,116,105,111, + 110,32,111,102,32,115,112,101,99,105,102,105,99,32,109,111, + 100,117,108,101,115,32,97,110,100,32,97,116,116,114,105,98, + 117,116,101,115,32,105,110,32,111,114,100,101,114,32,116,111, + 10,119,111,114,107,46,32,79,110,101,32,115,104,111,117,108, + 100,32,117,115,101,32,105,109,112,111,114,116,108,105,98,32, + 97,115,32,116,104,101,32,112,117,98,108,105,99,45,102,97, + 99,105,110,103,32,118,101,114,115,105,111,110,32,111,102,32, + 116,104,105,115,32,109,111,100,117,108,101,46,10,10,99,1, + 0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,8, + 0,0,0,67,0,0,0,115,38,0,0,0,122,4,124,0, + 106,0,87,0,83,0,4,0,116,1,121,18,1,0,1,0, + 1,0,116,2,124,0,131,1,106,0,6,0,89,0,83,0, + 119,0,169,1,78,41,3,218,12,95,95,113,117,97,108,110, + 97,109,101,95,95,218,14,65,116,116,114,105,98,117,116,101, + 69,114,114,111,114,218,4,116,121,112,101,41,1,218,3,111, + 98,106,169,0,114,5,0,0,0,250,29,60,102,114,111,122, + 101,110,32,105,109,112,111,114,116,108,105,98,46,95,98,111, + 111,116,115,116,114,97,112,62,218,12,95,111,98,106,101,99, + 116,95,110,97,109,101,23,0,0,0,115,10,0,0,0,2, + 1,8,1,12,1,14,1,2,255,114,7,0,0,0,78,99, + 2,0,0,0,0,0,0,0,0,0,0,0,3,0,0,0, + 7,0,0,0,67,0,0,0,115,56,0,0,0,100,1,68, + 0,93,16,125,2,116,0,124,1,124,2,131,2,114,18,116, + 1,124,0,124,2,116,2,124,1,124,2,131,2,131,3,1, + 0,113,2,124,0,106,3,160,4,124,1,106,3,161,1,1, + 0,100,2,83,0,41,3,122,47,83,105,109,112,108,101,32, + 115,117,98,115,116,105,116,117,116,101,32,102,111,114,32,102, + 117,110,99,116,111,111,108,115,46,117,112,100,97,116,101,95, + 119,114,97,112,112,101,114,46,41,4,218,10,95,95,109,111, + 100,117,108,101,95,95,218,8,95,95,110,97,109,101,95,95, + 114,1,0,0,0,218,7,95,95,100,111,99,95,95,78,41, + 5,218,7,104,97,115,97,116,116,114,218,7,115,101,116,97, + 116,116,114,218,7,103,101,116,97,116,116,114,218,8,95,95, + 100,105,99,116,95,95,218,6,117,112,100,97,116,101,41,3, + 90,3,110,101,119,90,3,111,108,100,218,7,114,101,112,108, + 97,99,101,114,5,0,0,0,114,5,0,0,0,114,6,0, + 0,0,218,5,95,119,114,97,112,40,0,0,0,115,10,0, + 0,0,8,2,10,1,18,1,2,128,18,1,114,17,0,0, + 0,99,1,0,0,0,0,0,0,0,0,0,0,0,1,0, + 0,0,2,0,0,0,67,0,0,0,115,12,0,0,0,116, + 0,116,1,131,1,124,0,131,1,83,0,114,0,0,0,0, + 41,2,114,3,0,0,0,218,3,115,121,115,169,1,218,4, + 110,97,109,101,114,5,0,0,0,114,5,0,0,0,114,6, + 0,0,0,218,11,95,110,101,119,95,109,111,100,117,108,101, + 48,0,0,0,115,2,0,0,0,12,1,114,21,0,0,0, 99,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,2,0,0,0,64,0,0,0,115,56,0,0,0,101,0, - 90,1,100,0,90,2,100,1,90,3,100,2,100,3,132,0, - 90,4,100,4,100,5,132,0,90,5,100,6,100,7,132,0, - 90,6,100,8,100,9,132,0,90,7,100,10,100,11,132,0, - 90,8,100,12,83,0,41,13,218,11,95,77,111,100,117,108, - 101,76,111,99,107,122,169,65,32,114,101,99,117,114,115,105, - 118,101,32,108,111,99,107,32,105,109,112,108,101,109,101,110, - 116,97,116,105,111,110,32,119,104,105,99,104,32,105,115,32, - 97,98,108,101,32,116,111,32,100,101,116,101,99,116,32,100, - 101,97,100,108,111,99,107,115,10,32,32,32,32,40,101,46, - 103,46,32,116,104,114,101,97,100,32,49,32,116,114,121,105, - 110,103,32,116,111,32,116,97,107,101,32,108,111,99,107,115, - 32,65,32,116,104,101,110,32,66,44,32,97,110,100,32,116, - 104,114,101,97,100,32,50,32,116,114,121,105,110,103,32,116, - 111,10,32,32,32,32,116,97,107,101,32,108,111,99,107,115, - 32,66,32,116,104,101,110,32,65,41,46,10,32,32,32,32, - 99,2,0,0,0,0,0,0,0,0,0,0,0,2,0,0, - 0,2,0,0,0,67,0,0,0,115,48,0,0,0,116,0, - 160,1,161,0,124,0,95,2,116,0,160,1,161,0,124,0, - 95,3,124,1,124,0,95,4,100,0,124,0,95,5,100,1, - 124,0,95,6,100,1,124,0,95,7,100,0,83,0,169,2, - 78,233,0,0,0,0,41,8,218,7,95,116,104,114,101,97, - 100,90,13,97,108,108,111,99,97,116,101,95,108,111,99,107, - 218,4,108,111,99,107,218,6,119,97,107,101,117,112,114,17, - 0,0,0,218,5,111,119,110,101,114,218,5,99,111,117,110, - 116,218,7,119,97,105,116,101,114,115,169,2,218,4,115,101, - 108,102,114,17,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,218,8,95,95,105,110,105,116,95,95, - 58,0,0,0,115,12,0,0,0,0,1,10,1,10,1,6, - 1,6,1,6,1,122,20,95,77,111,100,117,108,101,76,111, - 99,107,46,95,95,105,110,105,116,95,95,99,1,0,0,0, - 0,0,0,0,0,0,0,0,5,0,0,0,3,0,0,0, - 67,0,0,0,115,88,0,0,0,116,0,160,1,161,0,125, - 1,124,0,106,2,125,2,116,3,131,0,125,3,116,4,160, - 5,124,2,161,1,125,4,124,4,100,0,117,0,114,42,100, - 1,83,0,124,4,106,2,125,2,124,2,124,1,107,2,114, - 60,100,2,83,0,124,2,124,3,118,0,114,72,100,1,83, - 0,124,3,160,6,124,2,161,1,1,0,113,20,100,0,83, - 0,41,3,78,70,84,41,7,114,23,0,0,0,218,9,103, - 101,116,95,105,100,101,110,116,114,26,0,0,0,218,3,115, - 101,116,218,12,95,98,108,111,99,107,105,110,103,95,111,110, - 218,3,103,101,116,218,3,97,100,100,41,5,114,30,0,0, - 0,90,2,109,101,218,3,116,105,100,90,4,115,101,101,110, - 114,24,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,12,104,97,115,95,100,101,97,100,108,111, - 99,107,66,0,0,0,115,24,0,0,0,0,2,8,1,6, - 1,6,2,10,1,8,1,4,1,6,1,8,1,4,1,8, - 6,4,1,122,24,95,77,111,100,117,108,101,76,111,99,107, - 46,104,97,115,95,100,101,97,100,108,111,99,107,99,1,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,8,0, - 0,0,67,0,0,0,115,210,0,0,0,116,0,160,1,161, - 0,125,1,124,0,116,2,124,1,60,0,122,180,124,0,106, - 3,143,126,1,0,124,0,106,4,100,1,107,2,115,46,124, - 0,106,5,124,1,107,2,114,90,124,1,124,0,95,5,124, - 0,4,0,106,4,100,2,55,0,2,0,95,4,87,0,100, - 3,4,0,4,0,131,3,1,0,87,0,116,2,124,1,61, - 0,100,4,83,0,124,0,160,6,161,0,114,110,116,7,100, - 5,124,0,22,0,131,1,130,1,124,0,106,8,160,9,100, - 6,161,1,114,136,124,0,4,0,106,10,100,2,55,0,2, - 0,95,10,87,0,100,3,4,0,4,0,131,3,1,0,110, - 16,49,0,115,156,48,0,1,0,1,0,1,0,89,0,1, - 0,124,0,106,8,160,9,161,0,1,0,124,0,106,8,160, - 11,161,0,1,0,113,18,87,0,116,2,124,1,61,0,110, - 8,116,2,124,1,61,0,48,0,100,3,83,0,41,7,122, - 185,10,32,32,32,32,32,32,32,32,65,99,113,117,105,114, - 101,32,116,104,101,32,109,111,100,117,108,101,32,108,111,99, - 107,46,32,32,73,102,32,97,32,112,111,116,101,110,116,105, - 97,108,32,100,101,97,100,108,111,99,107,32,105,115,32,100, - 101,116,101,99,116,101,100,44,10,32,32,32,32,32,32,32, - 32,97,32,95,68,101,97,100,108,111,99,107,69,114,114,111, - 114,32,105,115,32,114,97,105,115,101,100,46,10,32,32,32, - 32,32,32,32,32,79,116,104,101,114,119,105,115,101,44,32, - 116,104,101,32,108,111,99,107,32,105,115,32,97,108,119,97, - 121,115,32,97,99,113,117,105,114,101,100,32,97,110,100,32, - 84,114,117,101,32,105,115,32,114,101,116,117,114,110,101,100, - 46,10,32,32,32,32,32,32,32,32,114,22,0,0,0,233, - 1,0,0,0,78,84,122,23,100,101,97,100,108,111,99,107, - 32,100,101,116,101,99,116,101,100,32,98,121,32,37,114,70, - 41,12,114,23,0,0,0,114,32,0,0,0,114,34,0,0, - 0,114,24,0,0,0,114,27,0,0,0,114,26,0,0,0, - 114,38,0,0,0,114,19,0,0,0,114,25,0,0,0,218, - 7,97,99,113,117,105,114,101,114,28,0,0,0,218,7,114, - 101,108,101,97,115,101,169,2,114,30,0,0,0,114,37,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,114,40,0,0,0,87,0,0,0,115,34,0,0,0,0, - 6,8,1,8,1,2,2,8,1,20,1,6,1,14,1,14, - 9,6,247,4,1,8,1,12,1,12,1,44,2,10,1,14, - 2,122,19,95,77,111,100,117,108,101,76,111,99,107,46,97, - 99,113,117,105,114,101,99,1,0,0,0,0,0,0,0,0, - 0,0,0,2,0,0,0,8,0,0,0,67,0,0,0,115, - 142,0,0,0,116,0,160,1,161,0,125,1,124,0,106,2, - 143,108,1,0,124,0,106,3,124,1,107,3,114,34,116,4, - 100,1,131,1,130,1,124,0,106,5,100,2,107,4,115,48, - 74,0,130,1,124,0,4,0,106,5,100,3,56,0,2,0, - 95,5,124,0,106,5,100,2,107,2,114,108,100,0,124,0, - 95,3,124,0,106,6,114,108,124,0,4,0,106,6,100,3, - 56,0,2,0,95,6,124,0,106,7,160,8,161,0,1,0, - 87,0,100,0,4,0,4,0,131,3,1,0,110,16,49,0, - 115,128,48,0,1,0,1,0,1,0,89,0,1,0,100,0, - 83,0,41,4,78,250,31,99,97,110,110,111,116,32,114,101, - 108,101,97,115,101,32,117,110,45,97,99,113,117,105,114,101, - 100,32,108,111,99,107,114,22,0,0,0,114,39,0,0,0, - 41,9,114,23,0,0,0,114,32,0,0,0,114,24,0,0, - 0,114,26,0,0,0,218,12,82,117,110,116,105,109,101,69, - 114,114,111,114,114,27,0,0,0,114,28,0,0,0,114,25, - 0,0,0,114,41,0,0,0,114,42,0,0,0,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,114,41,0,0, - 0,112,0,0,0,115,22,0,0,0,0,1,8,1,8,1, - 10,1,8,1,14,1,14,1,10,1,6,1,6,1,14,1, - 122,19,95,77,111,100,117,108,101,76,111,99,107,46,114,101, - 108,101,97,115,101,99,1,0,0,0,0,0,0,0,0,0, - 0,0,1,0,0,0,5,0,0,0,67,0,0,0,115,18, - 0,0,0,100,1,160,0,124,0,106,1,116,2,124,0,131, - 1,161,2,83,0,41,2,78,122,23,95,77,111,100,117,108, - 101,76,111,99,107,40,123,33,114,125,41,32,97,116,32,123, - 125,169,3,218,6,102,111,114,109,97,116,114,17,0,0,0, - 218,2,105,100,169,1,114,30,0,0,0,114,10,0,0,0, - 114,10,0,0,0,114,11,0,0,0,218,8,95,95,114,101, - 112,114,95,95,125,0,0,0,115,2,0,0,0,0,1,122, - 20,95,77,111,100,117,108,101,76,111,99,107,46,95,95,114, - 101,112,114,95,95,78,41,9,114,1,0,0,0,114,0,0, - 0,0,114,2,0,0,0,114,3,0,0,0,114,31,0,0, - 0,114,38,0,0,0,114,40,0,0,0,114,41,0,0,0, - 114,49,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,114,20,0,0,0,52,0, - 0,0,115,12,0,0,0,8,1,4,5,8,8,8,21,8, - 25,8,13,114,20,0,0,0,99,0,0,0,0,0,0,0, - 0,0,0,0,0,0,0,0,0,2,0,0,0,64,0,0, - 0,115,48,0,0,0,101,0,90,1,100,0,90,2,100,1, - 90,3,100,2,100,3,132,0,90,4,100,4,100,5,132,0, - 90,5,100,6,100,7,132,0,90,6,100,8,100,9,132,0, - 90,7,100,10,83,0,41,11,218,16,95,68,117,109,109,121, - 77,111,100,117,108,101,76,111,99,107,122,86,65,32,115,105, - 109,112,108,101,32,95,77,111,100,117,108,101,76,111,99,107, - 32,101,113,117,105,118,97,108,101,110,116,32,102,111,114,32, - 80,121,116,104,111,110,32,98,117,105,108,100,115,32,119,105, - 116,104,111,117,116,10,32,32,32,32,109,117,108,116,105,45, - 116,104,114,101,97,100,105,110,103,32,115,117,112,112,111,114, - 116,46,99,2,0,0,0,0,0,0,0,0,0,0,0,2, - 0,0,0,2,0,0,0,67,0,0,0,115,16,0,0,0, - 124,1,124,0,95,0,100,1,124,0,95,1,100,0,83,0, - 114,21,0,0,0,41,2,114,17,0,0,0,114,27,0,0, - 0,114,29,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,31,0,0,0,133,0,0,0,115,4, - 0,0,0,0,1,6,1,122,25,95,68,117,109,109,121,77, - 111,100,117,108,101,76,111,99,107,46,95,95,105,110,105,116, - 95,95,99,1,0,0,0,0,0,0,0,0,0,0,0,1, - 0,0,0,3,0,0,0,67,0,0,0,115,18,0,0,0, - 124,0,4,0,106,0,100,1,55,0,2,0,95,0,100,2, - 83,0,41,3,78,114,39,0,0,0,84,41,1,114,27,0, - 0,0,114,48,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,114,40,0,0,0,137,0,0,0,115, - 4,0,0,0,0,1,14,1,122,24,95,68,117,109,109,121, - 77,111,100,117,108,101,76,111,99,107,46,97,99,113,117,105, - 114,101,99,1,0,0,0,0,0,0,0,0,0,0,0,1, - 0,0,0,3,0,0,0,67,0,0,0,115,36,0,0,0, - 124,0,106,0,100,1,107,2,114,18,116,1,100,2,131,1, - 130,1,124,0,4,0,106,0,100,3,56,0,2,0,95,0, - 100,0,83,0,41,4,78,114,22,0,0,0,114,43,0,0, - 0,114,39,0,0,0,41,2,114,27,0,0,0,114,44,0, - 0,0,114,48,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,114,41,0,0,0,141,0,0,0,115, - 6,0,0,0,0,1,10,1,8,1,122,24,95,68,117,109, - 109,121,77,111,100,117,108,101,76,111,99,107,46,114,101,108, - 101,97,115,101,99,1,0,0,0,0,0,0,0,0,0,0, - 0,1,0,0,0,5,0,0,0,67,0,0,0,115,18,0, - 0,0,100,1,160,0,124,0,106,1,116,2,124,0,131,1, - 161,2,83,0,41,2,78,122,28,95,68,117,109,109,121,77, - 111,100,117,108,101,76,111,99,107,40,123,33,114,125,41,32, - 97,116,32,123,125,114,45,0,0,0,114,48,0,0,0,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,114,49, - 0,0,0,146,0,0,0,115,2,0,0,0,0,1,122,25, + 0,1,0,0,0,64,0,0,0,115,12,0,0,0,101,0, + 90,1,100,0,90,2,100,1,83,0,41,2,218,14,95,68, + 101,97,100,108,111,99,107,69,114,114,111,114,78,41,3,114, + 9,0,0,0,114,8,0,0,0,114,1,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,5,0,0,0,114,6,0, + 0,0,114,22,0,0,0,61,0,0,0,115,4,0,0,0, + 8,0,4,1,114,22,0,0,0,99,0,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0,2,0,0,0,64,0, + 0,0,115,56,0,0,0,101,0,90,1,100,0,90,2,100, + 1,90,3,100,2,100,3,132,0,90,4,100,4,100,5,132, + 0,90,5,100,6,100,7,132,0,90,6,100,8,100,9,132, + 0,90,7,100,10,100,11,132,0,90,8,100,12,83,0,41, + 13,218,11,95,77,111,100,117,108,101,76,111,99,107,122,169, + 65,32,114,101,99,117,114,115,105,118,101,32,108,111,99,107, + 32,105,109,112,108,101,109,101,110,116,97,116,105,111,110,32, + 119,104,105,99,104,32,105,115,32,97,98,108,101,32,116,111, + 32,100,101,116,101,99,116,32,100,101,97,100,108,111,99,107, + 115,10,32,32,32,32,40,101,46,103,46,32,116,104,114,101, + 97,100,32,49,32,116,114,121,105,110,103,32,116,111,32,116, + 97,107,101,32,108,111,99,107,115,32,65,32,116,104,101,110, + 32,66,44,32,97,110,100,32,116,104,114,101,97,100,32,50, + 32,116,114,121,105,110,103,32,116,111,10,32,32,32,32,116, + 97,107,101,32,108,111,99,107,115,32,66,32,116,104,101,110, + 32,65,41,46,10,32,32,32,32,99,2,0,0,0,0,0, + 0,0,0,0,0,0,2,0,0,0,2,0,0,0,67,0, + 0,0,115,48,0,0,0,116,0,160,1,161,0,124,0,95, + 2,116,0,160,1,161,0,124,0,95,3,124,1,124,0,95, + 4,100,0,124,0,95,5,100,1,124,0,95,6,100,1,124, + 0,95,7,100,0,83,0,169,2,78,233,0,0,0,0,41, + 8,218,7,95,116,104,114,101,97,100,90,13,97,108,108,111, + 99,97,116,101,95,108,111,99,107,218,4,108,111,99,107,218, + 6,119,97,107,101,117,112,114,20,0,0,0,218,5,111,119, + 110,101,114,218,5,99,111,117,110,116,218,7,119,97,105,116, + 101,114,115,169,2,218,4,115,101,108,102,114,20,0,0,0, + 114,5,0,0,0,114,5,0,0,0,114,6,0,0,0,218, + 8,95,95,105,110,105,116,95,95,71,0,0,0,115,12,0, + 0,0,10,1,10,1,6,1,6,1,6,1,10,1,122,20, + 95,77,111,100,117,108,101,76,111,99,107,46,95,95,105,110, + 105,116,95,95,99,1,0,0,0,0,0,0,0,0,0,0, + 0,5,0,0,0,3,0,0,0,67,0,0,0,115,86,0, + 0,0,116,0,160,1,161,0,125,1,124,0,106,2,125,2, + 116,3,131,0,125,3,9,0,116,4,160,5,124,2,161,1, + 125,4,124,4,100,0,117,0,114,22,100,2,83,0,124,4, + 106,2,125,2,124,2,124,1,107,2,114,31,100,1,83,0, + 124,2,124,3,118,0,114,37,100,2,83,0,124,3,160,6, + 124,2,161,1,1,0,113,11,41,3,78,84,70,41,7,114, + 26,0,0,0,218,9,103,101,116,95,105,100,101,110,116,114, + 29,0,0,0,218,3,115,101,116,218,12,95,98,108,111,99, + 107,105,110,103,95,111,110,218,3,103,101,116,218,3,97,100, + 100,41,5,114,33,0,0,0,90,2,109,101,218,3,116,105, + 100,90,4,115,101,101,110,114,27,0,0,0,114,5,0,0, + 0,114,5,0,0,0,114,6,0,0,0,218,12,104,97,115, + 95,100,101,97,100,108,111,99,107,79,0,0,0,115,28,0, + 0,0,8,2,6,1,6,1,2,1,10,1,8,1,4,1, + 6,1,8,1,4,1,8,1,4,6,10,1,2,242,122,24, + 95,77,111,100,117,108,101,76,111,99,107,46,104,97,115,95, + 100,101,97,100,108,111,99,107,99,1,0,0,0,0,0,0, + 0,0,0,0,0,2,0,0,0,8,0,0,0,67,0,0, + 0,115,200,0,0,0,116,0,160,1,161,0,125,1,124,0, + 116,2,124,1,60,0,122,87,9,0,124,0,106,3,143,64, + 1,0,124,0,106,4,100,2,107,2,115,24,124,0,106,5, + 124,1,107,2,114,47,124,1,124,0,95,5,124,0,4,0, + 106,4,100,3,55,0,2,0,95,4,9,0,87,0,100,4, + 4,0,4,0,131,3,1,0,87,0,116,2,124,1,61,0, + 100,1,83,0,124,0,160,6,161,0,114,57,116,7,100,5, + 124,0,22,0,131,1,130,1,124,0,106,8,160,9,100,6, + 161,1,114,70,124,0,4,0,106,10,100,3,55,0,2,0, + 95,10,87,0,100,4,4,0,4,0,131,3,1,0,110,8, + 49,0,115,80,119,1,1,0,1,0,1,0,89,0,1,0, + 124,0,106,8,160,9,161,0,1,0,124,0,106,8,160,11, + 161,0,1,0,113,10,116,2,124,1,61,0,119,0,41,7, + 122,185,10,32,32,32,32,32,32,32,32,65,99,113,117,105, + 114,101,32,116,104,101,32,109,111,100,117,108,101,32,108,111, + 99,107,46,32,32,73,102,32,97,32,112,111,116,101,110,116, + 105,97,108,32,100,101,97,100,108,111,99,107,32,105,115,32, + 100,101,116,101,99,116,101,100,44,10,32,32,32,32,32,32, + 32,32,97,32,95,68,101,97,100,108,111,99,107,69,114,114, + 111,114,32,105,115,32,114,97,105,115,101,100,46,10,32,32, + 32,32,32,32,32,32,79,116,104,101,114,119,105,115,101,44, + 32,116,104,101,32,108,111,99,107,32,105,115,32,97,108,119, + 97,121,115,32,97,99,113,117,105,114,101,100,32,97,110,100, + 32,84,114,117,101,32,105,115,32,114,101,116,117,114,110,101, + 100,46,10,32,32,32,32,32,32,32,32,84,114,25,0,0, + 0,233,1,0,0,0,78,122,23,100,101,97,100,108,111,99, + 107,32,100,101,116,101,99,116,101,100,32,98,121,32,37,114, + 70,41,12,114,26,0,0,0,114,35,0,0,0,114,37,0, + 0,0,114,27,0,0,0,114,30,0,0,0,114,29,0,0, + 0,114,41,0,0,0,114,22,0,0,0,114,28,0,0,0, + 218,7,97,99,113,117,105,114,101,114,31,0,0,0,218,7, + 114,101,108,101,97,115,101,169,2,114,33,0,0,0,114,40, + 0,0,0,114,5,0,0,0,114,5,0,0,0,114,6,0, + 0,0,114,43,0,0,0,100,0,0,0,115,42,0,0,0, + 8,6,8,1,2,1,2,1,8,1,20,1,6,1,14,1, + 2,1,14,252,10,13,8,248,12,1,12,1,14,1,2,128, + 28,248,10,10,10,1,2,244,8,14,122,19,95,77,111,100, + 117,108,101,76,111,99,107,46,97,99,113,117,105,114,101,99, + 1,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0, + 8,0,0,0,67,0,0,0,115,176,0,0,0,116,0,160, + 1,161,0,125,1,124,0,106,2,143,71,1,0,124,0,106, + 3,124,1,107,3,114,17,116,4,100,1,131,1,130,1,124, + 0,106,5,100,2,107,4,115,24,74,0,130,1,124,0,4, + 0,106,5,100,3,56,0,2,0,95,5,124,0,106,5,100, + 2,107,2,114,62,100,0,124,0,95,3,124,0,106,6,114, + 70,124,0,4,0,106,6,100,3,56,0,2,0,95,6,124, + 0,106,7,160,8,161,0,1,0,87,0,100,0,4,0,4, + 0,131,3,1,0,100,0,83,0,87,0,100,0,4,0,4, + 0,131,3,1,0,100,0,83,0,87,0,100,0,4,0,4, + 0,131,3,1,0,100,0,83,0,49,0,115,81,119,1,1, + 0,1,0,1,0,89,0,1,0,100,0,83,0,41,4,78, + 250,31,99,97,110,110,111,116,32,114,101,108,101,97,115,101, + 32,117,110,45,97,99,113,117,105,114,101,100,32,108,111,99, + 107,114,25,0,0,0,114,42,0,0,0,41,9,114,26,0, + 0,0,114,35,0,0,0,114,27,0,0,0,114,29,0,0, + 0,218,12,82,117,110,116,105,109,101,69,114,114,111,114,114, + 30,0,0,0,114,31,0,0,0,114,28,0,0,0,114,44, + 0,0,0,114,45,0,0,0,114,5,0,0,0,114,5,0, + 0,0,114,6,0,0,0,114,44,0,0,0,125,0,0,0, + 115,32,0,0,0,8,1,8,1,10,1,8,1,14,1,14, + 1,10,1,6,1,6,1,14,1,12,1,14,247,2,5,14, + 251,2,7,34,249,122,19,95,77,111,100,117,108,101,76,111, + 99,107,46,114,101,108,101,97,115,101,99,1,0,0,0,0, + 0,0,0,0,0,0,0,1,0,0,0,5,0,0,0,67, + 0,0,0,243,18,0,0,0,100,1,160,0,124,0,106,1, + 116,2,124,0,131,1,161,2,83,0,41,2,78,122,23,95, + 77,111,100,117,108,101,76,111,99,107,40,123,33,114,125,41, + 32,97,116,32,123,125,169,3,218,6,102,111,114,109,97,116, + 114,20,0,0,0,218,2,105,100,169,1,114,33,0,0,0, + 114,5,0,0,0,114,5,0,0,0,114,6,0,0,0,218, + 8,95,95,114,101,112,114,95,95,138,0,0,0,243,2,0, + 0,0,18,1,122,20,95,77,111,100,117,108,101,76,111,99, + 107,46,95,95,114,101,112,114,95,95,78,41,9,114,9,0, + 0,0,114,8,0,0,0,114,1,0,0,0,114,10,0,0, + 0,114,34,0,0,0,114,41,0,0,0,114,43,0,0,0, + 114,44,0,0,0,114,53,0,0,0,114,5,0,0,0,114, + 5,0,0,0,114,5,0,0,0,114,6,0,0,0,114,23, + 0,0,0,65,0,0,0,115,14,0,0,0,8,0,4,1, + 8,5,8,8,8,21,8,25,12,13,114,23,0,0,0,99, + 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, + 2,0,0,0,64,0,0,0,115,48,0,0,0,101,0,90, + 1,100,0,90,2,100,1,90,3,100,2,100,3,132,0,90, + 4,100,4,100,5,132,0,90,5,100,6,100,7,132,0,90, + 6,100,8,100,9,132,0,90,7,100,10,83,0,41,11,218, + 16,95,68,117,109,109,121,77,111,100,117,108,101,76,111,99, + 107,122,86,65,32,115,105,109,112,108,101,32,95,77,111,100, + 117,108,101,76,111,99,107,32,101,113,117,105,118,97,108,101, + 110,116,32,102,111,114,32,80,121,116,104,111,110,32,98,117, + 105,108,100,115,32,119,105,116,104,111,117,116,10,32,32,32, + 32,109,117,108,116,105,45,116,104,114,101,97,100,105,110,103, + 32,115,117,112,112,111,114,116,46,99,2,0,0,0,0,0, + 0,0,0,0,0,0,2,0,0,0,2,0,0,0,67,0, + 0,0,115,16,0,0,0,124,1,124,0,95,0,100,1,124, + 0,95,1,100,0,83,0,114,24,0,0,0,41,2,114,20, + 0,0,0,114,30,0,0,0,114,32,0,0,0,114,5,0, + 0,0,114,5,0,0,0,114,6,0,0,0,114,34,0,0, + 0,146,0,0,0,243,4,0,0,0,6,1,10,1,122,25, 95,68,117,109,109,121,77,111,100,117,108,101,76,111,99,107, - 46,95,95,114,101,112,114,95,95,78,41,8,114,1,0,0, - 0,114,0,0,0,0,114,2,0,0,0,114,3,0,0,0, - 114,31,0,0,0,114,40,0,0,0,114,41,0,0,0,114, - 49,0,0,0,114,10,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,114,50,0,0,0,129,0,0, - 0,115,10,0,0,0,8,1,4,3,8,4,8,4,8,5, - 114,50,0,0,0,99,0,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,2,0,0,0,64,0,0,0,115,36, - 0,0,0,101,0,90,1,100,0,90,2,100,1,100,2,132, - 0,90,3,100,3,100,4,132,0,90,4,100,5,100,6,132, - 0,90,5,100,7,83,0,41,8,218,18,95,77,111,100,117, - 108,101,76,111,99,107,77,97,110,97,103,101,114,99,2,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,2,0, - 0,0,67,0,0,0,115,16,0,0,0,124,1,124,0,95, - 0,100,0,124,0,95,1,100,0,83,0,114,13,0,0,0, - 41,2,218,5,95,110,97,109,101,218,5,95,108,111,99,107, - 114,29,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,114,31,0,0,0,152,0,0,0,115,4,0, - 0,0,0,1,6,1,122,27,95,77,111,100,117,108,101,76, - 111,99,107,77,97,110,97,103,101,114,46,95,95,105,110,105, - 116,95,95,99,1,0,0,0,0,0,0,0,0,0,0,0, - 1,0,0,0,2,0,0,0,67,0,0,0,115,26,0,0, - 0,116,0,124,0,106,1,131,1,124,0,95,2,124,0,106, - 2,160,3,161,0,1,0,100,0,83,0,114,13,0,0,0, - 41,4,218,16,95,103,101,116,95,109,111,100,117,108,101,95, - 108,111,99,107,114,52,0,0,0,114,53,0,0,0,114,40, - 0,0,0,114,48,0,0,0,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,9,95,95,101,110,116,101,114, - 95,95,156,0,0,0,115,4,0,0,0,0,1,12,1,122, - 28,95,77,111,100,117,108,101,76,111,99,107,77,97,110,97, - 103,101,114,46,95,95,101,110,116,101,114,95,95,99,1,0, - 0,0,0,0,0,0,0,0,0,0,3,0,0,0,2,0, - 0,0,79,0,0,0,115,14,0,0,0,124,0,106,0,160, - 1,161,0,1,0,100,0,83,0,114,13,0,0,0,41,2, - 114,53,0,0,0,114,41,0,0,0,41,3,114,30,0,0, - 0,218,4,97,114,103,115,90,6,107,119,97,114,103,115,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,218,8, - 95,95,101,120,105,116,95,95,160,0,0,0,115,2,0,0, - 0,0,1,122,27,95,77,111,100,117,108,101,76,111,99,107, - 77,97,110,97,103,101,114,46,95,95,101,120,105,116,95,95, - 78,41,6,114,1,0,0,0,114,0,0,0,0,114,2,0, - 0,0,114,31,0,0,0,114,55,0,0,0,114,57,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,51,0,0,0,150,0,0,0,115,6, - 0,0,0,8,2,8,4,8,4,114,51,0,0,0,99,1, - 0,0,0,0,0,0,0,0,0,0,0,3,0,0,0,8, - 0,0,0,67,0,0,0,115,136,0,0,0,116,0,160,1, - 161,0,1,0,122,112,122,14,116,2,124,0,25,0,131,0, - 125,1,87,0,110,22,4,0,116,3,121,46,1,0,1,0, - 1,0,100,1,125,1,89,0,110,2,48,0,124,1,100,1, - 117,0,114,110,116,4,100,1,117,0,114,74,116,5,124,0, - 131,1,125,1,110,8,116,6,124,0,131,1,125,1,124,0, - 102,1,100,2,100,3,132,1,125,2,116,7,160,8,124,1, - 124,2,161,2,116,2,124,0,60,0,87,0,116,0,160,9, - 161,0,1,0,110,10,116,0,160,9,161,0,1,0,48,0, - 124,1,83,0,41,4,122,139,71,101,116,32,111,114,32,99, - 114,101,97,116,101,32,116,104,101,32,109,111,100,117,108,101, - 32,108,111,99,107,32,102,111,114,32,97,32,103,105,118,101, - 110,32,109,111,100,117,108,101,32,110,97,109,101,46,10,10, - 32,32,32,32,65,99,113,117,105,114,101,47,114,101,108,101, - 97,115,101,32,105,110,116,101,114,110,97,108,108,121,32,116, - 104,101,32,103,108,111,98,97,108,32,105,109,112,111,114,116, - 32,108,111,99,107,32,116,111,32,112,114,111,116,101,99,116, - 10,32,32,32,32,95,109,111,100,117,108,101,95,108,111,99, - 107,115,46,78,99,2,0,0,0,0,0,0,0,0,0,0, - 0,2,0,0,0,8,0,0,0,83,0,0,0,115,56,0, - 0,0,116,0,160,1,161,0,1,0,122,32,116,2,160,3, - 124,1,161,1,124,0,117,0,114,30,116,2,124,1,61,0, - 87,0,116,0,160,4,161,0,1,0,110,10,116,0,160,4, - 161,0,1,0,48,0,100,0,83,0,114,13,0,0,0,41, - 5,218,4,95,105,109,112,218,12,97,99,113,117,105,114,101, - 95,108,111,99,107,218,13,95,109,111,100,117,108,101,95,108, - 111,99,107,115,114,35,0,0,0,218,12,114,101,108,101,97, - 115,101,95,108,111,99,107,41,2,218,3,114,101,102,114,17, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,218,2,99,98,185,0,0,0,115,10,0,0,0,0, - 1,8,1,2,4,14,1,8,2,122,28,95,103,101,116,95, - 109,111,100,117,108,101,95,108,111,99,107,46,60,108,111,99, - 97,108,115,62,46,99,98,41,10,114,58,0,0,0,114,59, - 0,0,0,114,60,0,0,0,218,8,75,101,121,69,114,114, - 111,114,114,23,0,0,0,114,50,0,0,0,114,20,0,0, - 0,218,8,95,119,101,97,107,114,101,102,114,62,0,0,0, - 114,61,0,0,0,41,3,114,17,0,0,0,114,24,0,0, - 0,114,63,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,54,0,0,0,166,0,0,0,115,28, - 0,0,0,0,6,8,1,2,1,2,1,14,1,12,1,10, - 2,8,1,8,1,10,2,8,2,12,11,18,2,20,2,114, - 54,0,0,0,99,1,0,0,0,0,0,0,0,0,0,0, - 0,2,0,0,0,8,0,0,0,67,0,0,0,115,52,0, - 0,0,116,0,124,0,131,1,125,1,122,12,124,1,160,1, - 161,0,1,0,87,0,110,18,4,0,116,2,121,38,1,0, - 1,0,1,0,89,0,110,10,48,0,124,1,160,3,161,0, - 1,0,100,1,83,0,41,2,122,189,65,99,113,117,105,114, - 101,115,32,116,104,101,110,32,114,101,108,101,97,115,101,115, - 32,116,104,101,32,109,111,100,117,108,101,32,108,111,99,107, - 32,102,111,114,32,97,32,103,105,118,101,110,32,109,111,100, - 117,108,101,32,110,97,109,101,46,10,10,32,32,32,32,84, - 104,105,115,32,105,115,32,117,115,101,100,32,116,111,32,101, - 110,115,117,114,101,32,97,32,109,111,100,117,108,101,32,105, - 115,32,99,111,109,112,108,101,116,101,108,121,32,105,110,105, - 116,105,97,108,105,122,101,100,44,32,105,110,32,116,104,101, - 10,32,32,32,32,101,118,101,110,116,32,105,116,32,105,115, - 32,98,101,105,110,103,32,105,109,112,111,114,116,101,100,32, - 98,121,32,97,110,111,116,104,101,114,32,116,104,114,101,97, - 100,46,10,32,32,32,32,78,41,4,114,54,0,0,0,114, - 40,0,0,0,114,19,0,0,0,114,41,0,0,0,41,2, - 114,17,0,0,0,114,24,0,0,0,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,218,19,95,108,111,99,107, - 95,117,110,108,111,99,107,95,109,111,100,117,108,101,203,0, - 0,0,115,12,0,0,0,0,6,8,1,2,1,12,1,12, - 3,6,2,114,66,0,0,0,99,1,0,0,0,0,0,0, - 0,0,0,0,0,3,0,0,0,4,0,0,0,79,0,0, - 0,115,14,0,0,0,124,0,124,1,105,0,124,2,164,1, - 142,1,83,0,41,1,97,46,1,0,0,114,101,109,111,118, - 101,95,105,109,112,111,114,116,108,105,98,95,102,114,97,109, - 101,115,32,105,110,32,105,109,112,111,114,116,46,99,32,119, - 105,108,108,32,97,108,119,97,121,115,32,114,101,109,111,118, - 101,32,115,101,113,117,101,110,99,101,115,10,32,32,32,32, - 111,102,32,105,109,112,111,114,116,108,105,98,32,102,114,97, - 109,101,115,32,116,104,97,116,32,101,110,100,32,119,105,116, - 104,32,97,32,99,97,108,108,32,116,111,32,116,104,105,115, - 32,102,117,110,99,116,105,111,110,10,10,32,32,32,32,85, - 115,101,32,105,116,32,105,110,115,116,101,97,100,32,111,102, - 32,97,32,110,111,114,109,97,108,32,99,97,108,108,32,105, - 110,32,112,108,97,99,101,115,32,119,104,101,114,101,32,105, - 110,99,108,117,100,105,110,103,32,116,104,101,32,105,109,112, - 111,114,116,108,105,98,10,32,32,32,32,102,114,97,109,101, - 115,32,105,110,116,114,111,100,117,99,101,115,32,117,110,119, - 97,110,116,101,100,32,110,111,105,115,101,32,105,110,116,111, - 32,116,104,101,32,116,114,97,99,101,98,97,99,107,32,40, - 101,46,103,46,32,119,104,101,110,32,101,120,101,99,117,116, - 105,110,103,10,32,32,32,32,109,111,100,117,108,101,32,99, - 111,100,101,41,10,32,32,32,32,114,10,0,0,0,41,3, - 218,1,102,114,56,0,0,0,90,4,107,119,100,115,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,218,25,95, - 99,97,108,108,95,119,105,116,104,95,102,114,97,109,101,115, - 95,114,101,109,111,118,101,100,220,0,0,0,115,2,0,0, - 0,0,8,114,68,0,0,0,114,39,0,0,0,41,1,218, - 9,118,101,114,98,111,115,105,116,121,99,1,0,0,0,0, - 0,0,0,1,0,0,0,3,0,0,0,4,0,0,0,71, - 0,0,0,115,54,0,0,0,116,0,106,1,106,2,124,1, - 107,5,114,50,124,0,160,3,100,1,161,1,115,30,100,2, - 124,0,23,0,125,0,116,4,124,0,106,5,124,2,142,0, - 116,0,106,6,100,3,141,2,1,0,100,4,83,0,41,5, - 122,61,80,114,105,110,116,32,116,104,101,32,109,101,115,115, - 97,103,101,32,116,111,32,115,116,100,101,114,114,32,105,102, - 32,45,118,47,80,89,84,72,79,78,86,69,82,66,79,83, - 69,32,105,115,32,116,117,114,110,101,100,32,111,110,46,41, - 2,250,1,35,122,7,105,109,112,111,114,116,32,122,2,35, - 32,41,1,90,4,102,105,108,101,78,41,7,114,15,0,0, - 0,218,5,102,108,97,103,115,218,7,118,101,114,98,111,115, - 101,218,10,115,116,97,114,116,115,119,105,116,104,218,5,112, - 114,105,110,116,114,46,0,0,0,218,6,115,116,100,101,114, - 114,41,3,218,7,109,101,115,115,97,103,101,114,69,0,0, - 0,114,56,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,16,95,118,101,114,98,111,115,101,95, - 109,101,115,115,97,103,101,231,0,0,0,115,8,0,0,0, - 0,2,12,1,10,1,8,1,114,77,0,0,0,99,1,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,3,0, - 0,0,3,0,0,0,115,26,0,0,0,135,0,102,1,100, - 1,100,2,132,8,125,1,116,0,124,1,136,0,131,2,1, - 0,124,1,83,0,41,3,122,49,68,101,99,111,114,97,116, - 111,114,32,116,111,32,118,101,114,105,102,121,32,116,104,101, - 32,110,97,109,101,100,32,109,111,100,117,108,101,32,105,115, - 32,98,117,105,108,116,45,105,110,46,99,2,0,0,0,0, - 0,0,0,0,0,0,0,2,0,0,0,4,0,0,0,19, - 0,0,0,115,38,0,0,0,124,1,116,0,106,1,118,1, - 114,28,116,2,100,1,160,3,124,1,161,1,124,1,100,2, - 141,2,130,1,136,0,124,0,124,1,131,2,83,0,41,3, - 78,250,29,123,33,114,125,32,105,115,32,110,111,116,32,97, - 32,98,117,105,108,116,45,105,110,32,109,111,100,117,108,101, - 114,16,0,0,0,41,4,114,15,0,0,0,218,20,98,117, - 105,108,116,105,110,95,109,111,100,117,108,101,95,110,97,109, - 101,115,218,11,73,109,112,111,114,116,69,114,114,111,114,114, - 46,0,0,0,169,2,114,30,0,0,0,218,8,102,117,108, - 108,110,97,109,101,169,1,218,3,102,120,110,114,10,0,0, - 0,114,11,0,0,0,218,25,95,114,101,113,117,105,114,101, - 115,95,98,117,105,108,116,105,110,95,119,114,97,112,112,101, - 114,241,0,0,0,115,10,0,0,0,0,1,10,1,10,1, - 2,255,6,2,122,52,95,114,101,113,117,105,114,101,115,95, - 98,117,105,108,116,105,110,46,60,108,111,99,97,108,115,62, - 46,95,114,101,113,117,105,114,101,115,95,98,117,105,108,116, - 105,110,95,119,114,97,112,112,101,114,169,1,114,12,0,0, - 0,41,2,114,84,0,0,0,114,85,0,0,0,114,10,0, - 0,0,114,83,0,0,0,114,11,0,0,0,218,17,95,114, - 101,113,117,105,114,101,115,95,98,117,105,108,116,105,110,239, - 0,0,0,115,6,0,0,0,0,2,12,5,10,1,114,87, - 0,0,0,99,1,0,0,0,0,0,0,0,0,0,0,0, - 2,0,0,0,3,0,0,0,3,0,0,0,115,26,0,0, - 0,135,0,102,1,100,1,100,2,132,8,125,1,116,0,124, - 1,136,0,131,2,1,0,124,1,83,0,41,3,122,47,68, - 101,99,111,114,97,116,111,114,32,116,111,32,118,101,114,105, - 102,121,32,116,104,101,32,110,97,109,101,100,32,109,111,100, - 117,108,101,32,105,115,32,102,114,111,122,101,110,46,99,2, - 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,4, - 0,0,0,19,0,0,0,115,38,0,0,0,116,0,160,1, - 124,1,161,1,115,28,116,2,100,1,160,3,124,1,161,1, - 124,1,100,2,141,2,130,1,136,0,124,0,124,1,131,2, - 83,0,169,3,78,122,27,123,33,114,125,32,105,115,32,110, - 111,116,32,97,32,102,114,111,122,101,110,32,109,111,100,117, - 108,101,114,16,0,0,0,41,4,114,58,0,0,0,218,9, - 105,115,95,102,114,111,122,101,110,114,80,0,0,0,114,46, - 0,0,0,114,81,0,0,0,114,83,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,24,95,114,101,113,117,105,114, - 101,115,95,102,114,111,122,101,110,95,119,114,97,112,112,101, - 114,252,0,0,0,115,10,0,0,0,0,1,10,1,10,1, - 2,255,6,2,122,50,95,114,101,113,117,105,114,101,115,95, - 102,114,111,122,101,110,46,60,108,111,99,97,108,115,62,46, - 95,114,101,113,117,105,114,101,115,95,102,114,111,122,101,110, - 95,119,114,97,112,112,101,114,114,86,0,0,0,41,2,114, - 84,0,0,0,114,90,0,0,0,114,10,0,0,0,114,83, - 0,0,0,114,11,0,0,0,218,16,95,114,101,113,117,105, - 114,101,115,95,102,114,111,122,101,110,250,0,0,0,115,6, - 0,0,0,0,2,12,5,10,1,114,91,0,0,0,99,2, - 0,0,0,0,0,0,0,0,0,0,0,4,0,0,0,3, - 0,0,0,67,0,0,0,115,62,0,0,0,116,0,124,1, - 124,0,131,2,125,2,124,1,116,1,106,2,118,0,114,50, - 116,1,106,2,124,1,25,0,125,3,116,3,124,2,124,3, - 131,2,1,0,116,1,106,2,124,1,25,0,83,0,116,4, - 124,2,131,1,83,0,100,1,83,0,41,2,122,128,76,111, - 97,100,32,116,104,101,32,115,112,101,99,105,102,105,101,100, - 32,109,111,100,117,108,101,32,105,110,116,111,32,115,121,115, - 46,109,111,100,117,108,101,115,32,97,110,100,32,114,101,116, - 117,114,110,32,105,116,46,10,10,32,32,32,32,84,104,105, - 115,32,109,101,116,104,111,100,32,105,115,32,100,101,112,114, - 101,99,97,116,101,100,46,32,32,85,115,101,32,108,111,97, - 100,101,114,46,101,120,101,99,95,109,111,100,117,108,101,32, - 105,110,115,116,101,97,100,46,10,10,32,32,32,32,78,41, - 5,218,16,115,112,101,99,95,102,114,111,109,95,108,111,97, - 100,101,114,114,15,0,0,0,218,7,109,111,100,117,108,101, - 115,218,5,95,101,120,101,99,218,5,95,108,111,97,100,41, - 4,114,30,0,0,0,114,82,0,0,0,218,4,115,112,101, - 99,218,6,109,111,100,117,108,101,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,218,17,95,108,111,97,100,95, - 109,111,100,117,108,101,95,115,104,105,109,6,1,0,0,115, - 12,0,0,0,0,6,10,1,10,1,10,1,10,1,10,2, - 114,98,0,0,0,99,1,0,0,0,0,0,0,0,0,0, - 0,0,5,0,0,0,8,0,0,0,67,0,0,0,115,218, - 0,0,0,116,0,124,0,100,1,100,0,131,3,125,1,116, - 1,124,1,100,2,131,2,114,54,122,12,124,1,160,2,124, - 0,161,1,87,0,83,0,4,0,116,3,121,52,1,0,1, - 0,1,0,89,0,110,2,48,0,122,10,124,0,106,4,125, - 2,87,0,110,18,4,0,116,5,121,82,1,0,1,0,1, - 0,89,0,110,18,48,0,124,2,100,0,117,1,114,100,116, - 6,124,2,131,1,83,0,122,10,124,0,106,7,125,3,87, - 0,110,22,4,0,116,5,121,132,1,0,1,0,1,0,100, - 3,125,3,89,0,110,2,48,0,122,10,124,0,106,8,125, - 4,87,0,110,56,4,0,116,5,121,200,1,0,1,0,1, - 0,124,1,100,0,117,0,114,180,100,4,160,9,124,3,161, - 1,6,0,89,0,83,0,100,5,160,9,124,3,124,1,161, - 2,6,0,89,0,83,0,89,0,110,14,48,0,100,6,160, - 9,124,3,124,4,161,2,83,0,100,0,83,0,41,7,78, - 218,10,95,95,108,111,97,100,101,114,95,95,218,11,109,111, - 100,117,108,101,95,114,101,112,114,250,1,63,250,13,60,109, - 111,100,117,108,101,32,123,33,114,125,62,250,20,60,109,111, - 100,117,108,101,32,123,33,114,125,32,40,123,33,114,125,41, - 62,250,23,60,109,111,100,117,108,101,32,123,33,114,125,32, - 102,114,111,109,32,123,33,114,125,62,41,10,114,6,0,0, - 0,114,4,0,0,0,114,100,0,0,0,218,9,69,120,99, - 101,112,116,105,111,110,218,8,95,95,115,112,101,99,95,95, - 218,14,65,116,116,114,105,98,117,116,101,69,114,114,111,114, - 218,22,95,109,111,100,117,108,101,95,114,101,112,114,95,102, - 114,111,109,95,115,112,101,99,114,1,0,0,0,218,8,95, - 95,102,105,108,101,95,95,114,46,0,0,0,41,5,114,97, - 0,0,0,218,6,108,111,97,100,101,114,114,96,0,0,0, - 114,17,0,0,0,218,8,102,105,108,101,110,97,109,101,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,218,12, - 95,109,111,100,117,108,101,95,114,101,112,114,22,1,0,0, - 115,46,0,0,0,0,2,12,1,10,4,2,1,12,1,12, - 1,6,1,2,1,10,1,12,1,6,2,8,1,8,4,2, - 1,10,1,12,1,10,1,2,1,10,1,12,1,8,1,14, - 2,22,2,114,112,0,0,0,99,0,0,0,0,0,0,0, + 46,95,95,105,110,105,116,95,95,99,1,0,0,0,0,0, + 0,0,0,0,0,0,1,0,0,0,3,0,0,0,67,0, + 0,0,115,18,0,0,0,124,0,4,0,106,0,100,1,55, + 0,2,0,95,0,100,2,83,0,41,3,78,114,42,0,0, + 0,84,41,1,114,30,0,0,0,114,52,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,6,0,0,0,114,43,0, + 0,0,150,0,0,0,115,4,0,0,0,14,1,4,1,122, + 24,95,68,117,109,109,121,77,111,100,117,108,101,76,111,99, + 107,46,97,99,113,117,105,114,101,99,1,0,0,0,0,0, + 0,0,0,0,0,0,1,0,0,0,3,0,0,0,67,0, + 0,0,115,36,0,0,0,124,0,106,0,100,1,107,2,114, + 9,116,1,100,2,131,1,130,1,124,0,4,0,106,0,100, + 3,56,0,2,0,95,0,100,0,83,0,41,4,78,114,25, + 0,0,0,114,46,0,0,0,114,42,0,0,0,41,2,114, + 30,0,0,0,114,47,0,0,0,114,52,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,6,0,0,0,114,44,0, + 0,0,154,0,0,0,115,6,0,0,0,10,1,8,1,18, + 1,122,24,95,68,117,109,109,121,77,111,100,117,108,101,76, + 111,99,107,46,114,101,108,101,97,115,101,99,1,0,0,0, + 0,0,0,0,0,0,0,0,1,0,0,0,5,0,0,0, + 67,0,0,0,114,48,0,0,0,41,2,78,122,28,95,68, + 117,109,109,121,77,111,100,117,108,101,76,111,99,107,40,123, + 33,114,125,41,32,97,116,32,123,125,114,49,0,0,0,114, + 52,0,0,0,114,5,0,0,0,114,5,0,0,0,114,6, + 0,0,0,114,53,0,0,0,159,0,0,0,114,54,0,0, + 0,122,25,95,68,117,109,109,121,77,111,100,117,108,101,76, + 111,99,107,46,95,95,114,101,112,114,95,95,78,41,8,114, + 9,0,0,0,114,8,0,0,0,114,1,0,0,0,114,10, + 0,0,0,114,34,0,0,0,114,43,0,0,0,114,44,0, + 0,0,114,53,0,0,0,114,5,0,0,0,114,5,0,0, + 0,114,5,0,0,0,114,6,0,0,0,114,55,0,0,0, + 142,0,0,0,115,12,0,0,0,8,0,4,1,8,3,8, + 4,8,4,12,5,114,55,0,0,0,99,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,64, + 0,0,0,115,36,0,0,0,101,0,90,1,100,0,90,2, + 100,1,100,2,132,0,90,3,100,3,100,4,132,0,90,4, + 100,5,100,6,132,0,90,5,100,7,83,0,41,8,218,18, + 95,77,111,100,117,108,101,76,111,99,107,77,97,110,97,103, + 101,114,99,2,0,0,0,0,0,0,0,0,0,0,0,2, + 0,0,0,2,0,0,0,67,0,0,0,115,16,0,0,0, + 124,1,124,0,95,0,100,0,124,0,95,1,100,0,83,0, + 114,0,0,0,0,41,2,218,5,95,110,97,109,101,218,5, + 95,108,111,99,107,114,32,0,0,0,114,5,0,0,0,114, + 5,0,0,0,114,6,0,0,0,114,34,0,0,0,165,0, + 0,0,114,56,0,0,0,122,27,95,77,111,100,117,108,101, + 76,111,99,107,77,97,110,97,103,101,114,46,95,95,105,110, + 105,116,95,95,99,1,0,0,0,0,0,0,0,0,0,0, + 0,1,0,0,0,2,0,0,0,67,0,0,0,115,26,0, + 0,0,116,0,124,0,106,1,131,1,124,0,95,2,124,0, + 106,2,160,3,161,0,1,0,100,0,83,0,114,0,0,0, + 0,41,4,218,16,95,103,101,116,95,109,111,100,117,108,101, + 95,108,111,99,107,114,58,0,0,0,114,59,0,0,0,114, + 43,0,0,0,114,52,0,0,0,114,5,0,0,0,114,5, + 0,0,0,114,6,0,0,0,218,9,95,95,101,110,116,101, + 114,95,95,169,0,0,0,115,4,0,0,0,12,1,14,1, + 122,28,95,77,111,100,117,108,101,76,111,99,107,77,97,110, + 97,103,101,114,46,95,95,101,110,116,101,114,95,95,99,1, + 0,0,0,0,0,0,0,0,0,0,0,3,0,0,0,2, + 0,0,0,79,0,0,0,115,14,0,0,0,124,0,106,0, + 160,1,161,0,1,0,100,0,83,0,114,0,0,0,0,41, + 2,114,59,0,0,0,114,44,0,0,0,41,3,114,33,0, + 0,0,218,4,97,114,103,115,90,6,107,119,97,114,103,115, + 114,5,0,0,0,114,5,0,0,0,114,6,0,0,0,218, + 8,95,95,101,120,105,116,95,95,173,0,0,0,115,2,0, + 0,0,14,1,122,27,95,77,111,100,117,108,101,76,111,99, + 107,77,97,110,97,103,101,114,46,95,95,101,120,105,116,95, + 95,78,41,6,114,9,0,0,0,114,8,0,0,0,114,1, + 0,0,0,114,34,0,0,0,114,61,0,0,0,114,63,0, + 0,0,114,5,0,0,0,114,5,0,0,0,114,5,0,0, + 0,114,6,0,0,0,114,57,0,0,0,163,0,0,0,115, + 8,0,0,0,8,0,8,2,8,4,12,4,114,57,0,0, + 0,99,1,0,0,0,0,0,0,0,0,0,0,0,3,0, + 0,0,8,0,0,0,67,0,0,0,115,148,0,0,0,116, + 0,160,1,161,0,1,0,122,64,122,7,116,2,124,0,25, + 0,131,0,125,1,87,0,110,11,4,0,116,3,121,23,1, + 0,1,0,1,0,100,1,125,1,89,0,110,1,119,0,124, + 1,100,1,117,0,114,62,116,4,100,1,117,0,114,37,116, + 5,124,0,131,1,125,1,110,4,116,6,124,0,131,1,125, + 1,124,0,102,1,100,2,100,3,132,1,125,2,116,7,160, + 8,124,1,124,2,161,2,116,2,124,0,60,0,87,0,116, + 0,160,9,161,0,1,0,124,1,83,0,87,0,116,0,160, + 9,161,0,1,0,124,1,83,0,116,0,160,9,161,0,1, + 0,119,0,41,4,122,139,71,101,116,32,111,114,32,99,114, + 101,97,116,101,32,116,104,101,32,109,111,100,117,108,101,32, + 108,111,99,107,32,102,111,114,32,97,32,103,105,118,101,110, + 32,109,111,100,117,108,101,32,110,97,109,101,46,10,10,32, + 32,32,32,65,99,113,117,105,114,101,47,114,101,108,101,97, + 115,101,32,105,110,116,101,114,110,97,108,108,121,32,116,104, + 101,32,103,108,111,98,97,108,32,105,109,112,111,114,116,32, + 108,111,99,107,32,116,111,32,112,114,111,116,101,99,116,10, + 32,32,32,32,95,109,111,100,117,108,101,95,108,111,99,107, + 115,46,78,99,2,0,0,0,0,0,0,0,0,0,0,0, + 2,0,0,0,8,0,0,0,83,0,0,0,115,68,0,0, + 0,116,0,160,1,161,0,1,0,122,24,116,2,160,3,124, + 1,161,1,124,0,117,0,114,22,116,2,124,1,61,0,87, + 0,116,0,160,4,161,0,1,0,100,0,83,0,87,0,116, + 0,160,4,161,0,1,0,100,0,83,0,116,0,160,4,161, + 0,1,0,119,0,114,0,0,0,0,41,5,218,4,95,105, + 109,112,218,12,97,99,113,117,105,114,101,95,108,111,99,107, + 218,13,95,109,111,100,117,108,101,95,108,111,99,107,115,114, + 38,0,0,0,218,12,114,101,108,101,97,115,101,95,108,111, + 99,107,41,2,218,3,114,101,102,114,20,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,6,0,0,0,218,2,99, + 98,198,0,0,0,115,14,0,0,0,8,1,2,1,14,4, + 8,1,12,2,2,253,22,3,122,28,95,103,101,116,95,109, + 111,100,117,108,101,95,108,111,99,107,46,60,108,111,99,97, + 108,115,62,46,99,98,41,10,114,64,0,0,0,114,65,0, + 0,0,114,66,0,0,0,218,8,75,101,121,69,114,114,111, + 114,114,26,0,0,0,114,55,0,0,0,114,23,0,0,0, + 218,8,95,119,101,97,107,114,101,102,114,68,0,0,0,114, + 67,0,0,0,41,3,114,20,0,0,0,114,27,0,0,0, + 114,69,0,0,0,114,5,0,0,0,114,5,0,0,0,114, + 6,0,0,0,114,60,0,0,0,179,0,0,0,115,38,0, + 0,0,8,6,2,1,2,1,14,1,12,1,8,1,2,255, + 8,3,8,1,10,1,8,2,12,2,18,11,8,2,4,2, + 2,235,8,19,4,2,10,254,114,60,0,0,0,99,1,0, + 0,0,0,0,0,0,0,0,0,0,2,0,0,0,8,0, + 0,0,67,0,0,0,115,54,0,0,0,116,0,124,0,131, + 1,125,1,122,6,124,1,160,1,161,0,1,0,87,0,110, + 10,4,0,116,2,121,20,1,0,1,0,1,0,89,0,100, + 1,83,0,119,0,124,1,160,3,161,0,1,0,100,1,83, + 0,41,2,122,189,65,99,113,117,105,114,101,115,32,116,104, + 101,110,32,114,101,108,101,97,115,101,115,32,116,104,101,32, + 109,111,100,117,108,101,32,108,111,99,107,32,102,111,114,32, + 97,32,103,105,118,101,110,32,109,111,100,117,108,101,32,110, + 97,109,101,46,10,10,32,32,32,32,84,104,105,115,32,105, + 115,32,117,115,101,100,32,116,111,32,101,110,115,117,114,101, + 32,97,32,109,111,100,117,108,101,32,105,115,32,99,111,109, + 112,108,101,116,101,108,121,32,105,110,105,116,105,97,108,105, + 122,101,100,44,32,105,110,32,116,104,101,10,32,32,32,32, + 101,118,101,110,116,32,105,116,32,105,115,32,98,101,105,110, + 103,32,105,109,112,111,114,116,101,100,32,98,121,32,97,110, + 111,116,104,101,114,32,116,104,114,101,97,100,46,10,32,32, + 32,32,78,41,4,114,60,0,0,0,114,43,0,0,0,114, + 22,0,0,0,114,44,0,0,0,41,2,114,20,0,0,0, + 114,27,0,0,0,114,5,0,0,0,114,5,0,0,0,114, + 6,0,0,0,218,19,95,108,111,99,107,95,117,110,108,111, + 99,107,95,109,111,100,117,108,101,216,0,0,0,115,14,0, + 0,0,8,6,2,1,12,1,12,1,6,3,2,253,12,5, + 114,72,0,0,0,99,1,0,0,0,0,0,0,0,0,0, + 0,0,3,0,0,0,4,0,0,0,79,0,0,0,115,14, + 0,0,0,124,0,124,1,105,0,124,2,164,1,142,1,83, + 0,41,1,97,46,1,0,0,114,101,109,111,118,101,95,105, + 109,112,111,114,116,108,105,98,95,102,114,97,109,101,115,32, + 105,110,32,105,109,112,111,114,116,46,99,32,119,105,108,108, + 32,97,108,119,97,121,115,32,114,101,109,111,118,101,32,115, + 101,113,117,101,110,99,101,115,10,32,32,32,32,111,102,32, + 105,109,112,111,114,116,108,105,98,32,102,114,97,109,101,115, + 32,116,104,97,116,32,101,110,100,32,119,105,116,104,32,97, + 32,99,97,108,108,32,116,111,32,116,104,105,115,32,102,117, + 110,99,116,105,111,110,10,10,32,32,32,32,85,115,101,32, + 105,116,32,105,110,115,116,101,97,100,32,111,102,32,97,32, + 110,111,114,109,97,108,32,99,97,108,108,32,105,110,32,112, + 108,97,99,101,115,32,119,104,101,114,101,32,105,110,99,108, + 117,100,105,110,103,32,116,104,101,32,105,109,112,111,114,116, + 108,105,98,10,32,32,32,32,102,114,97,109,101,115,32,105, + 110,116,114,111,100,117,99,101,115,32,117,110,119,97,110,116, + 101,100,32,110,111,105,115,101,32,105,110,116,111,32,116,104, + 101,32,116,114,97,99,101,98,97,99,107,32,40,101,46,103, + 46,32,119,104,101,110,32,101,120,101,99,117,116,105,110,103, + 10,32,32,32,32,109,111,100,117,108,101,32,99,111,100,101, + 41,10,32,32,32,32,114,5,0,0,0,41,3,218,1,102, + 114,62,0,0,0,90,4,107,119,100,115,114,5,0,0,0, + 114,5,0,0,0,114,6,0,0,0,218,25,95,99,97,108, + 108,95,119,105,116,104,95,102,114,97,109,101,115,95,114,101, + 109,111,118,101,100,233,0,0,0,115,2,0,0,0,14,8, + 114,74,0,0,0,114,42,0,0,0,41,1,218,9,118,101, + 114,98,111,115,105,116,121,99,1,0,0,0,0,0,0,0, + 1,0,0,0,3,0,0,0,4,0,0,0,71,0,0,0, + 115,58,0,0,0,116,0,106,1,106,2,124,1,107,5,114, + 27,124,0,160,3,100,1,161,1,115,15,100,2,124,0,23, + 0,125,0,116,4,124,0,106,5,124,2,142,0,116,0,106, + 6,100,3,141,2,1,0,100,4,83,0,100,4,83,0,41, + 5,122,61,80,114,105,110,116,32,116,104,101,32,109,101,115, + 115,97,103,101,32,116,111,32,115,116,100,101,114,114,32,105, + 102,32,45,118,47,80,89,84,72,79,78,86,69,82,66,79, + 83,69,32,105,115,32,116,117,114,110,101,100,32,111,110,46, + 41,2,250,1,35,122,7,105,109,112,111,114,116,32,122,2, + 35,32,41,1,90,4,102,105,108,101,78,41,7,114,18,0, + 0,0,218,5,102,108,97,103,115,218,7,118,101,114,98,111, + 115,101,218,10,115,116,97,114,116,115,119,105,116,104,218,5, + 112,114,105,110,116,114,50,0,0,0,218,6,115,116,100,101, + 114,114,41,3,218,7,109,101,115,115,97,103,101,114,75,0, + 0,0,114,62,0,0,0,114,5,0,0,0,114,5,0,0, + 0,114,6,0,0,0,218,16,95,118,101,114,98,111,115,101, + 95,109,101,115,115,97,103,101,244,0,0,0,115,10,0,0, + 0,12,2,10,1,8,1,24,1,4,253,114,83,0,0,0, + 99,1,0,0,0,0,0,0,0,0,0,0,0,2,0,0, + 0,3,0,0,0,3,0,0,0,243,26,0,0,0,135,0, + 102,1,100,1,100,2,132,8,125,1,116,0,124,1,136,0, + 131,2,1,0,124,1,83,0,41,3,122,49,68,101,99,111, + 114,97,116,111,114,32,116,111,32,118,101,114,105,102,121,32, + 116,104,101,32,110,97,109,101,100,32,109,111,100,117,108,101, + 32,105,115,32,98,117,105,108,116,45,105,110,46,99,2,0, + 0,0,0,0,0,0,0,0,0,0,2,0,0,0,4,0, + 0,0,19,0,0,0,115,38,0,0,0,124,1,116,0,106, + 1,118,1,114,14,116,2,100,1,160,3,124,1,161,1,124, + 1,100,2,141,2,130,1,136,0,124,0,124,1,131,2,83, + 0,41,3,78,250,29,123,33,114,125,32,105,115,32,110,111, + 116,32,97,32,98,117,105,108,116,45,105,110,32,109,111,100, + 117,108,101,114,19,0,0,0,41,4,114,18,0,0,0,218, + 20,98,117,105,108,116,105,110,95,109,111,100,117,108,101,95, + 110,97,109,101,115,218,11,73,109,112,111,114,116,69,114,114, + 111,114,114,50,0,0,0,169,2,114,33,0,0,0,218,8, + 102,117,108,108,110,97,109,101,169,1,218,3,102,120,110,114, + 5,0,0,0,114,6,0,0,0,218,25,95,114,101,113,117, + 105,114,101,115,95,98,117,105,108,116,105,110,95,119,114,97, + 112,112,101,114,254,0,0,0,243,10,0,0,0,10,1,10, + 1,2,1,6,255,10,2,122,52,95,114,101,113,117,105,114, + 101,115,95,98,117,105,108,116,105,110,46,60,108,111,99,97, + 108,115,62,46,95,114,101,113,117,105,114,101,115,95,98,117, + 105,108,116,105,110,95,119,114,97,112,112,101,114,169,1,114, + 17,0,0,0,41,2,114,91,0,0,0,114,92,0,0,0, + 114,5,0,0,0,114,90,0,0,0,114,6,0,0,0,218, + 17,95,114,101,113,117,105,114,101,115,95,98,117,105,108,116, + 105,110,252,0,0,0,243,6,0,0,0,12,2,10,5,4, + 1,114,95,0,0,0,99,1,0,0,0,0,0,0,0,0, + 0,0,0,2,0,0,0,3,0,0,0,3,0,0,0,114, + 84,0,0,0,41,3,122,47,68,101,99,111,114,97,116,111, + 114,32,116,111,32,118,101,114,105,102,121,32,116,104,101,32, + 110,97,109,101,100,32,109,111,100,117,108,101,32,105,115,32, + 102,114,111,122,101,110,46,99,2,0,0,0,0,0,0,0, + 0,0,0,0,2,0,0,0,4,0,0,0,19,0,0,0, + 115,38,0,0,0,116,0,160,1,124,1,161,1,115,14,116, + 2,100,1,160,3,124,1,161,1,124,1,100,2,141,2,130, + 1,136,0,124,0,124,1,131,2,83,0,169,3,78,122,27, + 123,33,114,125,32,105,115,32,110,111,116,32,97,32,102,114, + 111,122,101,110,32,109,111,100,117,108,101,114,19,0,0,0, + 41,4,114,64,0,0,0,218,9,105,115,95,102,114,111,122, + 101,110,114,87,0,0,0,114,50,0,0,0,114,88,0,0, + 0,114,90,0,0,0,114,5,0,0,0,114,6,0,0,0, + 218,24,95,114,101,113,117,105,114,101,115,95,102,114,111,122, + 101,110,95,119,114,97,112,112,101,114,9,1,0,0,114,93, + 0,0,0,122,50,95,114,101,113,117,105,114,101,115,95,102, + 114,111,122,101,110,46,60,108,111,99,97,108,115,62,46,95, + 114,101,113,117,105,114,101,115,95,102,114,111,122,101,110,95, + 119,114,97,112,112,101,114,114,94,0,0,0,41,2,114,91, + 0,0,0,114,99,0,0,0,114,5,0,0,0,114,90,0, + 0,0,114,6,0,0,0,218,16,95,114,101,113,117,105,114, + 101,115,95,102,114,111,122,101,110,7,1,0,0,114,96,0, + 0,0,114,100,0,0,0,99,2,0,0,0,0,0,0,0, + 0,0,0,0,5,0,0,0,4,0,0,0,67,0,0,0, + 115,74,0,0,0,100,1,125,2,116,0,160,1,124,2,116, + 2,161,2,1,0,116,3,124,1,124,0,131,2,125,3,124, + 1,116,4,106,5,118,0,114,33,116,4,106,5,124,1,25, + 0,125,4,116,6,124,3,124,4,131,2,1,0,116,4,106, + 5,124,1,25,0,83,0,116,7,124,3,131,1,83,0,41, + 2,122,130,76,111,97,100,32,116,104,101,32,115,112,101,99, + 105,102,105,101,100,32,109,111,100,117,108,101,32,105,110,116, + 111,32,115,121,115,46,109,111,100,117,108,101,115,32,97,110, + 100,32,114,101,116,117,114,110,32,105,116,46,10,10,32,32, + 32,32,84,104,105,115,32,109,101,116,104,111,100,32,105,115, + 32,100,101,112,114,101,99,97,116,101,100,46,32,32,85,115, + 101,32,108,111,97,100,101,114,46,101,120,101,99,95,109,111, + 100,117,108,101,40,41,32,105,110,115,116,101,97,100,46,10, + 10,32,32,32,32,122,103,116,104,101,32,108,111,97,100,95, + 109,111,100,117,108,101,40,41,32,109,101,116,104,111,100,32, + 105,115,32,100,101,112,114,101,99,97,116,101,100,32,97,110, + 100,32,115,108,97,116,101,100,32,102,111,114,32,114,101,109, + 111,118,97,108,32,105,110,32,80,121,116,104,111,110,32,51, + 46,49,50,59,32,117,115,101,32,101,120,101,99,95,109,111, + 100,117,108,101,40,41,32,105,110,115,116,101,97,100,41,8, + 218,9,95,119,97,114,110,105,110,103,115,218,4,119,97,114, + 110,218,18,68,101,112,114,101,99,97,116,105,111,110,87,97, + 114,110,105,110,103,218,16,115,112,101,99,95,102,114,111,109, + 95,108,111,97,100,101,114,114,18,0,0,0,218,7,109,111, + 100,117,108,101,115,218,5,95,101,120,101,99,218,5,95,108, + 111,97,100,41,5,114,33,0,0,0,114,89,0,0,0,218, + 3,109,115,103,218,4,115,112,101,99,218,6,109,111,100,117, + 108,101,114,5,0,0,0,114,5,0,0,0,114,6,0,0, + 0,218,17,95,108,111,97,100,95,109,111,100,117,108,101,95, + 115,104,105,109,19,1,0,0,115,16,0,0,0,4,6,12, + 2,10,1,10,1,10,1,10,1,10,1,8,2,114,111,0, + 0,0,99,1,0,0,0,0,0,0,0,0,0,0,0,5, + 0,0,0,8,0,0,0,67,0,0,0,115,188,0,0,0, + 116,0,124,0,100,1,100,2,131,3,125,1,116,0,124,0, + 100,3,100,2,131,3,4,0,125,2,114,18,116,1,124,2, + 131,1,83,0,116,2,124,1,100,4,131,2,114,39,122,6, + 124,1,160,3,124,0,161,1,87,0,83,0,4,0,116,4, + 121,38,1,0,1,0,1,0,89,0,110,1,119,0,122,5, + 124,0,106,5,125,3,87,0,110,11,4,0,116,6,121,55, + 1,0,1,0,1,0,100,5,125,3,89,0,110,1,119,0, + 122,5,124,0,106,7,125,4,87,0,110,26,4,0,116,6, + 121,87,1,0,1,0,1,0,124,1,100,2,117,0,114,79, + 100,6,160,8,124,3,161,1,6,0,89,0,83,0,100,7, + 160,8,124,3,124,1,161,2,6,0,89,0,83,0,119,0, + 100,8,160,8,124,3,124,4,161,2,83,0,41,9,122,44, + 84,104,101,32,105,109,112,108,101,109,101,110,116,97,116,105, + 111,110,32,111,102,32,77,111,100,117,108,101,84,121,112,101, + 46,95,95,114,101,112,114,95,95,40,41,46,218,10,95,95, + 108,111,97,100,101,114,95,95,78,218,8,95,95,115,112,101, + 99,95,95,218,11,109,111,100,117,108,101,95,114,101,112,114, + 250,1,63,250,13,60,109,111,100,117,108,101,32,123,33,114, + 125,62,250,20,60,109,111,100,117,108,101,32,123,33,114,125, + 32,40,123,33,114,125,41,62,250,23,60,109,111,100,117,108, + 101,32,123,33,114,125,32,102,114,111,109,32,123,33,114,125, + 62,41,9,114,13,0,0,0,218,22,95,109,111,100,117,108, + 101,95,114,101,112,114,95,102,114,111,109,95,115,112,101,99, + 114,11,0,0,0,114,114,0,0,0,218,9,69,120,99,101, + 112,116,105,111,110,114,9,0,0,0,114,2,0,0,0,218, + 8,95,95,102,105,108,101,95,95,114,50,0,0,0,41,5, + 114,110,0,0,0,218,6,108,111,97,100,101,114,114,109,0, + 0,0,114,20,0,0,0,218,8,102,105,108,101,110,97,109, + 101,114,5,0,0,0,114,5,0,0,0,114,6,0,0,0, + 218,12,95,109,111,100,117,108,101,95,114,101,112,114,38,1, + 0,0,115,44,0,0,0,12,2,16,1,8,1,10,1,2, + 1,12,1,12,1,4,1,2,255,2,3,10,1,12,1,8, + 1,2,255,2,2,10,1,12,1,8,1,14,1,16,2,2, + 252,12,6,114,124,0,0,0,99,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,4,0,0,0,64,0,0, 0,115,114,0,0,0,101,0,90,1,100,0,90,2,100,1, 90,3,100,2,100,2,100,2,100,3,156,3,100,4,100,5, @@ -640,25 +664,25 @@ const unsigned char _Py_M__importlib_bootstrap[] = { 99,3,0,0,0,0,0,0,0,3,0,0,0,6,0,0, 0,2,0,0,0,67,0,0,0,115,54,0,0,0,124,1, 124,0,95,0,124,2,124,0,95,1,124,3,124,0,95,2, - 124,4,124,0,95,3,124,5,114,32,103,0,110,2,100,0, + 124,4,124,0,95,3,124,5,114,16,103,0,110,1,100,0, 124,0,95,4,100,1,124,0,95,5,100,0,124,0,95,6, - 100,0,83,0,41,2,78,70,41,7,114,17,0,0,0,114, - 110,0,0,0,114,114,0,0,0,114,115,0,0,0,218,26, + 100,0,83,0,41,2,78,70,41,7,114,20,0,0,0,114, + 122,0,0,0,114,126,0,0,0,114,127,0,0,0,218,26, 115,117,98,109,111,100,117,108,101,95,115,101,97,114,99,104, 95,108,111,99,97,116,105,111,110,115,218,13,95,115,101,116, 95,102,105,108,101,97,116,116,114,218,7,95,99,97,99,104, - 101,100,41,6,114,30,0,0,0,114,17,0,0,0,114,110, - 0,0,0,114,114,0,0,0,114,115,0,0,0,114,116,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,114,31,0,0,0,95,1,0,0,115,14,0,0,0,0, - 2,6,1,6,1,6,1,6,1,14,3,6,1,122,19,77, + 101,100,41,6,114,33,0,0,0,114,20,0,0,0,114,122, + 0,0,0,114,126,0,0,0,114,127,0,0,0,114,128,0, + 0,0,114,5,0,0,0,114,5,0,0,0,114,6,0,0, + 0,114,34,0,0,0,101,1,0,0,115,14,0,0,0,6, + 2,6,1,6,1,6,1,14,1,6,3,10,1,122,19,77, 111,100,117,108,101,83,112,101,99,46,95,95,105,110,105,116, 95,95,99,1,0,0,0,0,0,0,0,0,0,0,0,2, 0,0,0,6,0,0,0,67,0,0,0,115,102,0,0,0, 100,1,160,0,124,0,106,1,161,1,100,2,160,0,124,0, 106,2,161,1,103,2,125,1,124,0,106,3,100,0,117,1, - 114,52,124,1,160,4,100,3,160,0,124,0,106,3,161,1, - 161,1,1,0,124,0,106,5,100,0,117,1,114,80,124,1, + 114,26,124,1,160,4,100,3,160,0,124,0,106,3,161,1, + 161,1,1,0,124,0,106,5,100,0,117,1,114,40,124,1, 160,4,100,4,160,0,124,0,106,5,161,1,161,1,1,0, 100,5,160,0,124,0,106,6,106,7,100,6,160,8,124,1, 161,1,161,2,83,0,41,7,78,122,9,110,97,109,101,61, @@ -666,1147 +690,1196 @@ const unsigned char _Py_M__importlib_bootstrap[] = { 125,122,11,111,114,105,103,105,110,61,123,33,114,125,122,29, 115,117,98,109,111,100,117,108,101,95,115,101,97,114,99,104, 95,108,111,99,97,116,105,111,110,115,61,123,125,122,6,123, - 125,40,123,125,41,122,2,44,32,41,9,114,46,0,0,0, - 114,17,0,0,0,114,110,0,0,0,114,114,0,0,0,218, - 6,97,112,112,101,110,100,114,117,0,0,0,218,9,95,95, - 99,108,97,115,115,95,95,114,1,0,0,0,218,4,106,111, - 105,110,41,2,114,30,0,0,0,114,56,0,0,0,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,114,49,0, - 0,0,107,1,0,0,115,20,0,0,0,0,1,10,1,10, - 255,4,2,10,1,18,1,10,1,8,1,4,255,6,2,122, + 125,40,123,125,41,122,2,44,32,41,9,114,50,0,0,0, + 114,20,0,0,0,114,122,0,0,0,114,126,0,0,0,218, + 6,97,112,112,101,110,100,114,129,0,0,0,218,9,95,95, + 99,108,97,115,115,95,95,114,9,0,0,0,218,4,106,111, + 105,110,41,2,114,33,0,0,0,114,62,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,6,0,0,0,114,53,0, + 0,0,113,1,0,0,115,20,0,0,0,10,1,10,1,4, + 255,10,2,18,1,10,1,6,1,8,1,4,255,22,2,122, 19,77,111,100,117,108,101,83,112,101,99,46,95,95,114,101, 112,114,95,95,99,2,0,0,0,0,0,0,0,0,0,0, - 0,3,0,0,0,8,0,0,0,67,0,0,0,115,106,0, - 0,0,124,0,106,0,125,2,122,72,124,0,106,1,124,1, - 106,1,107,2,111,76,124,0,106,2,124,1,106,2,107,2, - 111,76,124,0,106,3,124,1,106,3,107,2,111,76,124,2, - 124,1,106,0,107,2,111,76,124,0,106,4,124,1,106,4, - 107,2,111,76,124,0,106,5,124,1,106,5,107,2,87,0, - 83,0,4,0,116,6,121,100,1,0,1,0,1,0,116,7, - 6,0,89,0,83,0,48,0,100,0,83,0,114,13,0,0, - 0,41,8,114,117,0,0,0,114,17,0,0,0,114,110,0, - 0,0,114,114,0,0,0,218,6,99,97,99,104,101,100,218, - 12,104,97,115,95,108,111,99,97,116,105,111,110,114,107,0, - 0,0,218,14,78,111,116,73,109,112,108,101,109,101,110,116, - 101,100,41,3,114,30,0,0,0,90,5,111,116,104,101,114, - 90,4,115,109,115,108,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,6,95,95,101,113,95,95,117,1,0, - 0,115,30,0,0,0,0,1,6,1,2,1,12,1,10,255, - 2,2,10,254,2,3,8,253,2,4,10,252,2,5,10,251, - 4,6,12,1,122,17,77,111,100,117,108,101,83,112,101,99, - 46,95,95,101,113,95,95,99,1,0,0,0,0,0,0,0, - 0,0,0,0,1,0,0,0,3,0,0,0,67,0,0,0, - 115,58,0,0,0,124,0,106,0,100,0,117,0,114,52,124, - 0,106,1,100,0,117,1,114,52,124,0,106,2,114,52,116, - 3,100,0,117,0,114,38,116,4,130,1,116,3,160,5,124, - 0,106,1,161,1,124,0,95,0,124,0,106,0,83,0,114, - 13,0,0,0,41,6,114,119,0,0,0,114,114,0,0,0, - 114,118,0,0,0,218,19,95,98,111,111,116,115,116,114,97, - 112,95,101,120,116,101,114,110,97,108,218,19,78,111,116,73, - 109,112,108,101,109,101,110,116,101,100,69,114,114,111,114,90, - 11,95,103,101,116,95,99,97,99,104,101,100,114,48,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,11,0,0,0, - 114,123,0,0,0,129,1,0,0,115,12,0,0,0,0,2, - 10,1,16,1,8,1,4,1,14,1,122,17,77,111,100,117, - 108,101,83,112,101,99,46,99,97,99,104,101,100,99,2,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,2,0, - 0,0,67,0,0,0,115,10,0,0,0,124,1,124,0,95, - 0,100,0,83,0,114,13,0,0,0,41,1,114,119,0,0, - 0,41,2,114,30,0,0,0,114,123,0,0,0,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,114,123,0,0, - 0,138,1,0,0,115,2,0,0,0,0,2,99,1,0,0, - 0,0,0,0,0,0,0,0,0,1,0,0,0,3,0,0, - 0,67,0,0,0,115,36,0,0,0,124,0,106,0,100,1, - 117,0,114,26,124,0,106,1,160,2,100,2,161,1,100,3, - 25,0,83,0,124,0,106,1,83,0,100,1,83,0,41,4, - 122,32,84,104,101,32,110,97,109,101,32,111,102,32,116,104, - 101,32,109,111,100,117,108,101,39,115,32,112,97,114,101,110, - 116,46,78,218,1,46,114,22,0,0,0,41,3,114,117,0, - 0,0,114,17,0,0,0,218,10,114,112,97,114,116,105,116, - 105,111,110,114,48,0,0,0,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,6,112,97,114,101,110,116,142, - 1,0,0,115,6,0,0,0,0,3,10,1,16,2,122,17, - 77,111,100,117,108,101,83,112,101,99,46,112,97,114,101,110, - 116,99,1,0,0,0,0,0,0,0,0,0,0,0,1,0, - 0,0,1,0,0,0,67,0,0,0,115,6,0,0,0,124, - 0,106,0,83,0,114,13,0,0,0,41,1,114,118,0,0, - 0,114,48,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,124,0,0,0,150,1,0,0,115,2, - 0,0,0,0,2,122,23,77,111,100,117,108,101,83,112,101, - 99,46,104,97,115,95,108,111,99,97,116,105,111,110,99,2, - 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,2, - 0,0,0,67,0,0,0,115,14,0,0,0,116,0,124,1, - 131,1,124,0,95,1,100,0,83,0,114,13,0,0,0,41, - 2,218,4,98,111,111,108,114,118,0,0,0,41,2,114,30, - 0,0,0,218,5,118,97,108,117,101,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,114,124,0,0,0,154,1, - 0,0,115,2,0,0,0,0,2,41,12,114,1,0,0,0, - 114,0,0,0,0,114,2,0,0,0,114,3,0,0,0,114, - 31,0,0,0,114,49,0,0,0,114,126,0,0,0,218,8, - 112,114,111,112,101,114,116,121,114,123,0,0,0,218,6,115, - 101,116,116,101,114,114,131,0,0,0,114,124,0,0,0,114, - 10,0,0,0,114,10,0,0,0,114,10,0,0,0,114,11, - 0,0,0,114,113,0,0,0,58,1,0,0,115,32,0,0, - 0,8,1,4,36,4,1,2,255,12,12,8,10,8,12,2, - 1,10,8,4,1,10,3,2,1,10,7,2,1,10,3,4, - 1,114,113,0,0,0,169,2,114,114,0,0,0,114,116,0, - 0,0,99,2,0,0,0,0,0,0,0,2,0,0,0,6, - 0,0,0,8,0,0,0,67,0,0,0,115,152,0,0,0, - 116,0,124,1,100,1,131,2,114,74,116,1,100,2,117,0, - 114,22,116,2,130,1,116,1,106,3,125,4,124,3,100,2, - 117,0,114,48,124,4,124,0,124,1,100,3,141,2,83,0, - 124,3,114,56,103,0,110,2,100,2,125,5,124,4,124,0, - 124,1,124,5,100,4,141,3,83,0,124,3,100,2,117,0, - 114,136,116,0,124,1,100,5,131,2,114,132,122,14,124,1, - 160,4,124,0,161,1,125,3,87,0,113,136,4,0,116,5, - 121,128,1,0,1,0,1,0,100,2,125,3,89,0,113,136, - 48,0,110,4,100,6,125,3,116,6,124,0,124,1,124,2, - 124,3,100,7,141,4,83,0,41,8,122,53,82,101,116,117, - 114,110,32,97,32,109,111,100,117,108,101,32,115,112,101,99, - 32,98,97,115,101,100,32,111,110,32,118,97,114,105,111,117, - 115,32,108,111,97,100,101,114,32,109,101,116,104,111,100,115, - 46,90,12,103,101,116,95,102,105,108,101,110,97,109,101,78, - 41,1,114,110,0,0,0,41,2,114,110,0,0,0,114,117, - 0,0,0,114,116,0,0,0,70,114,136,0,0,0,41,7, - 114,4,0,0,0,114,127,0,0,0,114,128,0,0,0,218, - 23,115,112,101,99,95,102,114,111,109,95,102,105,108,101,95, - 108,111,99,97,116,105,111,110,114,116,0,0,0,114,80,0, - 0,0,114,113,0,0,0,41,6,114,17,0,0,0,114,110, - 0,0,0,114,114,0,0,0,114,116,0,0,0,114,137,0, - 0,0,90,6,115,101,97,114,99,104,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,114,92,0,0,0,159,1, - 0,0,115,36,0,0,0,0,2,10,1,8,1,4,1,6, - 2,8,1,12,1,12,1,6,1,2,255,6,3,8,1,10, - 1,2,1,14,1,12,1,12,3,4,2,114,92,0,0,0, - 99,3,0,0,0,0,0,0,0,0,0,0,0,8,0,0, - 0,8,0,0,0,67,0,0,0,115,42,1,0,0,122,10, - 124,0,106,0,125,3,87,0,110,18,4,0,116,1,121,28, - 1,0,1,0,1,0,89,0,110,14,48,0,124,3,100,0, - 117,1,114,42,124,3,83,0,124,0,106,2,125,4,124,1, - 100,0,117,0,114,86,122,10,124,0,106,3,125,1,87,0, - 110,18,4,0,116,1,121,84,1,0,1,0,1,0,89,0, - 110,2,48,0,122,10,124,0,106,4,125,5,87,0,110,22, - 4,0,116,1,121,118,1,0,1,0,1,0,100,0,125,5, - 89,0,110,2,48,0,124,2,100,0,117,0,114,176,124,5, - 100,0,117,0,114,172,122,10,124,1,106,5,125,2,87,0, - 113,176,4,0,116,1,121,168,1,0,1,0,1,0,100,0, - 125,2,89,0,113,176,48,0,110,4,124,5,125,2,122,10, - 124,0,106,6,125,6,87,0,110,22,4,0,116,1,121,208, - 1,0,1,0,1,0,100,0,125,6,89,0,110,2,48,0, - 122,14,116,7,124,0,106,8,131,1,125,7,87,0,110,22, - 4,0,116,1,121,246,1,0,1,0,1,0,100,0,125,7, - 89,0,110,2,48,0,116,9,124,4,124,1,124,2,100,1, - 141,3,125,3,124,5,100,0,117,0,144,1,114,20,100,2, - 110,2,100,3,124,3,95,10,124,6,124,3,95,11,124,7, - 124,3,95,12,124,3,83,0,41,4,78,169,1,114,114,0, - 0,0,70,84,41,13,114,106,0,0,0,114,107,0,0,0, - 114,1,0,0,0,114,99,0,0,0,114,109,0,0,0,218, - 7,95,79,82,73,71,73,78,218,10,95,95,99,97,99,104, - 101,100,95,95,218,4,108,105,115,116,218,8,95,95,112,97, - 116,104,95,95,114,113,0,0,0,114,118,0,0,0,114,123, - 0,0,0,114,117,0,0,0,41,8,114,97,0,0,0,114, - 110,0,0,0,114,114,0,0,0,114,96,0,0,0,114,17, - 0,0,0,90,8,108,111,99,97,116,105,111,110,114,123,0, - 0,0,114,117,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,218,17,95,115,112,101,99,95,102,114, - 111,109,95,109,111,100,117,108,101,185,1,0,0,115,72,0, - 0,0,0,2,2,1,10,1,12,1,6,2,8,1,4,2, - 6,1,8,1,2,1,10,1,12,2,6,1,2,1,10,1, - 12,1,10,1,8,1,8,1,2,1,10,1,12,1,12,2, - 4,1,2,1,10,1,12,1,10,1,2,1,14,1,12,1, - 10,2,14,1,20,1,6,1,6,1,114,143,0,0,0,70, - 169,1,218,8,111,118,101,114,114,105,100,101,99,2,0,0, - 0,0,0,0,0,1,0,0,0,5,0,0,0,8,0,0, - 0,67,0,0,0,115,210,1,0,0,124,2,115,20,116,0, - 124,1,100,1,100,0,131,3,100,0,117,0,114,52,122,12, - 124,0,106,1,124,1,95,2,87,0,110,18,4,0,116,3, - 121,50,1,0,1,0,1,0,89,0,110,2,48,0,124,2, - 115,72,116,0,124,1,100,2,100,0,131,3,100,0,117,0, - 114,174,124,0,106,4,125,3,124,3,100,0,117,0,114,144, - 124,0,106,5,100,0,117,1,114,144,116,6,100,0,117,0, - 114,108,116,7,130,1,116,6,106,8,125,4,124,4,160,9, - 124,4,161,1,125,3,124,0,106,5,124,3,95,10,124,3, - 124,0,95,4,100,0,124,1,95,11,122,10,124,3,124,1, - 95,12,87,0,110,18,4,0,116,3,121,172,1,0,1,0, - 1,0,89,0,110,2,48,0,124,2,115,194,116,0,124,1, - 100,3,100,0,131,3,100,0,117,0,114,226,122,12,124,0, - 106,13,124,1,95,14,87,0,110,18,4,0,116,3,121,224, - 1,0,1,0,1,0,89,0,110,2,48,0,122,10,124,0, - 124,1,95,15,87,0,110,18,4,0,116,3,121,254,1,0, - 1,0,1,0,89,0,110,2,48,0,124,2,144,1,115,24, - 116,0,124,1,100,4,100,0,131,3,100,0,117,0,144,1, - 114,70,124,0,106,5,100,0,117,1,144,1,114,70,122,12, - 124,0,106,5,124,1,95,16,87,0,110,20,4,0,116,3, - 144,1,121,68,1,0,1,0,1,0,89,0,110,2,48,0, - 124,0,106,17,144,1,114,206,124,2,144,1,115,102,116,0, - 124,1,100,5,100,0,131,3,100,0,117,0,144,1,114,136, - 122,12,124,0,106,18,124,1,95,11,87,0,110,20,4,0, - 116,3,144,1,121,134,1,0,1,0,1,0,89,0,110,2, - 48,0,124,2,144,1,115,160,116,0,124,1,100,6,100,0, - 131,3,100,0,117,0,144,1,114,206,124,0,106,19,100,0, - 117,1,144,1,114,206,122,12,124,0,106,19,124,1,95,20, - 87,0,110,20,4,0,116,3,144,1,121,204,1,0,1,0, - 1,0,89,0,110,2,48,0,124,1,83,0,41,7,78,114, - 1,0,0,0,114,99,0,0,0,218,11,95,95,112,97,99, - 107,97,103,101,95,95,114,142,0,0,0,114,109,0,0,0, - 114,140,0,0,0,41,21,114,6,0,0,0,114,17,0,0, - 0,114,1,0,0,0,114,107,0,0,0,114,110,0,0,0, - 114,117,0,0,0,114,127,0,0,0,114,128,0,0,0,218, + 0,3,0,0,0,8,0,0,0,67,0,0,0,115,102,0, + 0,0,124,0,106,0,125,2,122,36,124,0,106,1,124,1, + 106,1,107,2,111,38,124,0,106,2,124,1,106,2,107,2, + 111,38,124,0,106,3,124,1,106,3,107,2,111,38,124,2, + 124,1,106,0,107,2,111,38,124,0,106,4,124,1,106,4, + 107,2,111,38,124,0,106,5,124,1,106,5,107,2,87,0, + 83,0,4,0,116,6,121,50,1,0,1,0,1,0,116,7, + 6,0,89,0,83,0,119,0,114,0,0,0,0,41,8,114, + 129,0,0,0,114,20,0,0,0,114,122,0,0,0,114,126, + 0,0,0,218,6,99,97,99,104,101,100,218,12,104,97,115, + 95,108,111,99,97,116,105,111,110,114,2,0,0,0,218,14, + 78,111,116,73,109,112,108,101,109,101,110,116,101,100,41,3, + 114,33,0,0,0,90,5,111,116,104,101,114,90,4,115,109, + 115,108,114,5,0,0,0,114,5,0,0,0,114,6,0,0, + 0,218,6,95,95,101,113,95,95,123,1,0,0,115,32,0, + 0,0,6,1,2,1,12,1,10,1,2,255,10,2,2,254, + 8,3,2,253,10,4,2,252,10,5,4,251,12,6,8,1, + 2,255,122,17,77,111,100,117,108,101,83,112,101,99,46,95, + 95,101,113,95,95,99,1,0,0,0,0,0,0,0,0,0, + 0,0,1,0,0,0,3,0,0,0,67,0,0,0,115,58, + 0,0,0,124,0,106,0,100,0,117,0,114,26,124,0,106, + 1,100,0,117,1,114,26,124,0,106,2,114,26,116,3,100, + 0,117,0,114,19,116,4,130,1,116,3,160,5,124,0,106, + 1,161,1,124,0,95,0,124,0,106,0,83,0,114,0,0, + 0,0,41,6,114,131,0,0,0,114,126,0,0,0,114,130, + 0,0,0,218,19,95,98,111,111,116,115,116,114,97,112,95, + 101,120,116,101,114,110,97,108,218,19,78,111,116,73,109,112, + 108,101,109,101,110,116,101,100,69,114,114,111,114,90,11,95, + 103,101,116,95,99,97,99,104,101,100,114,52,0,0,0,114, + 5,0,0,0,114,5,0,0,0,114,6,0,0,0,114,135, + 0,0,0,135,1,0,0,115,12,0,0,0,10,2,16,1, + 8,1,4,1,14,1,6,1,122,17,77,111,100,117,108,101, + 83,112,101,99,46,99,97,99,104,101,100,99,2,0,0,0, + 0,0,0,0,0,0,0,0,2,0,0,0,2,0,0,0, + 67,0,0,0,115,10,0,0,0,124,1,124,0,95,0,100, + 0,83,0,114,0,0,0,0,41,1,114,131,0,0,0,41, + 2,114,33,0,0,0,114,135,0,0,0,114,5,0,0,0, + 114,5,0,0,0,114,6,0,0,0,114,135,0,0,0,144, + 1,0,0,115,2,0,0,0,10,2,99,1,0,0,0,0, + 0,0,0,0,0,0,0,1,0,0,0,3,0,0,0,67, + 0,0,0,115,32,0,0,0,124,0,106,0,100,1,117,0, + 114,13,124,0,106,1,160,2,100,2,161,1,100,3,25,0, + 83,0,124,0,106,1,83,0,41,4,122,32,84,104,101,32, + 110,97,109,101,32,111,102,32,116,104,101,32,109,111,100,117, + 108,101,39,115,32,112,97,114,101,110,116,46,78,218,1,46, + 114,25,0,0,0,41,3,114,129,0,0,0,114,20,0,0, + 0,218,10,114,112,97,114,116,105,116,105,111,110,114,52,0, + 0,0,114,5,0,0,0,114,5,0,0,0,114,6,0,0, + 0,218,6,112,97,114,101,110,116,148,1,0,0,115,6,0, + 0,0,10,3,16,1,6,2,122,17,77,111,100,117,108,101, + 83,112,101,99,46,112,97,114,101,110,116,99,1,0,0,0, + 0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0, + 67,0,0,0,115,6,0,0,0,124,0,106,0,83,0,114, + 0,0,0,0,41,1,114,130,0,0,0,114,52,0,0,0, + 114,5,0,0,0,114,5,0,0,0,114,6,0,0,0,114, + 136,0,0,0,156,1,0,0,115,2,0,0,0,6,2,122, + 23,77,111,100,117,108,101,83,112,101,99,46,104,97,115,95, + 108,111,99,97,116,105,111,110,99,2,0,0,0,0,0,0, + 0,0,0,0,0,2,0,0,0,2,0,0,0,67,0,0, + 0,115,14,0,0,0,116,0,124,1,131,1,124,0,95,1, + 100,0,83,0,114,0,0,0,0,41,2,218,4,98,111,111, + 108,114,130,0,0,0,41,2,114,33,0,0,0,218,5,118, + 97,108,117,101,114,5,0,0,0,114,5,0,0,0,114,6, + 0,0,0,114,136,0,0,0,160,1,0,0,115,2,0,0, + 0,14,2,41,12,114,9,0,0,0,114,8,0,0,0,114, + 1,0,0,0,114,10,0,0,0,114,34,0,0,0,114,53, + 0,0,0,114,138,0,0,0,218,8,112,114,111,112,101,114, + 116,121,114,135,0,0,0,218,6,115,101,116,116,101,114,114, + 143,0,0,0,114,136,0,0,0,114,5,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,6,0,0,0,114,125,0, + 0,0,64,1,0,0,115,34,0,0,0,8,0,4,1,4, + 36,2,1,12,255,8,12,8,10,2,12,10,1,4,8,10, + 1,2,3,10,1,2,7,10,1,4,3,14,1,114,125,0, + 0,0,169,2,114,126,0,0,0,114,128,0,0,0,99,2, + 0,0,0,0,0,0,0,2,0,0,0,6,0,0,0,8, + 0,0,0,67,0,0,0,115,150,0,0,0,116,0,124,1, + 100,1,131,2,114,37,116,1,100,2,117,0,114,11,116,2, + 130,1,116,1,106,3,125,4,124,3,100,2,117,0,114,24, + 124,4,124,0,124,1,100,3,141,2,83,0,124,3,114,28, + 103,0,110,1,100,2,125,5,124,4,124,0,124,1,124,5, + 100,4,141,3,83,0,124,3,100,2,117,0,114,67,116,0, + 124,1,100,5,131,2,114,65,122,7,124,1,160,4,124,0, + 161,1,125,3,87,0,110,13,4,0,116,5,121,64,1,0, + 1,0,1,0,100,2,125,3,89,0,110,3,119,0,100,6, + 125,3,116,6,124,0,124,1,124,2,124,3,100,7,141,4, + 83,0,41,8,122,53,82,101,116,117,114,110,32,97,32,109, + 111,100,117,108,101,32,115,112,101,99,32,98,97,115,101,100, + 32,111,110,32,118,97,114,105,111,117,115,32,108,111,97,100, + 101,114,32,109,101,116,104,111,100,115,46,90,12,103,101,116, + 95,102,105,108,101,110,97,109,101,78,41,1,114,122,0,0, + 0,41,2,114,122,0,0,0,114,129,0,0,0,114,128,0, + 0,0,70,114,148,0,0,0,41,7,114,11,0,0,0,114, + 139,0,0,0,114,140,0,0,0,218,23,115,112,101,99,95, + 102,114,111,109,95,102,105,108,101,95,108,111,99,97,116,105, + 111,110,114,128,0,0,0,114,87,0,0,0,114,125,0,0, + 0,41,6,114,20,0,0,0,114,122,0,0,0,114,126,0, + 0,0,114,128,0,0,0,114,149,0,0,0,90,6,115,101, + 97,114,99,104,114,5,0,0,0,114,5,0,0,0,114,6, + 0,0,0,114,104,0,0,0,165,1,0,0,115,38,0,0, + 0,10,2,8,1,4,1,6,1,8,2,12,1,12,1,6, + 1,2,1,6,255,8,3,10,1,2,1,14,1,12,1,8, + 1,2,255,4,4,16,2,114,104,0,0,0,99,3,0,0, + 0,0,0,0,0,0,0,0,0,8,0,0,0,8,0,0, + 0,67,0,0,0,115,38,1,0,0,122,5,124,0,106,0, + 125,3,87,0,110,9,4,0,116,1,121,14,1,0,1,0, + 1,0,89,0,110,7,119,0,124,3,100,0,117,1,114,21, + 124,3,83,0,124,0,106,2,125,4,124,1,100,0,117,0, + 114,43,122,5,124,0,106,3,125,1,87,0,110,9,4,0, + 116,1,121,42,1,0,1,0,1,0,89,0,110,1,119,0, + 122,5,124,0,106,4,125,5,87,0,110,11,4,0,116,1, + 121,59,1,0,1,0,1,0,100,0,125,5,89,0,110,1, + 119,0,124,2,100,0,117,0,114,87,124,5,100,0,117,0, + 114,85,122,5,124,1,106,5,125,2,87,0,110,13,4,0, + 116,1,121,84,1,0,1,0,1,0,100,0,125,2,89,0, + 110,3,119,0,124,5,125,2,122,5,124,0,106,6,125,6, + 87,0,110,11,4,0,116,1,121,103,1,0,1,0,1,0, + 100,0,125,6,89,0,110,1,119,0,122,7,116,7,124,0, + 106,8,131,1,125,7,87,0,110,11,4,0,116,1,121,122, + 1,0,1,0,1,0,100,0,125,7,89,0,110,1,119,0, + 116,9,124,4,124,1,124,2,100,1,141,3,125,3,124,5, + 100,0,117,0,114,136,100,2,110,1,100,3,124,3,95,10, + 124,6,124,3,95,11,124,7,124,3,95,12,124,3,83,0, + 41,4,78,169,1,114,126,0,0,0,70,84,41,13,114,113, + 0,0,0,114,2,0,0,0,114,9,0,0,0,114,112,0, + 0,0,114,121,0,0,0,218,7,95,79,82,73,71,73,78, + 218,10,95,95,99,97,99,104,101,100,95,95,218,4,108,105, + 115,116,218,8,95,95,112,97,116,104,95,95,114,125,0,0, + 0,114,130,0,0,0,114,135,0,0,0,114,129,0,0,0, + 41,8,114,110,0,0,0,114,122,0,0,0,114,126,0,0, + 0,114,109,0,0,0,114,20,0,0,0,90,8,108,111,99, + 97,116,105,111,110,114,135,0,0,0,114,129,0,0,0,114, + 5,0,0,0,114,5,0,0,0,114,6,0,0,0,218,17, + 95,115,112,101,99,95,102,114,111,109,95,109,111,100,117,108, + 101,191,1,0,0,115,84,0,0,0,2,2,10,1,12,1, + 4,1,2,255,8,3,4,1,6,2,8,1,2,1,10,1, + 12,1,4,2,2,254,2,3,10,1,12,1,8,1,2,255, + 8,2,8,1,2,1,10,1,12,1,8,1,2,255,4,3, + 2,1,10,1,12,1,8,1,2,255,2,2,14,1,12,1, + 8,1,2,255,14,3,18,1,6,1,6,1,4,1,114,155, + 0,0,0,70,169,1,218,8,111,118,101,114,114,105,100,101, + 99,2,0,0,0,0,0,0,0,1,0,0,0,5,0,0, + 0,8,0,0,0,67,0,0,0,115,190,1,0,0,124,2, + 115,10,116,0,124,1,100,1,100,0,131,3,100,0,117,0, + 114,26,122,6,124,0,106,1,124,1,95,2,87,0,110,9, + 4,0,116,3,121,25,1,0,1,0,1,0,89,0,110,1, + 119,0,124,2,115,36,116,0,124,1,100,2,100,0,131,3, + 100,0,117,0,114,87,124,0,106,4,125,3,124,3,100,0, + 117,0,114,72,124,0,106,5,100,0,117,1,114,72,116,6, + 100,0,117,0,114,54,116,7,130,1,116,6,106,8,125,4, + 124,4,160,9,124,4,161,1,125,3,124,0,106,5,124,3, + 95,10,124,3,124,0,95,4,100,0,124,1,95,11,122,5, + 124,3,124,1,95,12,87,0,110,9,4,0,116,3,121,86, + 1,0,1,0,1,0,89,0,110,1,119,0,124,2,115,97, + 116,0,124,1,100,3,100,0,131,3,100,0,117,0,114,113, + 122,6,124,0,106,13,124,1,95,14,87,0,110,9,4,0, + 116,3,121,112,1,0,1,0,1,0,89,0,110,1,119,0, + 122,5,124,0,124,1,95,15,87,0,110,9,4,0,116,3, + 121,127,1,0,1,0,1,0,89,0,110,1,119,0,124,2, + 115,138,116,0,124,1,100,4,100,0,131,3,100,0,117,0, + 114,159,124,0,106,5,100,0,117,1,114,159,122,6,124,0, + 106,5,124,1,95,16,87,0,110,9,4,0,116,3,121,158, + 1,0,1,0,1,0,89,0,110,1,119,0,124,0,106,17, + 114,221,124,2,115,172,116,0,124,1,100,5,100,0,131,3, + 100,0,117,0,114,188,122,6,124,0,106,18,124,1,95,11, + 87,0,110,9,4,0,116,3,121,187,1,0,1,0,1,0, + 89,0,110,1,119,0,124,2,115,198,116,0,124,1,100,6, + 100,0,131,3,100,0,117,0,114,221,124,0,106,19,100,0, + 117,1,114,221,122,7,124,0,106,19,124,1,95,20,87,0, + 124,1,83,0,4,0,116,3,121,220,1,0,1,0,1,0, + 89,0,124,1,83,0,119,0,124,1,83,0,41,7,78,114, + 9,0,0,0,114,112,0,0,0,218,11,95,95,112,97,99, + 107,97,103,101,95,95,114,154,0,0,0,114,121,0,0,0, + 114,152,0,0,0,41,21,114,13,0,0,0,114,20,0,0, + 0,114,9,0,0,0,114,2,0,0,0,114,122,0,0,0, + 114,129,0,0,0,114,139,0,0,0,114,140,0,0,0,218, 16,95,78,97,109,101,115,112,97,99,101,76,111,97,100,101, 114,218,7,95,95,110,101,119,95,95,90,5,95,112,97,116, - 104,114,109,0,0,0,114,99,0,0,0,114,131,0,0,0, - 114,146,0,0,0,114,106,0,0,0,114,142,0,0,0,114, - 124,0,0,0,114,114,0,0,0,114,123,0,0,0,114,140, - 0,0,0,41,5,114,96,0,0,0,114,97,0,0,0,114, - 145,0,0,0,114,110,0,0,0,114,147,0,0,0,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,218,18,95, + 104,114,121,0,0,0,114,112,0,0,0,114,143,0,0,0, + 114,158,0,0,0,114,113,0,0,0,114,154,0,0,0,114, + 136,0,0,0,114,126,0,0,0,114,135,0,0,0,114,152, + 0,0,0,41,5,114,109,0,0,0,114,110,0,0,0,114, + 157,0,0,0,114,122,0,0,0,114,159,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,6,0,0,0,218,18,95, 105,110,105,116,95,109,111,100,117,108,101,95,97,116,116,114, - 115,230,1,0,0,115,96,0,0,0,0,4,20,1,2,1, - 12,1,12,1,6,2,20,1,6,1,8,2,10,1,8,1, - 4,1,6,2,10,1,8,1,6,11,6,1,2,1,10,1, - 12,1,6,2,20,1,2,1,12,1,12,1,6,2,2,1, - 10,1,12,1,6,2,24,1,12,1,2,1,12,1,14,1, - 6,2,8,1,24,1,2,1,12,1,14,1,6,2,24,1, - 12,1,2,1,12,1,14,1,6,1,114,149,0,0,0,99, - 1,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0, - 3,0,0,0,67,0,0,0,115,82,0,0,0,100,1,125, - 1,116,0,124,0,106,1,100,2,131,2,114,30,124,0,106, - 1,160,2,124,0,161,1,125,1,110,20,116,0,124,0,106, - 1,100,3,131,2,114,50,116,3,100,4,131,1,130,1,124, - 1,100,1,117,0,114,68,116,4,124,0,106,5,131,1,125, - 1,116,6,124,0,124,1,131,2,1,0,124,1,83,0,41, - 5,122,43,67,114,101,97,116,101,32,97,32,109,111,100,117, - 108,101,32,98,97,115,101,100,32,111,110,32,116,104,101,32, - 112,114,111,118,105,100,101,100,32,115,112,101,99,46,78,218, - 13,99,114,101,97,116,101,95,109,111,100,117,108,101,218,11, - 101,120,101,99,95,109,111,100,117,108,101,122,66,108,111,97, - 100,101,114,115,32,116,104,97,116,32,100,101,102,105,110,101, - 32,101,120,101,99,95,109,111,100,117,108,101,40,41,32,109, - 117,115,116,32,97,108,115,111,32,100,101,102,105,110,101,32, - 99,114,101,97,116,101,95,109,111,100,117,108,101,40,41,41, - 7,114,4,0,0,0,114,110,0,0,0,114,150,0,0,0, - 114,80,0,0,0,114,18,0,0,0,114,17,0,0,0,114, - 149,0,0,0,169,2,114,96,0,0,0,114,97,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,218, - 16,109,111,100,117,108,101,95,102,114,111,109,95,115,112,101, - 99,46,2,0,0,115,18,0,0,0,0,3,4,1,12,3, - 14,1,12,1,8,2,8,1,10,1,10,1,114,153,0,0, + 115,236,1,0,0,115,114,0,0,0,20,4,2,1,12,1, + 12,1,4,1,2,255,20,3,6,1,8,1,10,2,8,1, + 4,1,6,1,10,2,8,1,6,1,6,11,2,1,10,1, + 12,1,4,1,2,255,20,3,2,1,12,1,12,1,4,1, + 2,255,2,3,10,1,12,1,4,1,2,255,20,3,10,1, + 2,1,12,1,12,1,4,1,2,255,6,3,20,1,2,1, + 12,1,12,1,4,1,2,255,20,3,10,1,2,1,10,1, + 4,3,12,254,2,1,4,1,2,254,4,2,114,161,0,0, 0,99,1,0,0,0,0,0,0,0,0,0,0,0,2,0, - 0,0,4,0,0,0,67,0,0,0,115,106,0,0,0,124, - 0,106,0,100,1,117,0,114,14,100,2,110,4,124,0,106, - 0,125,1,124,0,106,1,100,1,117,0,114,66,124,0,106, - 2,100,1,117,0,114,50,100,3,160,3,124,1,161,1,83, - 0,100,4,160,3,124,1,124,0,106,2,161,2,83,0,110, - 36,124,0,106,4,114,86,100,5,160,3,124,1,124,0,106, + 0,0,3,0,0,0,67,0,0,0,115,82,0,0,0,100, + 1,125,1,116,0,124,0,106,1,100,2,131,2,114,15,124, + 0,106,1,160,2,124,0,161,1,125,1,110,10,116,0,124, + 0,106,1,100,3,131,2,114,25,116,3,100,4,131,1,130, + 1,124,1,100,1,117,0,114,34,116,4,124,0,106,5,131, + 1,125,1,116,6,124,0,124,1,131,2,1,0,124,1,83, + 0,41,5,122,43,67,114,101,97,116,101,32,97,32,109,111, + 100,117,108,101,32,98,97,115,101,100,32,111,110,32,116,104, + 101,32,112,114,111,118,105,100,101,100,32,115,112,101,99,46, + 78,218,13,99,114,101,97,116,101,95,109,111,100,117,108,101, + 218,11,101,120,101,99,95,109,111,100,117,108,101,122,66,108, + 111,97,100,101,114,115,32,116,104,97,116,32,100,101,102,105, + 110,101,32,101,120,101,99,95,109,111,100,117,108,101,40,41, + 32,109,117,115,116,32,97,108,115,111,32,100,101,102,105,110, + 101,32,99,114,101,97,116,101,95,109,111,100,117,108,101,40, + 41,41,7,114,11,0,0,0,114,122,0,0,0,114,162,0, + 0,0,114,87,0,0,0,114,21,0,0,0,114,20,0,0, + 0,114,161,0,0,0,169,2,114,109,0,0,0,114,110,0, + 0,0,114,5,0,0,0,114,5,0,0,0,114,6,0,0, + 0,218,16,109,111,100,117,108,101,95,102,114,111,109,95,115, + 112,101,99,52,2,0,0,115,18,0,0,0,4,3,12,1, + 14,3,12,1,8,1,8,2,10,1,10,1,4,1,114,165, + 0,0,0,99,1,0,0,0,0,0,0,0,0,0,0,0, + 2,0,0,0,4,0,0,0,67,0,0,0,115,100,0,0, + 0,124,0,106,0,100,1,117,0,114,7,100,2,110,2,124, + 0,106,0,125,1,124,0,106,1,100,1,117,0,114,32,124, + 0,106,2,100,1,117,0,114,25,100,3,160,3,124,1,161, + 1,83,0,100,4,160,3,124,1,124,0,106,2,161,2,83, + 0,124,0,106,4,114,42,100,5,160,3,124,1,124,0,106, 1,161,2,83,0,100,6,160,3,124,0,106,0,124,0,106, - 1,161,2,83,0,100,1,83,0,41,7,122,38,82,101,116, - 117,114,110,32,116,104,101,32,114,101,112,114,32,116,111,32, - 117,115,101,32,102,111,114,32,116,104,101,32,109,111,100,117, - 108,101,46,78,114,101,0,0,0,114,102,0,0,0,114,103, - 0,0,0,114,104,0,0,0,250,18,60,109,111,100,117,108, - 101,32,123,33,114,125,32,40,123,125,41,62,41,5,114,17, - 0,0,0,114,114,0,0,0,114,110,0,0,0,114,46,0, - 0,0,114,124,0,0,0,41,2,114,96,0,0,0,114,17, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,114,108,0,0,0,63,2,0,0,115,16,0,0,0, - 0,3,20,1,10,1,10,1,10,2,16,2,6,1,14,2, - 114,108,0,0,0,99,2,0,0,0,0,0,0,0,0,0, - 0,0,4,0,0,0,10,0,0,0,67,0,0,0,115,250, - 0,0,0,124,0,106,0,125,2,116,1,124,2,131,1,143, - 216,1,0,116,2,106,3,160,4,124,2,161,1,124,1,117, - 1,114,54,100,1,160,5,124,2,161,1,125,3,116,6,124, - 3,124,2,100,2,141,2,130,1,122,132,124,0,106,7,100, - 3,117,0,114,106,124,0,106,8,100,3,117,0,114,90,116, - 6,100,4,124,0,106,0,100,2,141,2,130,1,116,9,124, - 0,124,1,100,5,100,6,141,3,1,0,110,52,116,9,124, - 0,124,1,100,5,100,6,141,3,1,0,116,10,124,0,106, - 7,100,7,131,2,115,146,124,0,106,7,160,11,124,2,161, - 1,1,0,110,12,124,0,106,7,160,12,124,1,161,1,1, - 0,87,0,116,2,106,3,160,13,124,0,106,0,161,1,125, - 1,124,1,116,2,106,3,124,0,106,0,60,0,110,28,116, - 2,106,3,160,13,124,0,106,0,161,1,125,1,124,1,116, - 2,106,3,124,0,106,0,60,0,48,0,87,0,100,3,4, - 0,4,0,131,3,1,0,110,16,49,0,115,236,48,0,1, - 0,1,0,1,0,89,0,1,0,124,1,83,0,41,8,122, - 70,69,120,101,99,117,116,101,32,116,104,101,32,115,112,101, - 99,39,115,32,115,112,101,99,105,102,105,101,100,32,109,111, - 100,117,108,101,32,105,110,32,97,110,32,101,120,105,115,116, - 105,110,103,32,109,111,100,117,108,101,39,115,32,110,97,109, - 101,115,112,97,99,101,46,122,30,109,111,100,117,108,101,32, - 123,33,114,125,32,110,111,116,32,105,110,32,115,121,115,46, - 109,111,100,117,108,101,115,114,16,0,0,0,78,250,14,109, - 105,115,115,105,110,103,32,108,111,97,100,101,114,84,114,144, - 0,0,0,114,151,0,0,0,41,14,114,17,0,0,0,114, - 51,0,0,0,114,15,0,0,0,114,93,0,0,0,114,35, - 0,0,0,114,46,0,0,0,114,80,0,0,0,114,110,0, - 0,0,114,117,0,0,0,114,149,0,0,0,114,4,0,0, - 0,218,11,108,111,97,100,95,109,111,100,117,108,101,114,151, - 0,0,0,218,3,112,111,112,41,4,114,96,0,0,0,114, - 97,0,0,0,114,17,0,0,0,218,3,109,115,103,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,114,94,0, - 0,0,80,2,0,0,115,38,0,0,0,0,2,6,1,10, - 1,16,1,10,1,12,1,2,1,10,1,10,1,14,2,16, - 2,14,1,12,4,14,2,14,4,14,1,14,255,14,1,44, - 1,114,94,0,0,0,99,1,0,0,0,0,0,0,0,0, - 0,0,0,2,0,0,0,8,0,0,0,67,0,0,0,115, - 20,1,0,0,122,18,124,0,106,0,160,1,124,0,106,2, - 161,1,1,0,87,0,110,52,1,0,1,0,1,0,124,0, - 106,2,116,3,106,4,118,0,114,64,116,3,106,4,160,5, - 124,0,106,2,161,1,125,1,124,1,116,3,106,4,124,0, - 106,2,60,0,130,0,89,0,110,2,48,0,116,3,106,4, - 160,5,124,0,106,2,161,1,125,1,124,1,116,3,106,4, - 124,0,106,2,60,0,116,6,124,1,100,1,100,0,131,3, - 100,0,117,0,114,146,122,12,124,0,106,0,124,1,95,7, - 87,0,110,18,4,0,116,8,121,144,1,0,1,0,1,0, - 89,0,110,2,48,0,116,6,124,1,100,2,100,0,131,3, - 100,0,117,0,114,222,122,40,124,1,106,9,124,1,95,10, - 116,11,124,1,100,3,131,2,115,200,124,0,106,2,160,12, - 100,4,161,1,100,5,25,0,124,1,95,10,87,0,110,18, - 4,0,116,8,121,220,1,0,1,0,1,0,89,0,110,2, - 48,0,116,6,124,1,100,6,100,0,131,3,100,0,117,0, - 144,1,114,16,122,10,124,0,124,1,95,13,87,0,110,20, - 4,0,116,8,144,1,121,14,1,0,1,0,1,0,89,0, - 110,2,48,0,124,1,83,0,41,7,78,114,99,0,0,0, - 114,146,0,0,0,114,142,0,0,0,114,129,0,0,0,114, - 22,0,0,0,114,106,0,0,0,41,14,114,110,0,0,0, - 114,156,0,0,0,114,17,0,0,0,114,15,0,0,0,114, - 93,0,0,0,114,157,0,0,0,114,6,0,0,0,114,99, - 0,0,0,114,107,0,0,0,114,1,0,0,0,114,146,0, - 0,0,114,4,0,0,0,114,130,0,0,0,114,106,0,0, - 0,114,152,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,25,95,108,111,97,100,95,98,97,99, - 107,119,97,114,100,95,99,111,109,112,97,116,105,98,108,101, - 110,2,0,0,115,54,0,0,0,0,4,2,1,18,1,6, - 1,12,1,14,1,12,1,8,3,14,1,12,1,16,1,2, - 1,12,1,12,1,6,1,16,1,2,4,8,1,10,1,22, - 1,12,1,6,1,18,1,2,1,10,1,14,1,6,1,114, - 159,0,0,0,99,1,0,0,0,0,0,0,0,0,0,0, - 0,2,0,0,0,11,0,0,0,67,0,0,0,115,224,0, - 0,0,124,0,106,0,100,0,117,1,114,30,116,1,124,0, - 106,0,100,1,131,2,115,30,116,2,124,0,131,1,83,0, - 116,3,124,0,131,1,125,1,100,2,124,0,95,4,122,166, - 124,1,116,5,106,6,124,0,106,7,60,0,122,52,124,0, - 106,0,100,0,117,0,114,96,124,0,106,8,100,0,117,0, - 114,108,116,9,100,3,124,0,106,7,100,4,141,2,130,1, - 110,12,124,0,106,0,160,10,124,1,161,1,1,0,87,0, - 110,48,1,0,1,0,1,0,122,14,116,5,106,6,124,0, - 106,7,61,0,87,0,110,18,4,0,116,11,121,150,1,0, - 1,0,1,0,89,0,110,2,48,0,130,0,89,0,110,2, - 48,0,116,5,106,6,160,12,124,0,106,7,161,1,125,1, - 124,1,116,5,106,6,124,0,106,7,60,0,116,13,100,5, - 124,0,106,7,124,0,106,0,131,3,1,0,87,0,100,6, - 124,0,95,4,110,8,100,6,124,0,95,4,48,0,124,1, - 83,0,41,7,78,114,151,0,0,0,84,114,155,0,0,0, - 114,16,0,0,0,122,18,105,109,112,111,114,116,32,123,33, - 114,125,32,35,32,123,33,114,125,70,41,14,114,110,0,0, - 0,114,4,0,0,0,114,159,0,0,0,114,153,0,0,0, - 90,13,95,105,110,105,116,105,97,108,105,122,105,110,103,114, - 15,0,0,0,114,93,0,0,0,114,17,0,0,0,114,117, - 0,0,0,114,80,0,0,0,114,151,0,0,0,114,64,0, - 0,0,114,157,0,0,0,114,77,0,0,0,114,152,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,11,0,0,0, - 218,14,95,108,111,97,100,95,117,110,108,111,99,107,101,100, - 147,2,0,0,115,46,0,0,0,0,2,10,2,12,1,8, - 2,8,5,6,1,2,1,12,1,2,1,10,1,10,1,16, - 3,16,1,6,1,2,1,14,1,12,1,6,1,8,5,14, - 1,12,1,18,2,16,2,114,160,0,0,0,99,1,0,0, - 0,0,0,0,0,0,0,0,0,1,0,0,0,8,0,0, - 0,67,0,0,0,115,54,0,0,0,116,0,124,0,106,1, - 131,1,143,24,1,0,116,2,124,0,131,1,87,0,2,0, - 100,1,4,0,4,0,131,3,1,0,83,0,49,0,115,40, - 48,0,1,0,1,0,1,0,89,0,1,0,100,1,83,0, - 41,2,122,191,82,101,116,117,114,110,32,97,32,110,101,119, - 32,109,111,100,117,108,101,32,111,98,106,101,99,116,44,32, - 108,111,97,100,101,100,32,98,121,32,116,104,101,32,115,112, - 101,99,39,115,32,108,111,97,100,101,114,46,10,10,32,32, - 32,32,84,104,101,32,109,111,100,117,108,101,32,105,115,32, - 110,111,116,32,97,100,100,101,100,32,116,111,32,105,116,115, - 32,112,97,114,101,110,116,46,10,10,32,32,32,32,73,102, - 32,97,32,109,111,100,117,108,101,32,105,115,32,97,108,114, - 101,97,100,121,32,105,110,32,115,121,115,46,109,111,100,117, - 108,101,115,44,32,116,104,97,116,32,101,120,105,115,116,105, - 110,103,32,109,111,100,117,108,101,32,103,101,116,115,10,32, - 32,32,32,99,108,111,98,98,101,114,101,100,46,10,10,32, - 32,32,32,78,41,3,114,51,0,0,0,114,17,0,0,0, - 114,160,0,0,0,41,1,114,96,0,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,114,95,0,0,0, - 189,2,0,0,115,4,0,0,0,0,9,12,1,114,95,0, - 0,0,99,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,0,4,0,0,0,64,0,0,0,115,140,0,0,0, - 101,0,90,1,100,0,90,2,100,1,90,3,100,2,90,4, - 101,5,100,3,100,4,132,0,131,1,90,6,101,7,100,20, - 100,6,100,7,132,1,131,1,90,8,101,7,100,21,100,8, - 100,9,132,1,131,1,90,9,101,7,100,10,100,11,132,0, - 131,1,90,10,101,7,100,12,100,13,132,0,131,1,90,11, - 101,7,101,12,100,14,100,15,132,0,131,1,131,1,90,13, - 101,7,101,12,100,16,100,17,132,0,131,1,131,1,90,14, - 101,7,101,12,100,18,100,19,132,0,131,1,131,1,90,15, - 101,7,101,16,131,1,90,17,100,5,83,0,41,22,218,15, - 66,117,105,108,116,105,110,73,109,112,111,114,116,101,114,122, - 144,77,101,116,97,32,112,97,116,104,32,105,109,112,111,114, - 116,32,102,111,114,32,98,117,105,108,116,45,105,110,32,109, - 111,100,117,108,101,115,46,10,10,32,32,32,32,65,108,108, - 32,109,101,116,104,111,100,115,32,97,114,101,32,101,105,116, - 104,101,114,32,99,108,97,115,115,32,111,114,32,115,116,97, - 116,105,99,32,109,101,116,104,111,100,115,32,116,111,32,97, - 118,111,105,100,32,116,104,101,32,110,101,101,100,32,116,111, - 10,32,32,32,32,105,110,115,116,97,110,116,105,97,116,101, - 32,116,104,101,32,99,108,97,115,115,46,10,10,32,32,32, - 32,122,8,98,117,105,108,116,45,105,110,99,1,0,0,0, - 0,0,0,0,0,0,0,0,1,0,0,0,5,0,0,0, - 67,0,0,0,115,22,0,0,0,100,1,124,0,106,0,155, - 2,100,2,116,1,106,2,155,0,100,3,157,5,83,0,41, - 4,250,115,82,101,116,117,114,110,32,114,101,112,114,32,102, - 111,114,32,116,104,101,32,109,111,100,117,108,101,46,10,10, - 32,32,32,32,32,32,32,32,84,104,101,32,109,101,116,104, + 1,161,2,83,0,41,7,122,38,82,101,116,117,114,110,32, + 116,104,101,32,114,101,112,114,32,116,111,32,117,115,101,32, + 102,111,114,32,116,104,101,32,109,111,100,117,108,101,46,78, + 114,115,0,0,0,114,116,0,0,0,114,117,0,0,0,114, + 118,0,0,0,250,18,60,109,111,100,117,108,101,32,123,33, + 114,125,32,40,123,125,41,62,41,5,114,20,0,0,0,114, + 126,0,0,0,114,122,0,0,0,114,50,0,0,0,114,136, + 0,0,0,41,2,114,109,0,0,0,114,20,0,0,0,114, + 5,0,0,0,114,5,0,0,0,114,6,0,0,0,114,119, + 0,0,0,69,2,0,0,115,16,0,0,0,20,3,10,1, + 10,1,10,1,14,2,6,2,14,1,16,2,114,119,0,0, + 0,99,2,0,0,0,0,0,0,0,0,0,0,0,4,0, + 0,0,10,0,0,0,67,0,0,0,115,24,1,0,0,124, + 0,106,0,125,2,116,1,124,2,131,1,143,123,1,0,116, + 2,106,3,160,4,124,2,161,1,124,1,117,1,114,27,100, + 1,160,5,124,2,161,1,125,3,116,6,124,3,124,2,100, + 2,141,2,130,1,122,80,124,0,106,7,100,3,117,0,114, + 53,124,0,106,8,100,3,117,0,114,45,116,6,100,4,124, + 0,106,0,100,2,141,2,130,1,116,9,124,0,124,1,100, + 5,100,6,141,3,1,0,110,40,116,9,124,0,124,1,100, + 5,100,6,141,3,1,0,116,10,124,0,106,7,100,7,131, + 2,115,87,116,11,124,0,106,7,131,1,155,0,100,8,157, + 2,125,3,116,12,160,13,124,3,116,14,161,2,1,0,124, + 0,106,7,160,15,124,2,161,1,1,0,110,6,124,0,106, + 7,160,16,124,1,161,1,1,0,87,0,116,2,106,3,160, + 17,124,0,106,0,161,1,125,1,124,1,116,2,106,3,124, + 0,106,0,60,0,110,14,116,2,106,3,160,17,124,0,106, + 0,161,1,125,1,124,1,116,2,106,3,124,0,106,0,60, + 0,119,0,87,0,100,3,4,0,4,0,131,3,1,0,124, + 1,83,0,49,0,115,133,119,1,1,0,1,0,1,0,89, + 0,1,0,124,1,83,0,41,9,122,70,69,120,101,99,117, + 116,101,32,116,104,101,32,115,112,101,99,39,115,32,115,112, + 101,99,105,102,105,101,100,32,109,111,100,117,108,101,32,105, + 110,32,97,110,32,101,120,105,115,116,105,110,103,32,109,111, + 100,117,108,101,39,115,32,110,97,109,101,115,112,97,99,101, + 46,122,30,109,111,100,117,108,101,32,123,33,114,125,32,110, + 111,116,32,105,110,32,115,121,115,46,109,111,100,117,108,101, + 115,114,19,0,0,0,78,250,14,109,105,115,115,105,110,103, + 32,108,111,97,100,101,114,84,114,156,0,0,0,114,163,0, + 0,0,250,55,46,101,120,101,99,95,109,111,100,117,108,101, + 40,41,32,110,111,116,32,102,111,117,110,100,59,32,102,97, + 108,108,105,110,103,32,98,97,99,107,32,116,111,32,108,111, + 97,100,95,109,111,100,117,108,101,40,41,41,18,114,20,0, + 0,0,114,57,0,0,0,114,18,0,0,0,114,105,0,0, + 0,114,38,0,0,0,114,50,0,0,0,114,87,0,0,0, + 114,122,0,0,0,114,129,0,0,0,114,161,0,0,0,114, + 11,0,0,0,114,7,0,0,0,114,101,0,0,0,114,102, + 0,0,0,218,13,73,109,112,111,114,116,87,97,114,110,105, + 110,103,218,11,108,111,97,100,95,109,111,100,117,108,101,114, + 163,0,0,0,218,3,112,111,112,41,4,114,109,0,0,0, + 114,110,0,0,0,114,20,0,0,0,114,108,0,0,0,114, + 5,0,0,0,114,5,0,0,0,114,6,0,0,0,114,106, + 0,0,0,86,2,0,0,115,50,0,0,0,6,2,10,1, + 16,1,10,1,12,1,2,1,10,1,10,1,14,1,16,2, + 14,2,12,1,16,1,12,2,14,1,12,2,2,128,14,4, + 14,1,14,255,16,1,10,233,4,24,16,232,4,24,114,106, + 0,0,0,99,1,0,0,0,0,0,0,0,0,0,0,0, + 2,0,0,0,8,0,0,0,67,0,0,0,115,14,1,0, + 0,122,9,124,0,106,0,160,1,124,0,106,2,161,1,1, + 0,87,0,110,23,1,0,1,0,1,0,124,0,106,2,116, + 3,106,4,118,0,114,32,116,3,106,4,160,5,124,0,106, + 2,161,1,125,1,124,1,116,3,106,4,124,0,106,2,60, + 0,130,0,116,3,106,4,160,5,124,0,106,2,161,1,125, + 1,124,1,116,3,106,4,124,0,106,2,60,0,116,6,124, + 1,100,1,100,0,131,3,100,0,117,0,114,70,122,6,124, + 0,106,0,124,1,95,7,87,0,110,9,4,0,116,8,121, + 69,1,0,1,0,1,0,89,0,110,1,119,0,116,6,124, + 1,100,2,100,0,131,3,100,0,117,0,114,108,122,20,124, + 1,106,9,124,1,95,10,116,11,124,1,100,3,131,2,115, + 97,124,0,106,2,160,12,100,4,161,1,100,5,25,0,124, + 1,95,10,87,0,110,9,4,0,116,8,121,107,1,0,1, + 0,1,0,89,0,110,1,119,0,116,6,124,1,100,6,100, + 0,131,3,100,0,117,0,114,133,122,6,124,0,124,1,95, + 13,87,0,124,1,83,0,4,0,116,8,121,132,1,0,1, + 0,1,0,89,0,124,1,83,0,119,0,124,1,83,0,41, + 7,78,114,112,0,0,0,114,158,0,0,0,114,154,0,0, + 0,114,141,0,0,0,114,25,0,0,0,114,113,0,0,0, + 41,14,114,122,0,0,0,114,170,0,0,0,114,20,0,0, + 0,114,18,0,0,0,114,105,0,0,0,114,171,0,0,0, + 114,13,0,0,0,114,112,0,0,0,114,2,0,0,0,114, + 9,0,0,0,114,158,0,0,0,114,11,0,0,0,114,142, + 0,0,0,114,113,0,0,0,114,164,0,0,0,114,5,0, + 0,0,114,5,0,0,0,114,6,0,0,0,218,25,95,108, + 111,97,100,95,98,97,99,107,119,97,114,100,95,99,111,109, + 112,97,116,105,98,108,101,116,2,0,0,115,66,0,0,0, + 2,3,18,1,6,1,12,1,14,1,12,1,2,1,14,3, + 12,1,16,1,2,1,12,1,12,1,4,1,2,255,16,2, + 2,1,8,4,10,1,18,1,4,128,12,1,4,1,2,255, + 16,2,2,1,8,1,4,3,12,254,2,1,4,1,2,254, + 4,2,114,172,0,0,0,99,1,0,0,0,0,0,0,0, + 0,0,0,0,3,0,0,0,11,0,0,0,67,0,0,0, + 115,242,0,0,0,124,0,106,0,100,0,117,1,114,29,116, + 1,124,0,106,0,100,1,131,2,115,29,116,2,124,0,106, + 0,131,1,155,0,100,2,157,2,125,1,116,3,160,4,124, + 1,116,5,161,2,1,0,116,6,124,0,131,1,83,0,116, + 7,124,0,131,1,125,2,100,3,124,0,95,8,122,80,124, + 2,116,9,106,10,124,0,106,11,60,0,122,26,124,0,106, + 0,100,0,117,0,114,62,124,0,106,12,100,0,117,0,114, + 61,116,13,100,4,124,0,106,11,100,5,141,2,130,1,110, + 6,124,0,106,0,160,14,124,2,161,1,1,0,87,0,110, + 20,1,0,1,0,1,0,122,7,116,9,106,10,124,0,106, + 11,61,0,87,0,130,0,4,0,116,15,121,89,1,0,1, + 0,1,0,89,0,130,0,119,0,116,9,106,10,160,16,124, + 0,106,11,161,1,125,2,124,2,116,9,106,10,124,0,106, + 11,60,0,116,17,100,6,124,0,106,11,124,0,106,0,131, + 3,1,0,87,0,100,7,124,0,95,8,124,2,83,0,100, + 7,124,0,95,8,119,0,41,8,78,114,163,0,0,0,114, + 168,0,0,0,84,114,167,0,0,0,114,19,0,0,0,122, + 18,105,109,112,111,114,116,32,123,33,114,125,32,35,32,123, + 33,114,125,70,41,18,114,122,0,0,0,114,11,0,0,0, + 114,7,0,0,0,114,101,0,0,0,114,102,0,0,0,114, + 169,0,0,0,114,172,0,0,0,114,165,0,0,0,90,13, + 95,105,110,105,116,105,97,108,105,122,105,110,103,114,18,0, + 0,0,114,105,0,0,0,114,20,0,0,0,114,129,0,0, + 0,114,87,0,0,0,114,163,0,0,0,114,70,0,0,0, + 114,171,0,0,0,114,83,0,0,0,41,3,114,109,0,0, + 0,114,108,0,0,0,114,110,0,0,0,114,5,0,0,0, + 114,5,0,0,0,114,6,0,0,0,218,14,95,108,111,97, + 100,95,117,110,108,111,99,107,101,100,152,2,0,0,115,60, + 0,0,0,10,2,12,2,16,1,12,2,8,1,8,2,6, + 5,2,1,12,1,2,1,10,1,10,1,14,1,2,255,12, + 4,4,128,6,1,2,1,12,1,2,3,12,254,2,1,2, + 1,2,254,14,7,12,1,18,1,6,2,4,2,8,254,114, + 173,0,0,0,99,1,0,0,0,0,0,0,0,0,0,0, + 0,1,0,0,0,8,0,0,0,67,0,0,0,115,54,0, + 0,0,116,0,124,0,106,1,131,1,143,12,1,0,116,2, + 124,0,131,1,87,0,2,0,100,1,4,0,4,0,131,3, + 1,0,83,0,49,0,115,20,119,1,1,0,1,0,1,0, + 89,0,1,0,100,1,83,0,41,2,122,191,82,101,116,117, + 114,110,32,97,32,110,101,119,32,109,111,100,117,108,101,32, + 111,98,106,101,99,116,44,32,108,111,97,100,101,100,32,98, + 121,32,116,104,101,32,115,112,101,99,39,115,32,108,111,97, + 100,101,114,46,10,10,32,32,32,32,84,104,101,32,109,111, + 100,117,108,101,32,105,115,32,110,111,116,32,97,100,100,101, + 100,32,116,111,32,105,116,115,32,112,97,114,101,110,116,46, + 10,10,32,32,32,32,73,102,32,97,32,109,111,100,117,108, + 101,32,105,115,32,97,108,114,101,97,100,121,32,105,110,32, + 115,121,115,46,109,111,100,117,108,101,115,44,32,116,104,97, + 116,32,101,120,105,115,116,105,110,103,32,109,111,100,117,108, + 101,32,103,101,116,115,10,32,32,32,32,99,108,111,98,98, + 101,114,101,100,46,10,10,32,32,32,32,78,41,3,114,57, + 0,0,0,114,20,0,0,0,114,173,0,0,0,169,1,114, + 109,0,0,0,114,5,0,0,0,114,5,0,0,0,114,6, + 0,0,0,114,107,0,0,0,197,2,0,0,115,6,0,0, + 0,12,9,6,1,36,255,114,107,0,0,0,99,0,0,0, + 0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,0, + 0,64,0,0,0,115,140,0,0,0,101,0,90,1,100,0, + 90,2,100,1,90,3,100,2,90,4,101,5,100,3,100,4, + 132,0,131,1,90,6,101,7,100,20,100,6,100,7,132,1, + 131,1,90,8,101,7,100,21,100,8,100,9,132,1,131,1, + 90,9,101,5,100,10,100,11,132,0,131,1,90,10,101,5, + 100,12,100,13,132,0,131,1,90,11,101,7,101,12,100,14, + 100,15,132,0,131,1,131,1,90,13,101,7,101,12,100,16, + 100,17,132,0,131,1,131,1,90,14,101,7,101,12,100,18, + 100,19,132,0,131,1,131,1,90,15,101,7,101,16,131,1, + 90,17,100,5,83,0,41,22,218,15,66,117,105,108,116,105, + 110,73,109,112,111,114,116,101,114,122,144,77,101,116,97,32, + 112,97,116,104,32,105,109,112,111,114,116,32,102,111,114,32, + 98,117,105,108,116,45,105,110,32,109,111,100,117,108,101,115, + 46,10,10,32,32,32,32,65,108,108,32,109,101,116,104,111, + 100,115,32,97,114,101,32,101,105,116,104,101,114,32,99,108, + 97,115,115,32,111,114,32,115,116,97,116,105,99,32,109,101, + 116,104,111,100,115,32,116,111,32,97,118,111,105,100,32,116, + 104,101,32,110,101,101,100,32,116,111,10,32,32,32,32,105, + 110,115,116,97,110,116,105,97,116,101,32,116,104,101,32,99, + 108,97,115,115,46,10,10,32,32,32,32,122,8,98,117,105, + 108,116,45,105,110,99,1,0,0,0,0,0,0,0,0,0, + 0,0,1,0,0,0,5,0,0,0,67,0,0,0,115,34, + 0,0,0,116,0,160,1,100,1,116,2,161,2,1,0,100, + 2,124,0,106,3,155,2,100,3,116,4,106,5,155,0,100, + 4,157,5,83,0,41,5,250,115,82,101,116,117,114,110,32, + 114,101,112,114,32,102,111,114,32,116,104,101,32,109,111,100, + 117,108,101,46,10,10,32,32,32,32,32,32,32,32,84,104, + 101,32,109,101,116,104,111,100,32,105,115,32,100,101,112,114, + 101,99,97,116,101,100,46,32,32,84,104,101,32,105,109,112, + 111,114,116,32,109,97,99,104,105,110,101,114,121,32,100,111, + 101,115,32,116,104,101,32,106,111,98,32,105,116,115,101,108, + 102,46,10,10,32,32,32,32,32,32,32,32,122,81,66,117, + 105,108,116,105,110,73,109,112,111,114,116,101,114,46,109,111, + 100,117,108,101,95,114,101,112,114,40,41,32,105,115,32,100, + 101,112,114,101,99,97,116,101,100,32,97,110,100,32,115,108, + 97,116,101,100,32,102,111,114,32,114,101,109,111,118,97,108, + 32,105,110,32,80,121,116,104,111,110,32,51,46,49,50,122, + 8,60,109,111,100,117,108,101,32,122,2,32,40,122,2,41, + 62,41,6,114,101,0,0,0,114,102,0,0,0,114,103,0, + 0,0,114,9,0,0,0,114,175,0,0,0,114,151,0,0, + 0,169,1,114,110,0,0,0,114,5,0,0,0,114,5,0, + 0,0,114,6,0,0,0,114,114,0,0,0,223,2,0,0, + 115,8,0,0,0,6,7,2,1,4,255,22,2,122,27,66, + 117,105,108,116,105,110,73,109,112,111,114,116,101,114,46,109, + 111,100,117,108,101,95,114,101,112,114,78,99,4,0,0,0, + 0,0,0,0,0,0,0,0,4,0,0,0,5,0,0,0, + 67,0,0,0,115,42,0,0,0,124,2,100,0,117,1,114, + 6,100,0,83,0,116,0,160,1,124,1,161,1,114,19,116, + 2,124,1,124,0,124,0,106,3,100,1,141,3,83,0,100, + 0,83,0,169,2,78,114,150,0,0,0,41,4,114,64,0, + 0,0,90,10,105,115,95,98,117,105,108,116,105,110,114,104, + 0,0,0,114,151,0,0,0,169,4,218,3,99,108,115,114, + 89,0,0,0,218,4,112,97,116,104,218,6,116,97,114,103, + 101,116,114,5,0,0,0,114,5,0,0,0,114,6,0,0, + 0,218,9,102,105,110,100,95,115,112,101,99,234,2,0,0, + 115,10,0,0,0,8,2,4,1,10,1,16,1,4,2,122, + 25,66,117,105,108,116,105,110,73,109,112,111,114,116,101,114, + 46,102,105,110,100,95,115,112,101,99,99,3,0,0,0,0, + 0,0,0,0,0,0,0,4,0,0,0,4,0,0,0,67, + 0,0,0,115,42,0,0,0,116,0,160,1,100,1,116,2, + 161,2,1,0,124,0,160,3,124,1,124,2,161,2,125,3, + 124,3,100,2,117,1,114,19,124,3,106,4,83,0,100,2, + 83,0,41,3,122,175,70,105,110,100,32,116,104,101,32,98, + 117,105,108,116,45,105,110,32,109,111,100,117,108,101,46,10, + 10,32,32,32,32,32,32,32,32,73,102,32,39,112,97,116, + 104,39,32,105,115,32,101,118,101,114,32,115,112,101,99,105, + 102,105,101,100,32,116,104,101,110,32,116,104,101,32,115,101, + 97,114,99,104,32,105,115,32,99,111,110,115,105,100,101,114, + 101,100,32,97,32,102,97,105,108,117,114,101,46,10,10,32, + 32,32,32,32,32,32,32,84,104,105,115,32,109,101,116,104, 111,100,32,105,115,32,100,101,112,114,101,99,97,116,101,100, - 46,32,32,84,104,101,32,105,109,112,111,114,116,32,109,97, - 99,104,105,110,101,114,121,32,100,111,101,115,32,116,104,101, - 32,106,111,98,32,105,116,115,101,108,102,46,10,10,32,32, - 32,32,32,32,32,32,122,8,60,109,111,100,117,108,101,32, - 122,2,32,40,122,2,41,62,41,3,114,1,0,0,0,114, - 161,0,0,0,114,139,0,0,0,41,1,114,97,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,114, - 100,0,0,0,215,2,0,0,115,2,0,0,0,0,7,122, - 27,66,117,105,108,116,105,110,73,109,112,111,114,116,101,114, - 46,109,111,100,117,108,101,95,114,101,112,114,78,99,4,0, - 0,0,0,0,0,0,0,0,0,0,4,0,0,0,5,0, - 0,0,67,0,0,0,115,46,0,0,0,124,2,100,0,117, - 1,114,12,100,0,83,0,116,0,160,1,124,1,161,1,114, - 38,116,2,124,1,124,0,124,0,106,3,100,1,141,3,83, - 0,100,0,83,0,100,0,83,0,169,2,78,114,138,0,0, - 0,41,4,114,58,0,0,0,90,10,105,115,95,98,117,105, - 108,116,105,110,114,92,0,0,0,114,139,0,0,0,169,4, - 218,3,99,108,115,114,82,0,0,0,218,4,112,97,116,104, - 218,6,116,97,114,103,101,116,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,9,102,105,110,100,95,115,112, - 101,99,224,2,0,0,115,10,0,0,0,0,2,8,1,4, - 1,10,1,16,2,122,25,66,117,105,108,116,105,110,73,109, - 112,111,114,116,101,114,46,102,105,110,100,95,115,112,101,99, - 99,3,0,0,0,0,0,0,0,0,0,0,0,4,0,0, - 0,4,0,0,0,67,0,0,0,115,30,0,0,0,124,0, - 160,0,124,1,124,2,161,2,125,3,124,3,100,1,117,1, - 114,26,124,3,106,1,83,0,100,1,83,0,41,2,122,175, - 70,105,110,100,32,116,104,101,32,98,117,105,108,116,45,105, - 110,32,109,111,100,117,108,101,46,10,10,32,32,32,32,32, - 32,32,32,73,102,32,39,112,97,116,104,39,32,105,115,32, - 101,118,101,114,32,115,112,101,99,105,102,105,101,100,32,116, - 104,101,110,32,116,104,101,32,115,101,97,114,99,104,32,105, - 115,32,99,111,110,115,105,100,101,114,101,100,32,97,32,102, - 97,105,108,117,114,101,46,10,10,32,32,32,32,32,32,32, - 32,84,104,105,115,32,109,101,116,104,111,100,32,105,115,32, - 100,101,112,114,101,99,97,116,101,100,46,32,32,85,115,101, - 32,102,105,110,100,95,115,112,101,99,40,41,32,105,110,115, - 116,101,97,100,46,10,10,32,32,32,32,32,32,32,32,78, - 41,2,114,168,0,0,0,114,110,0,0,0,41,4,114,165, - 0,0,0,114,82,0,0,0,114,166,0,0,0,114,96,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,218,11,102,105,110,100,95,109,111,100,117,108,101,233,2, - 0,0,115,4,0,0,0,0,9,12,1,122,27,66,117,105, - 108,116,105,110,73,109,112,111,114,116,101,114,46,102,105,110, - 100,95,109,111,100,117,108,101,99,2,0,0,0,0,0,0, - 0,0,0,0,0,2,0,0,0,4,0,0,0,67,0,0, - 0,115,46,0,0,0,124,1,106,0,116,1,106,2,118,1, - 114,34,116,3,100,1,160,4,124,1,106,0,161,1,124,1, - 106,0,100,2,141,2,130,1,116,5,116,6,106,7,124,1, - 131,2,83,0,41,3,122,24,67,114,101,97,116,101,32,97, - 32,98,117,105,108,116,45,105,110,32,109,111,100,117,108,101, - 114,78,0,0,0,114,16,0,0,0,41,8,114,17,0,0, - 0,114,15,0,0,0,114,79,0,0,0,114,80,0,0,0, - 114,46,0,0,0,114,68,0,0,0,114,58,0,0,0,90, - 14,99,114,101,97,116,101,95,98,117,105,108,116,105,110,41, - 2,114,30,0,0,0,114,96,0,0,0,114,10,0,0,0, - 114,10,0,0,0,114,11,0,0,0,114,150,0,0,0,245, - 2,0,0,115,10,0,0,0,0,3,12,1,12,1,4,255, - 6,2,122,29,66,117,105,108,116,105,110,73,109,112,111,114, + 46,32,32,85,115,101,32,102,105,110,100,95,115,112,101,99, + 40,41,32,105,110,115,116,101,97,100,46,10,10,32,32,32, + 32,32,32,32,32,122,106,66,117,105,108,116,105,110,73,109, + 112,111,114,116,101,114,46,102,105,110,100,95,109,111,100,117, + 108,101,40,41,32,105,115,32,100,101,112,114,101,99,97,116, + 101,100,32,97,110,100,32,115,108,97,116,101,100,32,102,111, + 114,32,114,101,109,111,118,97,108,32,105,110,32,80,121,116, + 104,111,110,32,51,46,49,50,59,32,117,115,101,32,102,105, + 110,100,95,115,112,101,99,40,41,32,105,110,115,116,101,97, + 100,78,41,5,114,101,0,0,0,114,102,0,0,0,114,103, + 0,0,0,114,183,0,0,0,114,122,0,0,0,41,4,114, + 180,0,0,0,114,89,0,0,0,114,181,0,0,0,114,109, + 0,0,0,114,5,0,0,0,114,5,0,0,0,114,6,0, + 0,0,218,11,102,105,110,100,95,109,111,100,117,108,101,243, + 2,0,0,115,10,0,0,0,6,9,2,2,4,254,12,3, + 18,1,122,27,66,117,105,108,116,105,110,73,109,112,111,114, + 116,101,114,46,102,105,110,100,95,109,111,100,117,108,101,99, + 1,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0, + 4,0,0,0,67,0,0,0,115,46,0,0,0,124,0,106, + 0,116,1,106,2,118,1,114,17,116,3,100,1,160,4,124, + 0,106,0,161,1,124,0,106,0,100,2,141,2,130,1,116, + 5,116,6,106,7,124,0,131,2,83,0,41,3,122,24,67, + 114,101,97,116,101,32,97,32,98,117,105,108,116,45,105,110, + 32,109,111,100,117,108,101,114,85,0,0,0,114,19,0,0, + 0,41,8,114,20,0,0,0,114,18,0,0,0,114,86,0, + 0,0,114,87,0,0,0,114,50,0,0,0,114,74,0,0, + 0,114,64,0,0,0,90,14,99,114,101,97,116,101,95,98, + 117,105,108,116,105,110,114,174,0,0,0,114,5,0,0,0, + 114,5,0,0,0,114,6,0,0,0,114,162,0,0,0,2, + 3,0,0,115,10,0,0,0,12,3,12,1,4,1,6,255, + 12,2,122,29,66,117,105,108,116,105,110,73,109,112,111,114, 116,101,114,46,99,114,101,97,116,101,95,109,111,100,117,108, - 101,99,2,0,0,0,0,0,0,0,0,0,0,0,2,0, + 101,99,1,0,0,0,0,0,0,0,0,0,0,0,1,0, 0,0,3,0,0,0,67,0,0,0,115,16,0,0,0,116, - 0,116,1,106,2,124,1,131,2,1,0,100,1,83,0,41, + 0,116,1,106,2,124,0,131,2,1,0,100,1,83,0,41, 2,122,22,69,120,101,99,32,97,32,98,117,105,108,116,45, - 105,110,32,109,111,100,117,108,101,78,41,3,114,68,0,0, - 0,114,58,0,0,0,90,12,101,120,101,99,95,98,117,105, - 108,116,105,110,41,2,114,30,0,0,0,114,97,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,114, - 151,0,0,0,253,2,0,0,115,2,0,0,0,0,3,122, - 27,66,117,105,108,116,105,110,73,109,112,111,114,116,101,114, - 46,101,120,101,99,95,109,111,100,117,108,101,99,2,0,0, - 0,0,0,0,0,0,0,0,0,2,0,0,0,1,0,0, - 0,67,0,0,0,115,4,0,0,0,100,1,83,0,41,2, - 122,57,82,101,116,117,114,110,32,78,111,110,101,32,97,115, - 32,98,117,105,108,116,45,105,110,32,109,111,100,117,108,101, - 115,32,100,111,32,110,111,116,32,104,97,118,101,32,99,111, - 100,101,32,111,98,106,101,99,116,115,46,78,114,10,0,0, - 0,169,2,114,165,0,0,0,114,82,0,0,0,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,218,8,103,101, - 116,95,99,111,100,101,2,3,0,0,115,2,0,0,0,0, - 4,122,24,66,117,105,108,116,105,110,73,109,112,111,114,116, - 101,114,46,103,101,116,95,99,111,100,101,99,2,0,0,0, - 0,0,0,0,0,0,0,0,2,0,0,0,1,0,0,0, - 67,0,0,0,115,4,0,0,0,100,1,83,0,41,2,122, - 56,82,101,116,117,114,110,32,78,111,110,101,32,97,115,32, - 98,117,105,108,116,45,105,110,32,109,111,100,117,108,101,115, - 32,100,111,32,110,111,116,32,104,97,118,101,32,115,111,117, - 114,99,101,32,99,111,100,101,46,78,114,10,0,0,0,114, - 170,0,0,0,114,10,0,0,0,114,10,0,0,0,114,11, - 0,0,0,218,10,103,101,116,95,115,111,117,114,99,101,8, - 3,0,0,115,2,0,0,0,0,4,122,26,66,117,105,108, + 105,110,32,109,111,100,117,108,101,78,41,3,114,74,0,0, + 0,114,64,0,0,0,90,12,101,120,101,99,95,98,117,105, + 108,116,105,110,114,177,0,0,0,114,5,0,0,0,114,5, + 0,0,0,114,6,0,0,0,114,163,0,0,0,10,3,0, + 0,115,2,0,0,0,16,3,122,27,66,117,105,108,116,105, + 110,73,109,112,111,114,116,101,114,46,101,120,101,99,95,109, + 111,100,117,108,101,99,2,0,0,0,0,0,0,0,0,0, + 0,0,2,0,0,0,1,0,0,0,67,0,0,0,243,4, + 0,0,0,100,1,83,0,41,2,122,57,82,101,116,117,114, + 110,32,78,111,110,101,32,97,115,32,98,117,105,108,116,45, + 105,110,32,109,111,100,117,108,101,115,32,100,111,32,110,111, + 116,32,104,97,118,101,32,99,111,100,101,32,111,98,106,101, + 99,116,115,46,78,114,5,0,0,0,169,2,114,180,0,0, + 0,114,89,0,0,0,114,5,0,0,0,114,5,0,0,0, + 114,6,0,0,0,218,8,103,101,116,95,99,111,100,101,15, + 3,0,0,243,2,0,0,0,4,4,122,24,66,117,105,108, 116,105,110,73,109,112,111,114,116,101,114,46,103,101,116,95, - 115,111,117,114,99,101,99,2,0,0,0,0,0,0,0,0, - 0,0,0,2,0,0,0,1,0,0,0,67,0,0,0,115, - 4,0,0,0,100,1,83,0,41,2,122,52,82,101,116,117, - 114,110,32,70,97,108,115,101,32,97,115,32,98,117,105,108, - 116,45,105,110,32,109,111,100,117,108,101,115,32,97,114,101, - 32,110,101,118,101,114,32,112,97,99,107,97,103,101,115,46, - 70,114,10,0,0,0,114,170,0,0,0,114,10,0,0,0, - 114,10,0,0,0,114,11,0,0,0,114,116,0,0,0,14, - 3,0,0,115,2,0,0,0,0,4,122,26,66,117,105,108, - 116,105,110,73,109,112,111,114,116,101,114,46,105,115,95,112, - 97,99,107,97,103,101,41,2,78,78,41,1,78,41,18,114, - 1,0,0,0,114,0,0,0,0,114,2,0,0,0,114,3, - 0,0,0,114,139,0,0,0,218,12,115,116,97,116,105,99, - 109,101,116,104,111,100,114,100,0,0,0,218,11,99,108,97, - 115,115,109,101,116,104,111,100,114,168,0,0,0,114,169,0, - 0,0,114,150,0,0,0,114,151,0,0,0,114,87,0,0, - 0,114,171,0,0,0,114,172,0,0,0,114,116,0,0,0, - 114,98,0,0,0,114,156,0,0,0,114,10,0,0,0,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,114,161, - 0,0,0,204,2,0,0,115,44,0,0,0,8,2,4,7, - 4,2,2,1,10,8,2,1,12,8,2,1,12,11,2,1, - 10,7,2,1,10,4,2,1,2,1,12,4,2,1,2,1, - 12,4,2,1,2,1,12,4,114,161,0,0,0,99,0,0, - 0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0, - 0,0,64,0,0,0,115,144,0,0,0,101,0,90,1,100, - 0,90,2,100,1,90,3,100,2,90,4,101,5,100,3,100, - 4,132,0,131,1,90,6,101,7,100,22,100,6,100,7,132, - 1,131,1,90,8,101,7,100,23,100,8,100,9,132,1,131, - 1,90,9,101,7,100,10,100,11,132,0,131,1,90,10,101, - 5,100,12,100,13,132,0,131,1,90,11,101,7,100,14,100, - 15,132,0,131,1,90,12,101,7,101,13,100,16,100,17,132, - 0,131,1,131,1,90,14,101,7,101,13,100,18,100,19,132, - 0,131,1,131,1,90,15,101,7,101,13,100,20,100,21,132, - 0,131,1,131,1,90,16,100,5,83,0,41,24,218,14,70, - 114,111,122,101,110,73,109,112,111,114,116,101,114,122,142,77, - 101,116,97,32,112,97,116,104,32,105,109,112,111,114,116,32, - 102,111,114,32,102,114,111,122,101,110,32,109,111,100,117,108, - 101,115,46,10,10,32,32,32,32,65,108,108,32,109,101,116, - 104,111,100,115,32,97,114,101,32,101,105,116,104,101,114,32, - 99,108,97,115,115,32,111,114,32,115,116,97,116,105,99,32, - 109,101,116,104,111,100,115,32,116,111,32,97,118,111,105,100, - 32,116,104,101,32,110,101,101,100,32,116,111,10,32,32,32, - 32,105,110,115,116,97,110,116,105,97,116,101,32,116,104,101, - 32,99,108,97,115,115,46,10,10,32,32,32,32,90,6,102, - 114,111,122,101,110,99,1,0,0,0,0,0,0,0,0,0, - 0,0,1,0,0,0,4,0,0,0,67,0,0,0,115,16, - 0,0,0,100,1,160,0,124,0,106,1,116,2,106,3,161, - 2,83,0,41,2,114,162,0,0,0,114,154,0,0,0,41, - 4,114,46,0,0,0,114,1,0,0,0,114,175,0,0,0, - 114,139,0,0,0,41,1,218,1,109,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,114,100,0,0,0,34,3, - 0,0,115,2,0,0,0,0,7,122,26,70,114,111,122,101, - 110,73,109,112,111,114,116,101,114,46,109,111,100,117,108,101, - 95,114,101,112,114,78,99,4,0,0,0,0,0,0,0,0, - 0,0,0,4,0,0,0,5,0,0,0,67,0,0,0,115, - 34,0,0,0,116,0,160,1,124,1,161,1,114,26,116,2, - 124,1,124,0,124,0,106,3,100,1,141,3,83,0,100,0, - 83,0,100,0,83,0,114,163,0,0,0,41,4,114,58,0, - 0,0,114,89,0,0,0,114,92,0,0,0,114,139,0,0, - 0,114,164,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,168,0,0,0,43,3,0,0,115,6, - 0,0,0,0,2,10,1,16,2,122,24,70,114,111,122,101, + 99,111,100,101,99,2,0,0,0,0,0,0,0,0,0,0, + 0,2,0,0,0,1,0,0,0,67,0,0,0,114,185,0, + 0,0,41,2,122,56,82,101,116,117,114,110,32,78,111,110, + 101,32,97,115,32,98,117,105,108,116,45,105,110,32,109,111, + 100,117,108,101,115,32,100,111,32,110,111,116,32,104,97,118, + 101,32,115,111,117,114,99,101,32,99,111,100,101,46,78,114, + 5,0,0,0,114,186,0,0,0,114,5,0,0,0,114,5, + 0,0,0,114,6,0,0,0,218,10,103,101,116,95,115,111, + 117,114,99,101,21,3,0,0,114,188,0,0,0,122,26,66, + 117,105,108,116,105,110,73,109,112,111,114,116,101,114,46,103, + 101,116,95,115,111,117,114,99,101,99,2,0,0,0,0,0, + 0,0,0,0,0,0,2,0,0,0,1,0,0,0,67,0, + 0,0,114,185,0,0,0,41,2,122,52,82,101,116,117,114, + 110,32,70,97,108,115,101,32,97,115,32,98,117,105,108,116, + 45,105,110,32,109,111,100,117,108,101,115,32,97,114,101,32, + 110,101,118,101,114,32,112,97,99,107,97,103,101,115,46,70, + 114,5,0,0,0,114,186,0,0,0,114,5,0,0,0,114, + 5,0,0,0,114,6,0,0,0,114,128,0,0,0,27,3, + 0,0,114,188,0,0,0,122,26,66,117,105,108,116,105,110, + 73,109,112,111,114,116,101,114,46,105,115,95,112,97,99,107, + 97,103,101,169,2,78,78,114,0,0,0,0,41,18,114,9, + 0,0,0,114,8,0,0,0,114,1,0,0,0,114,10,0, + 0,0,114,151,0,0,0,218,12,115,116,97,116,105,99,109, + 101,116,104,111,100,114,114,0,0,0,218,11,99,108,97,115, + 115,109,101,116,104,111,100,114,183,0,0,0,114,184,0,0, + 0,114,162,0,0,0,114,163,0,0,0,114,95,0,0,0, + 114,187,0,0,0,114,189,0,0,0,114,128,0,0,0,114, + 111,0,0,0,114,170,0,0,0,114,5,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,6,0,0,0,114,175,0, + 0,0,212,2,0,0,115,46,0,0,0,8,0,4,2,4, + 7,2,2,10,1,2,10,12,1,2,8,12,1,2,14,10, + 1,2,7,10,1,2,4,2,1,12,1,2,4,2,1,12, + 1,2,4,2,1,12,1,12,4,114,175,0,0,0,99,0, + 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, + 0,0,0,64,0,0,0,115,144,0,0,0,101,0,90,1, + 100,0,90,2,100,1,90,3,100,2,90,4,101,5,100,3, + 100,4,132,0,131,1,90,6,101,7,100,22,100,6,100,7, + 132,1,131,1,90,8,101,7,100,23,100,8,100,9,132,1, + 131,1,90,9,101,5,100,10,100,11,132,0,131,1,90,10, + 101,5,100,12,100,13,132,0,131,1,90,11,101,7,100,14, + 100,15,132,0,131,1,90,12,101,7,101,13,100,16,100,17, + 132,0,131,1,131,1,90,14,101,7,101,13,100,18,100,19, + 132,0,131,1,131,1,90,15,101,7,101,13,100,20,100,21, + 132,0,131,1,131,1,90,16,100,5,83,0,41,24,218,14, + 70,114,111,122,101,110,73,109,112,111,114,116,101,114,122,142, + 77,101,116,97,32,112,97,116,104,32,105,109,112,111,114,116, + 32,102,111,114,32,102,114,111,122,101,110,32,109,111,100,117, + 108,101,115,46,10,10,32,32,32,32,65,108,108,32,109,101, + 116,104,111,100,115,32,97,114,101,32,101,105,116,104,101,114, + 32,99,108,97,115,115,32,111,114,32,115,116,97,116,105,99, + 32,109,101,116,104,111,100,115,32,116,111,32,97,118,111,105, + 100,32,116,104,101,32,110,101,101,100,32,116,111,10,32,32, + 32,32,105,110,115,116,97,110,116,105,97,116,101,32,116,104, + 101,32,99,108,97,115,115,46,10,10,32,32,32,32,90,6, + 102,114,111,122,101,110,99,1,0,0,0,0,0,0,0,0, + 0,0,0,1,0,0,0,4,0,0,0,67,0,0,0,115, + 28,0,0,0,116,0,160,1,100,1,116,2,161,2,1,0, + 100,2,160,3,124,0,106,4,116,5,106,6,161,2,83,0, + 41,3,114,176,0,0,0,122,80,70,114,111,122,101,110,73, + 109,112,111,114,116,101,114,46,109,111,100,117,108,101,95,114, + 101,112,114,40,41,32,105,115,32,100,101,112,114,101,99,97, + 116,101,100,32,97,110,100,32,115,108,97,116,101,100,32,102, + 111,114,32,114,101,109,111,118,97,108,32,105,110,32,80,121, + 116,104,111,110,32,51,46,49,50,114,166,0,0,0,41,7, + 114,101,0,0,0,114,102,0,0,0,114,103,0,0,0,114, + 50,0,0,0,114,9,0,0,0,114,193,0,0,0,114,151, + 0,0,0,41,1,218,1,109,114,5,0,0,0,114,5,0, + 0,0,114,6,0,0,0,114,114,0,0,0,47,3,0,0, + 115,8,0,0,0,6,7,2,1,4,255,16,2,122,26,70, + 114,111,122,101,110,73,109,112,111,114,116,101,114,46,109,111, + 100,117,108,101,95,114,101,112,114,78,99,4,0,0,0,0, + 0,0,0,0,0,0,0,4,0,0,0,5,0,0,0,67, + 0,0,0,115,30,0,0,0,116,0,160,1,124,1,161,1, + 114,13,116,2,124,1,124,0,124,0,106,3,100,1,141,3, + 83,0,100,0,83,0,114,178,0,0,0,41,4,114,64,0, + 0,0,114,98,0,0,0,114,104,0,0,0,114,151,0,0, + 0,114,179,0,0,0,114,5,0,0,0,114,5,0,0,0, + 114,6,0,0,0,114,183,0,0,0,58,3,0,0,115,6, + 0,0,0,10,2,16,1,4,2,122,24,70,114,111,122,101, 110,73,109,112,111,114,116,101,114,46,102,105,110,100,95,115, 112,101,99,99,3,0,0,0,0,0,0,0,0,0,0,0, - 3,0,0,0,3,0,0,0,67,0,0,0,115,18,0,0, - 0,116,0,160,1,124,1,161,1,114,14,124,0,83,0,100, - 1,83,0,41,2,122,93,70,105,110,100,32,97,32,102,114, - 111,122,101,110,32,109,111,100,117,108,101,46,10,10,32,32, - 32,32,32,32,32,32,84,104,105,115,32,109,101,116,104,111, - 100,32,105,115,32,100,101,112,114,101,99,97,116,101,100,46, - 32,32,85,115,101,32,102,105,110,100,95,115,112,101,99,40, - 41,32,105,110,115,116,101,97,100,46,10,10,32,32,32,32, - 32,32,32,32,78,41,2,114,58,0,0,0,114,89,0,0, - 0,41,3,114,165,0,0,0,114,82,0,0,0,114,166,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,114,169,0,0,0,50,3,0,0,115,2,0,0,0,0, - 7,122,26,70,114,111,122,101,110,73,109,112,111,114,116,101, - 114,46,102,105,110,100,95,109,111,100,117,108,101,99,2,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,1,0, - 0,0,67,0,0,0,115,4,0,0,0,100,1,83,0,41, - 2,122,42,85,115,101,32,100,101,102,97,117,108,116,32,115, - 101,109,97,110,116,105,99,115,32,102,111,114,32,109,111,100, - 117,108,101,32,99,114,101,97,116,105,111,110,46,78,114,10, - 0,0,0,41,2,114,165,0,0,0,114,96,0,0,0,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,114,150, - 0,0,0,59,3,0,0,115,2,0,0,0,0,2,122,28, - 70,114,111,122,101,110,73,109,112,111,114,116,101,114,46,99, - 114,101,97,116,101,95,109,111,100,117,108,101,99,1,0,0, - 0,0,0,0,0,0,0,0,0,3,0,0,0,4,0,0, - 0,67,0,0,0,115,64,0,0,0,124,0,106,0,106,1, - 125,1,116,2,160,3,124,1,161,1,115,36,116,4,100,1, - 160,5,124,1,161,1,124,1,100,2,141,2,130,1,116,6, - 116,2,106,7,124,1,131,2,125,2,116,8,124,2,124,0, - 106,9,131,2,1,0,100,0,83,0,114,88,0,0,0,41, - 10,114,106,0,0,0,114,17,0,0,0,114,58,0,0,0, - 114,89,0,0,0,114,80,0,0,0,114,46,0,0,0,114, - 68,0,0,0,218,17,103,101,116,95,102,114,111,122,101,110, - 95,111,98,106,101,99,116,218,4,101,120,101,99,114,7,0, - 0,0,41,3,114,97,0,0,0,114,17,0,0,0,218,4, - 99,111,100,101,114,10,0,0,0,114,10,0,0,0,114,11, - 0,0,0,114,151,0,0,0,63,3,0,0,115,14,0,0, - 0,0,2,8,1,10,1,10,1,2,255,6,2,12,1,122, - 26,70,114,111,122,101,110,73,109,112,111,114,116,101,114,46, - 101,120,101,99,95,109,111,100,117,108,101,99,2,0,0,0, - 0,0,0,0,0,0,0,0,2,0,0,0,3,0,0,0, - 67,0,0,0,115,10,0,0,0,116,0,124,0,124,1,131, - 2,83,0,41,1,122,95,76,111,97,100,32,97,32,102,114, - 111,122,101,110,32,109,111,100,117,108,101,46,10,10,32,32, - 32,32,32,32,32,32,84,104,105,115,32,109,101,116,104,111, - 100,32,105,115,32,100,101,112,114,101,99,97,116,101,100,46, - 32,32,85,115,101,32,101,120,101,99,95,109,111,100,117,108, - 101,40,41,32,105,110,115,116,101,97,100,46,10,10,32,32, - 32,32,32,32,32,32,41,1,114,98,0,0,0,114,170,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,114,156,0,0,0,72,3,0,0,115,2,0,0,0,0, - 7,122,26,70,114,111,122,101,110,73,109,112,111,114,116,101, - 114,46,108,111,97,100,95,109,111,100,117,108,101,99,2,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,3,0, - 0,0,67,0,0,0,115,10,0,0,0,116,0,160,1,124, - 1,161,1,83,0,41,1,122,45,82,101,116,117,114,110,32, - 116,104,101,32,99,111,100,101,32,111,98,106,101,99,116,32, - 102,111,114,32,116,104,101,32,102,114,111,122,101,110,32,109, - 111,100,117,108,101,46,41,2,114,58,0,0,0,114,177,0, - 0,0,114,170,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,114,171,0,0,0,81,3,0,0,115, - 2,0,0,0,0,4,122,23,70,114,111,122,101,110,73,109, - 112,111,114,116,101,114,46,103,101,116,95,99,111,100,101,99, - 2,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0, - 1,0,0,0,67,0,0,0,115,4,0,0,0,100,1,83, - 0,41,2,122,54,82,101,116,117,114,110,32,78,111,110,101, - 32,97,115,32,102,114,111,122,101,110,32,109,111,100,117,108, - 101,115,32,100,111,32,110,111,116,32,104,97,118,101,32,115, - 111,117,114,99,101,32,99,111,100,101,46,78,114,10,0,0, - 0,114,170,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,172,0,0,0,87,3,0,0,115,2, - 0,0,0,0,4,122,25,70,114,111,122,101,110,73,109,112, - 111,114,116,101,114,46,103,101,116,95,115,111,117,114,99,101, + 3,0,0,0,4,0,0,0,67,0,0,0,115,30,0,0, + 0,116,0,160,1,100,1,116,2,161,2,1,0,116,3,160, + 4,124,1,161,1,114,13,124,0,83,0,100,2,83,0,41, + 3,122,93,70,105,110,100,32,97,32,102,114,111,122,101,110, + 32,109,111,100,117,108,101,46,10,10,32,32,32,32,32,32, + 32,32,84,104,105,115,32,109,101,116,104,111,100,32,105,115, + 32,100,101,112,114,101,99,97,116,101,100,46,32,32,85,115, + 101,32,102,105,110,100,95,115,112,101,99,40,41,32,105,110, + 115,116,101,97,100,46,10,10,32,32,32,32,32,32,32,32, + 122,105,70,114,111,122,101,110,73,109,112,111,114,116,101,114, + 46,102,105,110,100,95,109,111,100,117,108,101,40,41,32,105, + 115,32,100,101,112,114,101,99,97,116,101,100,32,97,110,100, + 32,115,108,97,116,101,100,32,102,111,114,32,114,101,109,111, + 118,97,108,32,105,110,32,80,121,116,104,111,110,32,51,46, + 49,50,59,32,117,115,101,32,102,105,110,100,95,115,112,101, + 99,40,41,32,105,110,115,116,101,97,100,78,41,5,114,101, + 0,0,0,114,102,0,0,0,114,103,0,0,0,114,64,0, + 0,0,114,98,0,0,0,41,3,114,180,0,0,0,114,89, + 0,0,0,114,181,0,0,0,114,5,0,0,0,114,5,0, + 0,0,114,6,0,0,0,114,184,0,0,0,65,3,0,0, + 115,8,0,0,0,6,7,2,2,4,254,18,3,122,26,70, + 114,111,122,101,110,73,109,112,111,114,116,101,114,46,102,105, + 110,100,95,109,111,100,117,108,101,99,1,0,0,0,0,0, + 0,0,0,0,0,0,1,0,0,0,1,0,0,0,67,0, + 0,0,114,185,0,0,0,41,2,122,42,85,115,101,32,100, + 101,102,97,117,108,116,32,115,101,109,97,110,116,105,99,115, + 32,102,111,114,32,109,111,100,117,108,101,32,99,114,101,97, + 116,105,111,110,46,78,114,5,0,0,0,114,174,0,0,0, + 114,5,0,0,0,114,5,0,0,0,114,6,0,0,0,114, + 162,0,0,0,77,3,0,0,115,2,0,0,0,4,0,122, + 28,70,114,111,122,101,110,73,109,112,111,114,116,101,114,46, + 99,114,101,97,116,101,95,109,111,100,117,108,101,99,1,0, + 0,0,0,0,0,0,0,0,0,0,3,0,0,0,4,0, + 0,0,67,0,0,0,115,64,0,0,0,124,0,106,0,106, + 1,125,1,116,2,160,3,124,1,161,1,115,18,116,4,100, + 1,160,5,124,1,161,1,124,1,100,2,141,2,130,1,116, + 6,116,2,106,7,124,1,131,2,125,2,116,8,124,2,124, + 0,106,9,131,2,1,0,100,0,83,0,114,97,0,0,0, + 41,10,114,113,0,0,0,114,20,0,0,0,114,64,0,0, + 0,114,98,0,0,0,114,87,0,0,0,114,50,0,0,0, + 114,74,0,0,0,218,17,103,101,116,95,102,114,111,122,101, + 110,95,111,98,106,101,99,116,218,4,101,120,101,99,114,14, + 0,0,0,41,3,114,110,0,0,0,114,20,0,0,0,218, + 4,99,111,100,101,114,5,0,0,0,114,5,0,0,0,114, + 6,0,0,0,114,163,0,0,0,81,3,0,0,115,14,0, + 0,0,8,2,10,1,10,1,2,1,6,255,12,2,16,1, + 122,26,70,114,111,122,101,110,73,109,112,111,114,116,101,114, + 46,101,120,101,99,95,109,111,100,117,108,101,99,2,0,0, + 0,0,0,0,0,0,0,0,0,2,0,0,0,3,0,0, + 0,67,0,0,0,115,10,0,0,0,116,0,124,0,124,1, + 131,2,83,0,41,1,122,95,76,111,97,100,32,97,32,102, + 114,111,122,101,110,32,109,111,100,117,108,101,46,10,10,32, + 32,32,32,32,32,32,32,84,104,105,115,32,109,101,116,104, + 111,100,32,105,115,32,100,101,112,114,101,99,97,116,101,100, + 46,32,32,85,115,101,32,101,120,101,99,95,109,111,100,117, + 108,101,40,41,32,105,110,115,116,101,97,100,46,10,10,32, + 32,32,32,32,32,32,32,41,1,114,111,0,0,0,114,186, + 0,0,0,114,5,0,0,0,114,5,0,0,0,114,6,0, + 0,0,114,170,0,0,0,90,3,0,0,115,2,0,0,0, + 10,8,122,26,70,114,111,122,101,110,73,109,112,111,114,116, + 101,114,46,108,111,97,100,95,109,111,100,117,108,101,99,2, + 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,3, + 0,0,0,67,0,0,0,243,10,0,0,0,116,0,160,1, + 124,1,161,1,83,0,41,1,122,45,82,101,116,117,114,110, + 32,116,104,101,32,99,111,100,101,32,111,98,106,101,99,116, + 32,102,111,114,32,116,104,101,32,102,114,111,122,101,110,32, + 109,111,100,117,108,101,46,41,2,114,64,0,0,0,114,195, + 0,0,0,114,186,0,0,0,114,5,0,0,0,114,5,0, + 0,0,114,6,0,0,0,114,187,0,0,0,100,3,0,0, + 243,2,0,0,0,10,4,122,23,70,114,111,122,101,110,73, + 109,112,111,114,116,101,114,46,103,101,116,95,99,111,100,101, 99,2,0,0,0,0,0,0,0,0,0,0,0,2,0,0, - 0,3,0,0,0,67,0,0,0,115,10,0,0,0,116,0, - 160,1,124,1,161,1,83,0,41,1,122,46,82,101,116,117, - 114,110,32,84,114,117,101,32,105,102,32,116,104,101,32,102, - 114,111,122,101,110,32,109,111,100,117,108,101,32,105,115,32, - 97,32,112,97,99,107,97,103,101,46,41,2,114,58,0,0, - 0,90,17,105,115,95,102,114,111,122,101,110,95,112,97,99, - 107,97,103,101,114,170,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,114,116,0,0,0,93,3,0, - 0,115,2,0,0,0,0,4,122,25,70,114,111,122,101,110, - 73,109,112,111,114,116,101,114,46,105,115,95,112,97,99,107, - 97,103,101,41,2,78,78,41,1,78,41,17,114,1,0,0, - 0,114,0,0,0,0,114,2,0,0,0,114,3,0,0,0, - 114,139,0,0,0,114,173,0,0,0,114,100,0,0,0,114, - 174,0,0,0,114,168,0,0,0,114,169,0,0,0,114,150, - 0,0,0,114,151,0,0,0,114,156,0,0,0,114,91,0, - 0,0,114,171,0,0,0,114,172,0,0,0,114,116,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,175,0,0,0,23,3,0,0,115,46, - 0,0,0,8,2,4,7,4,2,2,1,10,8,2,1,12, - 6,2,1,12,8,2,1,10,3,2,1,10,8,2,1,10, - 8,2,1,2,1,12,4,2,1,2,1,12,4,2,1,2, - 1,114,175,0,0,0,99,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,0,2,0,0,0,64,0,0,0,115, - 32,0,0,0,101,0,90,1,100,0,90,2,100,1,90,3, - 100,2,100,3,132,0,90,4,100,4,100,5,132,0,90,5, - 100,6,83,0,41,7,218,18,95,73,109,112,111,114,116,76, - 111,99,107,67,111,110,116,101,120,116,122,36,67,111,110,116, - 101,120,116,32,109,97,110,97,103,101,114,32,102,111,114,32, - 116,104,101,32,105,109,112,111,114,116,32,108,111,99,107,46, - 99,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0, - 0,2,0,0,0,67,0,0,0,115,12,0,0,0,116,0, - 160,1,161,0,1,0,100,1,83,0,41,2,122,24,65,99, - 113,117,105,114,101,32,116,104,101,32,105,109,112,111,114,116, - 32,108,111,99,107,46,78,41,2,114,58,0,0,0,114,59, - 0,0,0,114,48,0,0,0,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,114,55,0,0,0,106,3,0,0, - 115,2,0,0,0,0,2,122,28,95,73,109,112,111,114,116, - 76,111,99,107,67,111,110,116,101,120,116,46,95,95,101,110, - 116,101,114,95,95,99,4,0,0,0,0,0,0,0,0,0, - 0,0,4,0,0,0,2,0,0,0,67,0,0,0,115,12, - 0,0,0,116,0,160,1,161,0,1,0,100,1,83,0,41, - 2,122,60,82,101,108,101,97,115,101,32,116,104,101,32,105, - 109,112,111,114,116,32,108,111,99,107,32,114,101,103,97,114, - 100,108,101,115,115,32,111,102,32,97,110,121,32,114,97,105, - 115,101,100,32,101,120,99,101,112,116,105,111,110,115,46,78, - 41,2,114,58,0,0,0,114,61,0,0,0,41,4,114,30, - 0,0,0,218,8,101,120,99,95,116,121,112,101,218,9,101, - 120,99,95,118,97,108,117,101,218,13,101,120,99,95,116,114, - 97,99,101,98,97,99,107,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,114,57,0,0,0,110,3,0,0,115, - 2,0,0,0,0,2,122,27,95,73,109,112,111,114,116,76, - 111,99,107,67,111,110,116,101,120,116,46,95,95,101,120,105, - 116,95,95,78,41,6,114,1,0,0,0,114,0,0,0,0, - 114,2,0,0,0,114,3,0,0,0,114,55,0,0,0,114, - 57,0,0,0,114,10,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,114,180,0,0,0,102,3,0, - 0,115,6,0,0,0,8,2,4,2,8,4,114,180,0,0, - 0,99,3,0,0,0,0,0,0,0,0,0,0,0,5,0, - 0,0,5,0,0,0,67,0,0,0,115,64,0,0,0,124, - 1,160,0,100,1,124,2,100,2,24,0,161,2,125,3,116, - 1,124,3,131,1,124,2,107,0,114,36,116,2,100,3,131, - 1,130,1,124,3,100,4,25,0,125,4,124,0,114,60,100, - 5,160,3,124,4,124,0,161,2,83,0,124,4,83,0,41, - 6,122,50,82,101,115,111,108,118,101,32,97,32,114,101,108, - 97,116,105,118,101,32,109,111,100,117,108,101,32,110,97,109, - 101,32,116,111,32,97,110,32,97,98,115,111,108,117,116,101, - 32,111,110,101,46,114,129,0,0,0,114,39,0,0,0,122, - 50,97,116,116,101,109,112,116,101,100,32,114,101,108,97,116, - 105,118,101,32,105,109,112,111,114,116,32,98,101,121,111,110, - 100,32,116,111,112,45,108,101,118,101,108,32,112,97,99,107, - 97,103,101,114,22,0,0,0,250,5,123,125,46,123,125,41, - 4,218,6,114,115,112,108,105,116,218,3,108,101,110,114,80, - 0,0,0,114,46,0,0,0,41,5,114,17,0,0,0,218, - 7,112,97,99,107,97,103,101,218,5,108,101,118,101,108,90, - 4,98,105,116,115,90,4,98,97,115,101,114,10,0,0,0, - 114,10,0,0,0,114,11,0,0,0,218,13,95,114,101,115, - 111,108,118,101,95,110,97,109,101,115,3,0,0,115,10,0, - 0,0,0,2,16,1,12,1,8,1,8,1,114,189,0,0, - 0,99,3,0,0,0,0,0,0,0,0,0,0,0,4,0, - 0,0,4,0,0,0,67,0,0,0,115,34,0,0,0,124, - 0,160,0,124,1,124,2,161,2,125,3,124,3,100,0,117, - 0,114,24,100,0,83,0,116,1,124,1,124,3,131,2,83, - 0,114,13,0,0,0,41,2,114,169,0,0,0,114,92,0, - 0,0,41,4,218,6,102,105,110,100,101,114,114,17,0,0, - 0,114,166,0,0,0,114,110,0,0,0,114,10,0,0,0, - 114,10,0,0,0,114,11,0,0,0,218,17,95,102,105,110, - 100,95,115,112,101,99,95,108,101,103,97,99,121,124,3,0, - 0,115,8,0,0,0,0,3,12,1,8,1,4,1,114,191, - 0,0,0,99,3,0,0,0,0,0,0,0,0,0,0,0, - 10,0,0,0,10,0,0,0,67,0,0,0,115,32,1,0, - 0,116,0,106,1,125,3,124,3,100,1,117,0,114,22,116, - 2,100,2,131,1,130,1,124,3,115,38,116,3,160,4,100, - 3,116,5,161,2,1,0,124,0,116,0,106,6,118,0,125, - 4,124,3,68,0,93,230,125,5,116,7,131,0,143,94,1, - 0,122,10,124,5,106,8,125,6,87,0,110,54,4,0,116, - 9,121,128,1,0,1,0,1,0,116,10,124,5,124,0,124, - 1,131,3,125,7,124,7,100,1,117,0,114,124,89,0,87, - 0,100,1,4,0,4,0,131,3,1,0,113,52,89,0,110, - 14,48,0,124,6,124,0,124,1,124,2,131,3,125,7,87, - 0,100,1,4,0,4,0,131,3,1,0,110,16,49,0,115, - 162,48,0,1,0,1,0,1,0,89,0,1,0,124,7,100, - 1,117,1,114,52,124,4,144,1,115,18,124,0,116,0,106, - 6,118,0,144,1,114,18,116,0,106,6,124,0,25,0,125, - 8,122,10,124,8,106,11,125,9,87,0,110,26,4,0,116, - 9,121,244,1,0,1,0,1,0,124,7,6,0,89,0,2, - 0,1,0,83,0,48,0,124,9,100,1,117,0,144,1,114, - 8,124,7,2,0,1,0,83,0,124,9,2,0,1,0,83, - 0,113,52,124,7,2,0,1,0,83,0,113,52,100,1,83, - 0,41,4,122,21,70,105,110,100,32,97,32,109,111,100,117, - 108,101,39,115,32,115,112,101,99,46,78,122,53,115,121,115, - 46,109,101,116,97,95,112,97,116,104,32,105,115,32,78,111, - 110,101,44,32,80,121,116,104,111,110,32,105,115,32,108,105, - 107,101,108,121,32,115,104,117,116,116,105,110,103,32,100,111, - 119,110,122,22,115,121,115,46,109,101,116,97,95,112,97,116, - 104,32,105,115,32,101,109,112,116,121,41,12,114,15,0,0, - 0,218,9,109,101,116,97,95,112,97,116,104,114,80,0,0, - 0,218,9,95,119,97,114,110,105,110,103,115,218,4,119,97, - 114,110,218,13,73,109,112,111,114,116,87,97,114,110,105,110, - 103,114,93,0,0,0,114,180,0,0,0,114,168,0,0,0, - 114,107,0,0,0,114,191,0,0,0,114,106,0,0,0,41, - 10,114,17,0,0,0,114,166,0,0,0,114,167,0,0,0, - 114,192,0,0,0,90,9,105,115,95,114,101,108,111,97,100, - 114,190,0,0,0,114,168,0,0,0,114,96,0,0,0,114, - 97,0,0,0,114,106,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,218,10,95,102,105,110,100,95, - 115,112,101,99,133,3,0,0,115,54,0,0,0,0,2,6, - 1,8,2,8,3,4,1,12,5,10,1,8,1,8,1,2, - 1,10,1,12,1,12,1,8,1,22,2,42,1,8,2,18, - 1,10,1,2,1,10,1,12,4,14,2,10,1,8,2,10, - 2,10,2,114,196,0,0,0,99,3,0,0,0,0,0,0, - 0,0,0,0,0,3,0,0,0,5,0,0,0,67,0,0, - 0,115,108,0,0,0,116,0,124,0,116,1,131,2,115,28, - 116,2,100,1,160,3,116,4,124,0,131,1,161,1,131,1, - 130,1,124,2,100,2,107,0,114,44,116,5,100,3,131,1, - 130,1,124,2,100,2,107,4,114,84,116,0,124,1,116,1, - 131,2,115,72,116,2,100,4,131,1,130,1,110,12,124,1, - 115,84,116,6,100,5,131,1,130,1,124,0,115,104,124,2, - 100,2,107,2,114,104,116,5,100,6,131,1,130,1,100,7, - 83,0,41,8,122,28,86,101,114,105,102,121,32,97,114,103, - 117,109,101,110,116,115,32,97,114,101,32,34,115,97,110,101, - 34,46,122,31,109,111,100,117,108,101,32,110,97,109,101,32, - 109,117,115,116,32,98,101,32,115,116,114,44,32,110,111,116, - 32,123,125,114,22,0,0,0,122,18,108,101,118,101,108,32, - 109,117,115,116,32,98,101,32,62,61,32,48,122,31,95,95, - 112,97,99,107,97,103,101,95,95,32,110,111,116,32,115,101, - 116,32,116,111,32,97,32,115,116,114,105,110,103,122,54,97, - 116,116,101,109,112,116,101,100,32,114,101,108,97,116,105,118, - 101,32,105,109,112,111,114,116,32,119,105,116,104,32,110,111, - 32,107,110,111,119,110,32,112,97,114,101,110,116,32,112,97, - 99,107,97,103,101,122,17,69,109,112,116,121,32,109,111,100, - 117,108,101,32,110,97,109,101,78,41,7,218,10,105,115,105, - 110,115,116,97,110,99,101,218,3,115,116,114,218,9,84,121, - 112,101,69,114,114,111,114,114,46,0,0,0,114,14,0,0, - 0,218,10,86,97,108,117,101,69,114,114,111,114,114,80,0, - 0,0,169,3,114,17,0,0,0,114,187,0,0,0,114,188, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,218,13,95,115,97,110,105,116,121,95,99,104,101,99, - 107,180,3,0,0,115,22,0,0,0,0,2,10,1,18,1, - 8,1,8,1,8,1,10,1,10,1,4,1,8,2,12,1, - 114,202,0,0,0,122,16,78,111,32,109,111,100,117,108,101, - 32,110,97,109,101,100,32,122,4,123,33,114,125,99,2,0, - 0,0,0,0,0,0,0,0,0,0,9,0,0,0,8,0, - 0,0,67,0,0,0,115,22,1,0,0,100,0,125,2,124, - 0,160,0,100,1,161,1,100,2,25,0,125,3,124,3,114, - 132,124,3,116,1,106,2,118,1,114,42,116,3,124,1,124, - 3,131,2,1,0,124,0,116,1,106,2,118,0,114,62,116, - 1,106,2,124,0,25,0,83,0,116,1,106,2,124,3,25, - 0,125,4,122,10,124,4,106,4,125,2,87,0,110,48,4, - 0,116,5,121,130,1,0,1,0,1,0,116,6,100,3,23, - 0,160,7,124,0,124,3,161,2,125,5,116,8,124,5,124, - 0,100,4,141,2,100,0,130,2,89,0,110,2,48,0,116, - 9,124,0,124,2,131,2,125,6,124,6,100,0,117,0,114, - 170,116,8,116,6,160,7,124,0,161,1,124,0,100,4,141, - 2,130,1,110,8,116,10,124,6,131,1,125,7,124,3,144, - 1,114,18,116,1,106,2,124,3,25,0,125,4,124,0,160, - 0,100,1,161,1,100,5,25,0,125,8,122,16,116,11,124, - 4,124,8,124,7,131,3,1,0,87,0,110,48,4,0,116, - 5,144,1,121,16,1,0,1,0,1,0,100,6,124,3,155, - 2,100,7,124,8,155,2,157,4,125,5,116,12,160,13,124, - 5,116,14,161,2,1,0,89,0,110,2,48,0,124,7,83, - 0,41,8,78,114,129,0,0,0,114,22,0,0,0,122,23, - 59,32,123,33,114,125,32,105,115,32,110,111,116,32,97,32, - 112,97,99,107,97,103,101,114,16,0,0,0,233,2,0,0, - 0,122,27,67,97,110,110,111,116,32,115,101,116,32,97,110, - 32,97,116,116,114,105,98,117,116,101,32,111,110,32,122,18, - 32,102,111,114,32,99,104,105,108,100,32,109,111,100,117,108, - 101,32,41,15,114,130,0,0,0,114,15,0,0,0,114,93, - 0,0,0,114,68,0,0,0,114,142,0,0,0,114,107,0, - 0,0,218,8,95,69,82,82,95,77,83,71,114,46,0,0, - 0,218,19,77,111,100,117,108,101,78,111,116,70,111,117,110, - 100,69,114,114,111,114,114,196,0,0,0,114,160,0,0,0, - 114,5,0,0,0,114,193,0,0,0,114,194,0,0,0,114, - 195,0,0,0,41,9,114,17,0,0,0,218,7,105,109,112, - 111,114,116,95,114,166,0,0,0,114,131,0,0,0,90,13, - 112,97,114,101,110,116,95,109,111,100,117,108,101,114,158,0, - 0,0,114,96,0,0,0,114,97,0,0,0,90,5,99,104, - 105,108,100,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,218,23,95,102,105,110,100,95,97,110,100,95,108,111, - 97,100,95,117,110,108,111,99,107,101,100,199,3,0,0,115, - 52,0,0,0,0,1,4,1,14,1,4,1,10,1,10,2, - 10,1,10,1,10,1,2,1,10,1,12,1,16,1,20,1, - 10,1,8,1,20,2,8,1,6,2,10,1,14,1,2,1, - 16,1,14,1,16,1,18,1,114,207,0,0,0,99,2,0, - 0,0,0,0,0,0,0,0,0,0,4,0,0,0,8,0, - 0,0,67,0,0,0,115,128,0,0,0,116,0,124,0,131, - 1,143,62,1,0,116,1,106,2,160,3,124,0,116,4,161, - 2,125,2,124,2,116,4,117,0,114,56,116,5,124,0,124, - 1,131,2,87,0,2,0,100,1,4,0,4,0,131,3,1, - 0,83,0,87,0,100,1,4,0,4,0,131,3,1,0,110, - 16,49,0,115,76,48,0,1,0,1,0,1,0,89,0,1, - 0,124,2,100,1,117,0,114,116,100,2,160,6,124,0,161, - 1,125,3,116,7,124,3,124,0,100,3,141,2,130,1,116, - 8,124,0,131,1,1,0,124,2,83,0,41,4,122,25,70, - 105,110,100,32,97,110,100,32,108,111,97,100,32,116,104,101, - 32,109,111,100,117,108,101,46,78,122,40,105,109,112,111,114, - 116,32,111,102,32,123,125,32,104,97,108,116,101,100,59,32, - 78,111,110,101,32,105,110,32,115,121,115,46,109,111,100,117, - 108,101,115,114,16,0,0,0,41,9,114,51,0,0,0,114, - 15,0,0,0,114,93,0,0,0,114,35,0,0,0,218,14, - 95,78,69,69,68,83,95,76,79,65,68,73,78,71,114,207, - 0,0,0,114,46,0,0,0,114,205,0,0,0,114,66,0, - 0,0,41,4,114,17,0,0,0,114,206,0,0,0,114,97, - 0,0,0,114,76,0,0,0,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,14,95,102,105,110,100,95,97, - 110,100,95,108,111,97,100,234,3,0,0,115,22,0,0,0, - 0,2,10,1,14,1,8,1,54,2,8,1,4,1,2,255, - 4,2,12,2,8,1,114,209,0,0,0,114,22,0,0,0, - 99,3,0,0,0,0,0,0,0,0,0,0,0,3,0,0, - 0,4,0,0,0,67,0,0,0,115,42,0,0,0,116,0, - 124,0,124,1,124,2,131,3,1,0,124,2,100,1,107,4, - 114,32,116,1,124,0,124,1,124,2,131,3,125,0,116,2, - 124,0,116,3,131,2,83,0,41,2,97,50,1,0,0,73, - 109,112,111,114,116,32,97,110,100,32,114,101,116,117,114,110, - 32,116,104,101,32,109,111,100,117,108,101,32,98,97,115,101, - 100,32,111,110,32,105,116,115,32,110,97,109,101,44,32,116, - 104,101,32,112,97,99,107,97,103,101,32,116,104,101,32,99, - 97,108,108,32,105,115,10,32,32,32,32,98,101,105,110,103, - 32,109,97,100,101,32,102,114,111,109,44,32,97,110,100,32, - 116,104,101,32,108,101,118,101,108,32,97,100,106,117,115,116, - 109,101,110,116,46,10,10,32,32,32,32,84,104,105,115,32, - 102,117,110,99,116,105,111,110,32,114,101,112,114,101,115,101, - 110,116,115,32,116,104,101,32,103,114,101,97,116,101,115,116, - 32,99,111,109,109,111,110,32,100,101,110,111,109,105,110,97, - 116,111,114,32,111,102,32,102,117,110,99,116,105,111,110,97, - 108,105,116,121,10,32,32,32,32,98,101,116,119,101,101,110, - 32,105,109,112,111,114,116,95,109,111,100,117,108,101,32,97, - 110,100,32,95,95,105,109,112,111,114,116,95,95,46,32,84, - 104,105,115,32,105,110,99,108,117,100,101,115,32,115,101,116, - 116,105,110,103,32,95,95,112,97,99,107,97,103,101,95,95, - 32,105,102,10,32,32,32,32,116,104,101,32,108,111,97,100, - 101,114,32,100,105,100,32,110,111,116,46,10,10,32,32,32, - 32,114,22,0,0,0,41,4,114,202,0,0,0,114,189,0, - 0,0,114,209,0,0,0,218,11,95,103,99,100,95,105,109, - 112,111,114,116,114,201,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,114,210,0,0,0,250,3,0, - 0,115,8,0,0,0,0,9,12,1,8,1,12,1,114,210, - 0,0,0,169,1,218,9,114,101,99,117,114,115,105,118,101, - 99,3,0,0,0,0,0,0,0,1,0,0,0,8,0,0, - 0,11,0,0,0,67,0,0,0,115,232,0,0,0,124,1, - 68,0,93,222,125,4,116,0,124,4,116,1,131,2,115,66, - 124,3,114,34,124,0,106,2,100,1,23,0,125,5,110,4, - 100,2,125,5,116,3,100,3,124,5,155,0,100,4,116,4, - 124,4,131,1,106,2,155,0,157,4,131,1,130,1,113,4, - 124,4,100,5,107,2,114,108,124,3,115,226,116,5,124,0, - 100,6,131,2,114,226,116,6,124,0,124,0,106,7,124,2, - 100,7,100,8,141,4,1,0,113,4,116,5,124,0,124,4, - 131,2,115,4,100,9,160,8,124,0,106,2,124,4,161,2, - 125,6,122,14,116,9,124,2,124,6,131,2,1,0,87,0, - 113,4,4,0,116,10,121,224,1,0,125,7,1,0,122,54, - 124,7,106,11,124,6,107,2,114,202,116,12,106,13,160,14, - 124,6,116,15,161,2,100,10,117,1,114,202,87,0,89,0, - 100,10,125,7,126,7,113,4,130,0,87,0,89,0,100,10, - 125,7,126,7,113,4,100,10,125,7,126,7,48,0,48,0, - 113,4,124,0,83,0,41,11,122,238,70,105,103,117,114,101, - 32,111,117,116,32,119,104,97,116,32,95,95,105,109,112,111, - 114,116,95,95,32,115,104,111,117,108,100,32,114,101,116,117, - 114,110,46,10,10,32,32,32,32,84,104,101,32,105,109,112, - 111,114,116,95,32,112,97,114,97,109,101,116,101,114,32,105, - 115,32,97,32,99,97,108,108,97,98,108,101,32,119,104,105, - 99,104,32,116,97,107,101,115,32,116,104,101,32,110,97,109, - 101,32,111,102,32,109,111,100,117,108,101,32,116,111,10,32, - 32,32,32,105,109,112,111,114,116,46,32,73,116,32,105,115, - 32,114,101,113,117,105,114,101,100,32,116,111,32,100,101,99, - 111,117,112,108,101,32,116,104,101,32,102,117,110,99,116,105, - 111,110,32,102,114,111,109,32,97,115,115,117,109,105,110,103, - 32,105,109,112,111,114,116,108,105,98,39,115,10,32,32,32, - 32,105,109,112,111,114,116,32,105,109,112,108,101,109,101,110, - 116,97,116,105,111,110,32,105,115,32,100,101,115,105,114,101, - 100,46,10,10,32,32,32,32,122,8,46,95,95,97,108,108, - 95,95,122,13,96,96,102,114,111,109,32,108,105,115,116,39, - 39,122,8,73,116,101,109,32,105,110,32,122,18,32,109,117, - 115,116,32,98,101,32,115,116,114,44,32,110,111,116,32,250, - 1,42,218,7,95,95,97,108,108,95,95,84,114,211,0,0, - 0,114,184,0,0,0,78,41,16,114,197,0,0,0,114,198, - 0,0,0,114,1,0,0,0,114,199,0,0,0,114,14,0, - 0,0,114,4,0,0,0,218,16,95,104,97,110,100,108,101, - 95,102,114,111,109,108,105,115,116,114,214,0,0,0,114,46, - 0,0,0,114,68,0,0,0,114,205,0,0,0,114,17,0, - 0,0,114,15,0,0,0,114,93,0,0,0,114,35,0,0, - 0,114,208,0,0,0,41,8,114,97,0,0,0,218,8,102, - 114,111,109,108,105,115,116,114,206,0,0,0,114,212,0,0, - 0,218,1,120,90,5,119,104,101,114,101,90,9,102,114,111, - 109,95,110,97,109,101,90,3,101,120,99,114,10,0,0,0, - 114,10,0,0,0,114,11,0,0,0,114,215,0,0,0,9, - 4,0,0,115,48,0,0,0,0,10,8,1,10,1,4,1, - 12,2,4,1,10,1,8,255,10,2,8,1,14,1,10,1, - 2,255,8,2,10,1,14,1,2,1,14,1,14,4,10,1, - 16,255,2,2,12,1,26,1,114,215,0,0,0,99,1,0, - 0,0,0,0,0,0,0,0,0,0,3,0,0,0,6,0, - 0,0,67,0,0,0,115,146,0,0,0,124,0,160,0,100, - 1,161,1,125,1,124,0,160,0,100,2,161,1,125,2,124, - 1,100,3,117,1,114,82,124,2,100,3,117,1,114,78,124, - 1,124,2,106,1,107,3,114,78,116,2,106,3,100,4,124, - 1,155,2,100,5,124,2,106,1,155,2,100,6,157,5,116, - 4,100,7,100,8,141,3,1,0,124,1,83,0,124,2,100, - 3,117,1,114,96,124,2,106,1,83,0,116,2,106,3,100, - 9,116,4,100,7,100,8,141,3,1,0,124,0,100,10,25, - 0,125,1,100,11,124,0,118,1,114,142,124,1,160,5,100, - 12,161,1,100,13,25,0,125,1,124,1,83,0,41,14,122, - 167,67,97,108,99,117,108,97,116,101,32,119,104,97,116,32, - 95,95,112,97,99,107,97,103,101,95,95,32,115,104,111,117, - 108,100,32,98,101,46,10,10,32,32,32,32,95,95,112,97, - 99,107,97,103,101,95,95,32,105,115,32,110,111,116,32,103, - 117,97,114,97,110,116,101,101,100,32,116,111,32,98,101,32, - 100,101,102,105,110,101,100,32,111,114,32,99,111,117,108,100, - 32,98,101,32,115,101,116,32,116,111,32,78,111,110,101,10, - 32,32,32,32,116,111,32,114,101,112,114,101,115,101,110,116, - 32,116,104,97,116,32,105,116,115,32,112,114,111,112,101,114, - 32,118,97,108,117,101,32,105,115,32,117,110,107,110,111,119, - 110,46,10,10,32,32,32,32,114,146,0,0,0,114,106,0, - 0,0,78,122,32,95,95,112,97,99,107,97,103,101,95,95, - 32,33,61,32,95,95,115,112,101,99,95,95,46,112,97,114, - 101,110,116,32,40,122,4,32,33,61,32,250,1,41,233,3, - 0,0,0,41,1,90,10,115,116,97,99,107,108,101,118,101, - 108,122,89,99,97,110,39,116,32,114,101,115,111,108,118,101, - 32,112,97,99,107,97,103,101,32,102,114,111,109,32,95,95, - 115,112,101,99,95,95,32,111,114,32,95,95,112,97,99,107, - 97,103,101,95,95,44,32,102,97,108,108,105,110,103,32,98, - 97,99,107,32,111,110,32,95,95,110,97,109,101,95,95,32, - 97,110,100,32,95,95,112,97,116,104,95,95,114,1,0,0, - 0,114,142,0,0,0,114,129,0,0,0,114,22,0,0,0, - 41,6,114,35,0,0,0,114,131,0,0,0,114,193,0,0, - 0,114,194,0,0,0,114,195,0,0,0,114,130,0,0,0, - 41,3,218,7,103,108,111,98,97,108,115,114,187,0,0,0, - 114,96,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,17,95,99,97,108,99,95,95,95,112,97, - 99,107,97,103,101,95,95,46,4,0,0,115,42,0,0,0, - 0,7,10,1,10,1,8,1,18,1,6,1,2,255,4,1, - 4,255,6,2,4,254,6,3,4,1,8,1,6,2,6,2, - 4,254,6,3,8,1,8,1,14,1,114,221,0,0,0,114, - 10,0,0,0,99,5,0,0,0,0,0,0,0,0,0,0, - 0,9,0,0,0,5,0,0,0,67,0,0,0,115,180,0, - 0,0,124,4,100,1,107,2,114,18,116,0,124,0,131,1, - 125,5,110,36,124,1,100,2,117,1,114,30,124,1,110,2, - 105,0,125,6,116,1,124,6,131,1,125,7,116,0,124,0, - 124,7,124,4,131,3,125,5,124,3,115,150,124,4,100,1, - 107,2,114,84,116,0,124,0,160,2,100,3,161,1,100,1, - 25,0,131,1,83,0,124,0,115,92,124,5,83,0,116,3, - 124,0,131,1,116,3,124,0,160,2,100,3,161,1,100,1, - 25,0,131,1,24,0,125,8,116,4,106,5,124,5,106,6, - 100,2,116,3,124,5,106,6,131,1,124,8,24,0,133,2, - 25,0,25,0,83,0,110,26,116,7,124,5,100,4,131,2, - 114,172,116,8,124,5,124,3,116,0,131,3,83,0,124,5, - 83,0,100,2,83,0,41,5,97,215,1,0,0,73,109,112, - 111,114,116,32,97,32,109,111,100,117,108,101,46,10,10,32, - 32,32,32,84,104,101,32,39,103,108,111,98,97,108,115,39, - 32,97,114,103,117,109,101,110,116,32,105,115,32,117,115,101, - 100,32,116,111,32,105,110,102,101,114,32,119,104,101,114,101, - 32,116,104,101,32,105,109,112,111,114,116,32,105,115,32,111, - 99,99,117,114,114,105,110,103,32,102,114,111,109,10,32,32, - 32,32,116,111,32,104,97,110,100,108,101,32,114,101,108,97, - 116,105,118,101,32,105,109,112,111,114,116,115,46,32,84,104, - 101,32,39,108,111,99,97,108,115,39,32,97,114,103,117,109, - 101,110,116,32,105,115,32,105,103,110,111,114,101,100,46,32, - 84,104,101,10,32,32,32,32,39,102,114,111,109,108,105,115, - 116,39,32,97,114,103,117,109,101,110,116,32,115,112,101,99, - 105,102,105,101,115,32,119,104,97,116,32,115,104,111,117,108, - 100,32,101,120,105,115,116,32,97,115,32,97,116,116,114,105, - 98,117,116,101,115,32,111,110,32,116,104,101,32,109,111,100, - 117,108,101,10,32,32,32,32,98,101,105,110,103,32,105,109, - 112,111,114,116,101,100,32,40,101,46,103,46,32,96,96,102, - 114,111,109,32,109,111,100,117,108,101,32,105,109,112,111,114, - 116,32,60,102,114,111,109,108,105,115,116,62,96,96,41,46, - 32,32,84,104,101,32,39,108,101,118,101,108,39,10,32,32, - 32,32,97,114,103,117,109,101,110,116,32,114,101,112,114,101, - 115,101,110,116,115,32,116,104,101,32,112,97,99,107,97,103, - 101,32,108,111,99,97,116,105,111,110,32,116,111,32,105,109, - 112,111,114,116,32,102,114,111,109,32,105,110,32,97,32,114, - 101,108,97,116,105,118,101,10,32,32,32,32,105,109,112,111, - 114,116,32,40,101,46,103,46,32,96,96,102,114,111,109,32, - 46,46,112,107,103,32,105,109,112,111,114,116,32,109,111,100, - 96,96,32,119,111,117,108,100,32,104,97,118,101,32,97,32, - 39,108,101,118,101,108,39,32,111,102,32,50,41,46,10,10, - 32,32,32,32,114,22,0,0,0,78,114,129,0,0,0,114, - 142,0,0,0,41,9,114,210,0,0,0,114,221,0,0,0, - 218,9,112,97,114,116,105,116,105,111,110,114,186,0,0,0, - 114,15,0,0,0,114,93,0,0,0,114,1,0,0,0,114, - 4,0,0,0,114,215,0,0,0,41,9,114,17,0,0,0, - 114,220,0,0,0,218,6,108,111,99,97,108,115,114,216,0, - 0,0,114,188,0,0,0,114,97,0,0,0,90,8,103,108, - 111,98,97,108,115,95,114,187,0,0,0,90,7,99,117,116, - 95,111,102,102,114,10,0,0,0,114,10,0,0,0,114,11, - 0,0,0,218,10,95,95,105,109,112,111,114,116,95,95,73, - 4,0,0,115,30,0,0,0,0,11,8,1,10,2,16,1, - 8,1,12,1,4,3,8,1,18,1,4,1,4,4,26,3, - 32,1,10,1,12,2,114,224,0,0,0,99,1,0,0,0, + 0,1,0,0,0,67,0,0,0,114,185,0,0,0,41,2, + 122,54,82,101,116,117,114,110,32,78,111,110,101,32,97,115, + 32,102,114,111,122,101,110,32,109,111,100,117,108,101,115,32, + 100,111,32,110,111,116,32,104,97,118,101,32,115,111,117,114, + 99,101,32,99,111,100,101,46,78,114,5,0,0,0,114,186, + 0,0,0,114,5,0,0,0,114,5,0,0,0,114,6,0, + 0,0,114,189,0,0,0,106,3,0,0,114,188,0,0,0, + 122,25,70,114,111,122,101,110,73,109,112,111,114,116,101,114, + 46,103,101,116,95,115,111,117,114,99,101,99,2,0,0,0, 0,0,0,0,0,0,0,0,2,0,0,0,3,0,0,0, - 67,0,0,0,115,38,0,0,0,116,0,160,1,124,0,161, - 1,125,1,124,1,100,0,117,0,114,30,116,2,100,1,124, - 0,23,0,131,1,130,1,116,3,124,1,131,1,83,0,41, - 2,78,122,25,110,111,32,98,117,105,108,116,45,105,110,32, - 109,111,100,117,108,101,32,110,97,109,101,100,32,41,4,114, - 161,0,0,0,114,168,0,0,0,114,80,0,0,0,114,160, - 0,0,0,41,2,114,17,0,0,0,114,96,0,0,0,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,218,18, - 95,98,117,105,108,116,105,110,95,102,114,111,109,95,110,97, - 109,101,110,4,0,0,115,8,0,0,0,0,1,10,1,8, - 1,12,1,114,225,0,0,0,99,2,0,0,0,0,0,0, - 0,0,0,0,0,10,0,0,0,5,0,0,0,67,0,0, - 0,115,166,0,0,0,124,1,97,0,124,0,97,1,116,2, - 116,1,131,1,125,2,116,1,106,3,160,4,161,0,68,0, - 93,72,92,2,125,3,125,4,116,5,124,4,124,2,131,2, - 114,26,124,3,116,1,106,6,118,0,114,60,116,7,125,5, - 110,18,116,0,160,8,124,3,161,1,114,26,116,9,125,5, - 110,2,113,26,116,10,124,4,124,5,131,2,125,6,116,11, - 124,6,124,4,131,2,1,0,113,26,116,1,106,3,116,12, - 25,0,125,7,100,1,68,0,93,46,125,8,124,8,116,1, - 106,3,118,1,114,138,116,13,124,8,131,1,125,9,110,10, - 116,1,106,3,124,8,25,0,125,9,116,14,124,7,124,8, - 124,9,131,3,1,0,113,114,100,2,83,0,41,3,122,250, - 83,101,116,117,112,32,105,109,112,111,114,116,108,105,98,32, - 98,121,32,105,109,112,111,114,116,105,110,103,32,110,101,101, - 100,101,100,32,98,117,105,108,116,45,105,110,32,109,111,100, - 117,108,101,115,32,97,110,100,32,105,110,106,101,99,116,105, - 110,103,32,116,104,101,109,10,32,32,32,32,105,110,116,111, - 32,116,104,101,32,103,108,111,98,97,108,32,110,97,109,101, - 115,112,97,99,101,46,10,10,32,32,32,32,65,115,32,115, - 121,115,32,105,115,32,110,101,101,100,101,100,32,102,111,114, - 32,115,121,115,46,109,111,100,117,108,101,115,32,97,99,99, - 101,115,115,32,97,110,100,32,95,105,109,112,32,105,115,32, - 110,101,101,100,101,100,32,116,111,32,108,111,97,100,32,98, - 117,105,108,116,45,105,110,10,32,32,32,32,109,111,100,117, - 108,101,115,44,32,116,104,111,115,101,32,116,119,111,32,109, - 111,100,117,108,101,115,32,109,117,115,116,32,98,101,32,101, - 120,112,108,105,99,105,116,108,121,32,112,97,115,115,101,100, - 32,105,110,46,10,10,32,32,32,32,41,3,114,23,0,0, - 0,114,193,0,0,0,114,65,0,0,0,78,41,15,114,58, - 0,0,0,114,15,0,0,0,114,14,0,0,0,114,93,0, - 0,0,218,5,105,116,101,109,115,114,197,0,0,0,114,79, - 0,0,0,114,161,0,0,0,114,89,0,0,0,114,175,0, - 0,0,114,143,0,0,0,114,149,0,0,0,114,1,0,0, - 0,114,225,0,0,0,114,5,0,0,0,41,10,218,10,115, - 121,115,95,109,111,100,117,108,101,218,11,95,105,109,112,95, - 109,111,100,117,108,101,90,11,109,111,100,117,108,101,95,116, - 121,112,101,114,17,0,0,0,114,97,0,0,0,114,110,0, - 0,0,114,96,0,0,0,90,11,115,101,108,102,95,109,111, - 100,117,108,101,90,12,98,117,105,108,116,105,110,95,110,97, - 109,101,90,14,98,117,105,108,116,105,110,95,109,111,100,117, - 108,101,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,218,6,95,115,101,116,117,112,117,4,0,0,115,36,0, - 0,0,0,9,4,1,4,3,8,1,18,1,10,1,10,1, - 6,1,10,1,6,2,2,1,10,1,12,3,10,1,8,1, - 10,1,10,2,10,1,114,229,0,0,0,99,2,0,0,0, - 0,0,0,0,0,0,0,0,2,0,0,0,3,0,0,0, - 67,0,0,0,115,38,0,0,0,116,0,124,0,124,1,131, - 2,1,0,116,1,106,2,160,3,116,4,161,1,1,0,116, - 1,106,2,160,3,116,5,161,1,1,0,100,1,83,0,41, - 2,122,48,73,110,115,116,97,108,108,32,105,109,112,111,114, - 116,101,114,115,32,102,111,114,32,98,117,105,108,116,105,110, - 32,97,110,100,32,102,114,111,122,101,110,32,109,111,100,117, - 108,101,115,78,41,6,114,229,0,0,0,114,15,0,0,0, - 114,192,0,0,0,114,120,0,0,0,114,161,0,0,0,114, - 175,0,0,0,41,2,114,227,0,0,0,114,228,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,218, - 8,95,105,110,115,116,97,108,108,152,4,0,0,115,6,0, - 0,0,0,2,10,2,12,1,114,230,0,0,0,99,0,0, - 0,0,0,0,0,0,0,0,0,0,1,0,0,0,4,0, - 0,0,67,0,0,0,115,32,0,0,0,100,1,100,2,108, - 0,125,0,124,0,97,1,124,0,160,2,116,3,106,4,116, - 5,25,0,161,1,1,0,100,2,83,0,41,3,122,57,73, - 110,115,116,97,108,108,32,105,109,112,111,114,116,101,114,115, - 32,116,104,97,116,32,114,101,113,117,105,114,101,32,101,120, - 116,101,114,110,97,108,32,102,105,108,101,115,121,115,116,101, - 109,32,97,99,99,101,115,115,114,22,0,0,0,78,41,6, - 218,26,95,102,114,111,122,101,110,95,105,109,112,111,114,116, - 108,105,98,95,101,120,116,101,114,110,97,108,114,127,0,0, - 0,114,230,0,0,0,114,15,0,0,0,114,93,0,0,0, - 114,1,0,0,0,41,1,114,231,0,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,218,27,95,105,110, - 115,116,97,108,108,95,101,120,116,101,114,110,97,108,95,105, - 109,112,111,114,116,101,114,115,160,4,0,0,115,6,0,0, - 0,0,3,8,1,4,1,114,232,0,0,0,41,2,78,78, - 41,1,78,41,2,78,114,22,0,0,0,41,4,78,78,114, - 10,0,0,0,114,22,0,0,0,41,50,114,3,0,0,0, - 114,127,0,0,0,114,12,0,0,0,114,18,0,0,0,114, - 60,0,0,0,114,34,0,0,0,114,44,0,0,0,114,19, - 0,0,0,114,20,0,0,0,114,50,0,0,0,114,51,0, - 0,0,114,54,0,0,0,114,66,0,0,0,114,68,0,0, - 0,114,77,0,0,0,114,87,0,0,0,114,91,0,0,0, - 114,98,0,0,0,114,112,0,0,0,114,113,0,0,0,114, - 92,0,0,0,114,143,0,0,0,114,149,0,0,0,114,153, - 0,0,0,114,108,0,0,0,114,94,0,0,0,114,159,0, - 0,0,114,160,0,0,0,114,95,0,0,0,114,161,0,0, - 0,114,175,0,0,0,114,180,0,0,0,114,189,0,0,0, - 114,191,0,0,0,114,196,0,0,0,114,202,0,0,0,90, - 15,95,69,82,82,95,77,83,71,95,80,82,69,70,73,88, - 114,204,0,0,0,114,207,0,0,0,218,6,111,98,106,101, - 99,116,114,208,0,0,0,114,209,0,0,0,114,210,0,0, - 0,114,215,0,0,0,114,221,0,0,0,114,224,0,0,0, - 114,225,0,0,0,114,229,0,0,0,114,230,0,0,0,114, - 232,0,0,0,114,10,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,218,8,60,109,111,100,117,108, - 101,62,1,0,0,0,115,94,0,0,0,4,24,4,2,8, - 8,8,8,4,2,4,3,16,4,14,77,14,21,14,16,8, - 37,8,17,8,11,14,8,8,11,8,12,8,16,8,36,14, - 101,16,26,10,45,14,72,8,17,8,17,8,30,8,37,8, - 42,8,15,14,75,14,79,14,13,8,9,8,9,10,47,8, - 16,4,1,8,2,8,32,6,3,8,16,10,15,14,37,8, - 27,10,37,8,7,8,35,8,8, + 67,0,0,0,114,198,0,0,0,41,1,122,46,82,101,116, + 117,114,110,32,84,114,117,101,32,105,102,32,116,104,101,32, + 102,114,111,122,101,110,32,109,111,100,117,108,101,32,105,115, + 32,97,32,112,97,99,107,97,103,101,46,41,2,114,64,0, + 0,0,90,17,105,115,95,102,114,111,122,101,110,95,112,97, + 99,107,97,103,101,114,186,0,0,0,114,5,0,0,0,114, + 5,0,0,0,114,6,0,0,0,114,128,0,0,0,112,3, + 0,0,114,199,0,0,0,122,25,70,114,111,122,101,110,73, + 109,112,111,114,116,101,114,46,105,115,95,112,97,99,107,97, + 103,101,114,190,0,0,0,114,0,0,0,0,41,17,114,9, + 0,0,0,114,8,0,0,0,114,1,0,0,0,114,10,0, + 0,0,114,151,0,0,0,114,191,0,0,0,114,114,0,0, + 0,114,192,0,0,0,114,183,0,0,0,114,184,0,0,0, + 114,162,0,0,0,114,163,0,0,0,114,170,0,0,0,114, + 100,0,0,0,114,187,0,0,0,114,189,0,0,0,114,128, + 0,0,0,114,5,0,0,0,114,5,0,0,0,114,5,0, + 0,0,114,6,0,0,0,114,193,0,0,0,36,3,0,0, + 115,48,0,0,0,8,0,4,2,4,7,2,2,10,1,2, + 10,12,1,2,6,12,1,2,11,10,1,2,3,10,1,2, + 8,10,1,2,9,2,1,12,1,2,4,2,1,12,1,2, + 4,2,1,16,1,114,193,0,0,0,99,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,64, + 0,0,0,115,32,0,0,0,101,0,90,1,100,0,90,2, + 100,1,90,3,100,2,100,3,132,0,90,4,100,4,100,5, + 132,0,90,5,100,6,83,0,41,7,218,18,95,73,109,112, + 111,114,116,76,111,99,107,67,111,110,116,101,120,116,122,36, + 67,111,110,116,101,120,116,32,109,97,110,97,103,101,114,32, + 102,111,114,32,116,104,101,32,105,109,112,111,114,116,32,108, + 111,99,107,46,99,1,0,0,0,0,0,0,0,0,0,0, + 0,1,0,0,0,2,0,0,0,67,0,0,0,243,12,0, + 0,0,116,0,160,1,161,0,1,0,100,1,83,0,41,2, + 122,24,65,99,113,117,105,114,101,32,116,104,101,32,105,109, + 112,111,114,116,32,108,111,99,107,46,78,41,2,114,64,0, + 0,0,114,65,0,0,0,114,52,0,0,0,114,5,0,0, + 0,114,5,0,0,0,114,6,0,0,0,114,61,0,0,0, + 125,3,0,0,243,2,0,0,0,12,2,122,28,95,73,109, + 112,111,114,116,76,111,99,107,67,111,110,116,101,120,116,46, + 95,95,101,110,116,101,114,95,95,99,4,0,0,0,0,0, + 0,0,0,0,0,0,4,0,0,0,2,0,0,0,67,0, + 0,0,114,201,0,0,0,41,2,122,60,82,101,108,101,97, + 115,101,32,116,104,101,32,105,109,112,111,114,116,32,108,111, + 99,107,32,114,101,103,97,114,100,108,101,115,115,32,111,102, + 32,97,110,121,32,114,97,105,115,101,100,32,101,120,99,101, + 112,116,105,111,110,115,46,78,41,2,114,64,0,0,0,114, + 67,0,0,0,41,4,114,33,0,0,0,218,8,101,120,99, + 95,116,121,112,101,218,9,101,120,99,95,118,97,108,117,101, + 218,13,101,120,99,95,116,114,97,99,101,98,97,99,107,114, + 5,0,0,0,114,5,0,0,0,114,6,0,0,0,114,63, + 0,0,0,129,3,0,0,114,202,0,0,0,122,27,95,73, + 109,112,111,114,116,76,111,99,107,67,111,110,116,101,120,116, + 46,95,95,101,120,105,116,95,95,78,41,6,114,9,0,0, + 0,114,8,0,0,0,114,1,0,0,0,114,10,0,0,0, + 114,61,0,0,0,114,63,0,0,0,114,5,0,0,0,114, + 5,0,0,0,114,5,0,0,0,114,6,0,0,0,114,200, + 0,0,0,121,3,0,0,115,8,0,0,0,8,0,4,2, + 8,2,12,4,114,200,0,0,0,99,3,0,0,0,0,0, + 0,0,0,0,0,0,5,0,0,0,5,0,0,0,67,0, + 0,0,115,64,0,0,0,124,1,160,0,100,1,124,2,100, + 2,24,0,161,2,125,3,116,1,124,3,131,1,124,2,107, + 0,114,18,116,2,100,3,131,1,130,1,124,3,100,4,25, + 0,125,4,124,0,114,30,100,5,160,3,124,4,124,0,161, + 2,83,0,124,4,83,0,41,6,122,50,82,101,115,111,108, + 118,101,32,97,32,114,101,108,97,116,105,118,101,32,109,111, + 100,117,108,101,32,110,97,109,101,32,116,111,32,97,110,32, + 97,98,115,111,108,117,116,101,32,111,110,101,46,114,141,0, + 0,0,114,42,0,0,0,122,50,97,116,116,101,109,112,116, + 101,100,32,114,101,108,97,116,105,118,101,32,105,109,112,111, + 114,116,32,98,101,121,111,110,100,32,116,111,112,45,108,101, + 118,101,108,32,112,97,99,107,97,103,101,114,25,0,0,0, + 250,5,123,125,46,123,125,41,4,218,6,114,115,112,108,105, + 116,218,3,108,101,110,114,87,0,0,0,114,50,0,0,0, + 41,5,114,20,0,0,0,218,7,112,97,99,107,97,103,101, + 218,5,108,101,118,101,108,90,4,98,105,116,115,90,4,98, + 97,115,101,114,5,0,0,0,114,5,0,0,0,114,6,0, + 0,0,218,13,95,114,101,115,111,108,118,101,95,110,97,109, + 101,134,3,0,0,115,10,0,0,0,16,2,12,1,8,1, + 8,1,20,1,114,211,0,0,0,99,3,0,0,0,0,0, + 0,0,0,0,0,0,5,0,0,0,4,0,0,0,67,0, + 0,0,115,60,0,0,0,116,0,124,0,131,1,155,0,100, + 1,157,2,125,3,116,1,160,2,124,3,116,3,161,2,1, + 0,124,0,160,4,124,1,124,2,161,2,125,4,124,4,100, + 0,117,0,114,25,100,0,83,0,116,5,124,1,124,4,131, + 2,83,0,41,2,78,122,53,46,102,105,110,100,95,115,112, + 101,99,40,41,32,110,111,116,32,102,111,117,110,100,59,32, + 102,97,108,108,105,110,103,32,98,97,99,107,32,116,111,32, + 102,105,110,100,95,109,111,100,117,108,101,40,41,41,6,114, + 7,0,0,0,114,101,0,0,0,114,102,0,0,0,114,169, + 0,0,0,114,184,0,0,0,114,104,0,0,0,41,5,218, + 6,102,105,110,100,101,114,114,20,0,0,0,114,181,0,0, + 0,114,108,0,0,0,114,122,0,0,0,114,5,0,0,0, + 114,5,0,0,0,114,6,0,0,0,218,17,95,102,105,110, + 100,95,115,112,101,99,95,108,101,103,97,99,121,143,3,0, + 0,115,12,0,0,0,14,1,12,2,12,1,8,1,4,1, + 10,1,114,213,0,0,0,99,3,0,0,0,0,0,0,0, + 0,0,0,0,10,0,0,0,10,0,0,0,67,0,0,0, + 115,24,1,0,0,116,0,106,1,125,3,124,3,100,1,117, + 0,114,11,116,2,100,2,131,1,130,1,124,3,115,19,116, + 3,160,4,100,3,116,5,161,2,1,0,124,0,116,0,106, + 6,118,0,125,4,124,3,68,0,93,111,125,5,116,7,131, + 0,143,47,1,0,122,5,124,5,106,8,125,6,87,0,110, + 27,4,0,116,9,121,64,1,0,1,0,1,0,116,10,124, + 5,124,0,124,1,131,3,125,7,124,7,100,1,117,0,114, + 62,89,0,87,0,100,1,4,0,4,0,131,3,1,0,113, + 26,89,0,110,7,119,0,124,6,124,0,124,1,124,2,131, + 3,125,7,87,0,100,1,4,0,4,0,131,3,1,0,110, + 8,49,0,115,81,119,1,1,0,1,0,1,0,89,0,1, + 0,124,7,100,1,117,1,114,137,124,4,115,133,124,0,116, + 0,106,6,118,0,114,133,116,0,106,6,124,0,25,0,125, + 8,122,5,124,8,106,11,125,9,87,0,110,13,4,0,116, + 9,121,120,1,0,1,0,1,0,124,7,6,0,89,0,2, + 0,1,0,83,0,119,0,124,9,100,1,117,0,114,129,124, + 7,2,0,1,0,83,0,124,9,2,0,1,0,83,0,124, + 7,2,0,1,0,83,0,113,26,100,1,83,0,41,4,122, + 21,70,105,110,100,32,97,32,109,111,100,117,108,101,39,115, + 32,115,112,101,99,46,78,122,53,115,121,115,46,109,101,116, + 97,95,112,97,116,104,32,105,115,32,78,111,110,101,44,32, + 80,121,116,104,111,110,32,105,115,32,108,105,107,101,108,121, + 32,115,104,117,116,116,105,110,103,32,100,111,119,110,122,22, + 115,121,115,46,109,101,116,97,95,112,97,116,104,32,105,115, + 32,101,109,112,116,121,41,12,114,18,0,0,0,218,9,109, + 101,116,97,95,112,97,116,104,114,87,0,0,0,114,101,0, + 0,0,114,102,0,0,0,114,169,0,0,0,114,105,0,0, + 0,114,200,0,0,0,114,183,0,0,0,114,2,0,0,0, + 114,213,0,0,0,114,113,0,0,0,41,10,114,20,0,0, + 0,114,181,0,0,0,114,182,0,0,0,114,214,0,0,0, + 90,9,105,115,95,114,101,108,111,97,100,114,212,0,0,0, + 114,183,0,0,0,114,109,0,0,0,114,110,0,0,0,114, + 113,0,0,0,114,5,0,0,0,114,5,0,0,0,114,6, + 0,0,0,218,10,95,102,105,110,100,95,115,112,101,99,153, + 3,0,0,115,68,0,0,0,6,2,8,1,8,2,4,3, + 12,1,10,5,8,1,8,1,2,1,10,1,12,1,12,1, + 8,1,2,1,14,250,4,5,2,254,12,5,2,128,28,248, + 8,9,14,2,10,1,2,1,10,1,12,1,12,4,2,252, + 8,6,8,1,8,2,8,2,2,239,4,19,114,215,0,0, + 0,99,3,0,0,0,0,0,0,0,0,0,0,0,3,0, + 0,0,5,0,0,0,67,0,0,0,115,110,0,0,0,116, + 0,124,0,116,1,131,2,115,14,116,2,100,1,160,3,116, + 4,124,0,131,1,161,1,131,1,130,1,124,2,100,2,107, + 0,114,22,116,5,100,3,131,1,130,1,124,2,100,2,107, + 4,114,41,116,0,124,1,116,1,131,2,115,35,116,2,100, + 4,131,1,130,1,124,1,115,41,116,6,100,5,131,1,130, + 1,124,0,115,51,124,2,100,2,107,2,114,53,116,5,100, + 6,131,1,130,1,100,7,83,0,100,7,83,0,41,8,122, + 28,86,101,114,105,102,121,32,97,114,103,117,109,101,110,116, + 115,32,97,114,101,32,34,115,97,110,101,34,46,122,31,109, + 111,100,117,108,101,32,110,97,109,101,32,109,117,115,116,32, + 98,101,32,115,116,114,44,32,110,111,116,32,123,125,114,25, + 0,0,0,122,18,108,101,118,101,108,32,109,117,115,116,32, + 98,101,32,62,61,32,48,122,31,95,95,112,97,99,107,97, + 103,101,95,95,32,110,111,116,32,115,101,116,32,116,111,32, + 97,32,115,116,114,105,110,103,122,54,97,116,116,101,109,112, + 116,101,100,32,114,101,108,97,116,105,118,101,32,105,109,112, + 111,114,116,32,119,105,116,104,32,110,111,32,107,110,111,119, + 110,32,112,97,114,101,110,116,32,112,97,99,107,97,103,101, + 122,17,69,109,112,116,121,32,109,111,100,117,108,101,32,110, + 97,109,101,78,41,7,218,10,105,115,105,110,115,116,97,110, + 99,101,218,3,115,116,114,218,9,84,121,112,101,69,114,114, + 111,114,114,50,0,0,0,114,3,0,0,0,218,10,86,97, + 108,117,101,69,114,114,111,114,114,87,0,0,0,169,3,114, + 20,0,0,0,114,209,0,0,0,114,210,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,6,0,0,0,218,13,95, + 115,97,110,105,116,121,95,99,104,101,99,107,200,3,0,0, + 115,24,0,0,0,10,2,18,1,8,1,8,1,8,1,10, + 1,8,1,4,1,8,1,12,2,8,1,8,255,114,221,0, + 0,0,122,16,78,111,32,109,111,100,117,108,101,32,110,97, + 109,101,100,32,122,4,123,33,114,125,99,2,0,0,0,0, + 0,0,0,0,0,0,0,9,0,0,0,8,0,0,0,67, + 0,0,0,115,16,1,0,0,100,0,125,2,124,0,160,0, + 100,1,161,1,100,2,25,0,125,3,124,3,114,64,124,3, + 116,1,106,2,118,1,114,21,116,3,124,1,124,3,131,2, + 1,0,124,0,116,1,106,2,118,0,114,31,116,1,106,2, + 124,0,25,0,83,0,116,1,106,2,124,3,25,0,125,4, + 122,5,124,4,106,4,125,2,87,0,110,22,4,0,116,5, + 121,63,1,0,1,0,1,0,116,6,100,3,23,0,160,7, + 124,0,124,3,161,2,125,5,116,8,124,5,124,0,100,4, + 141,2,100,0,130,2,119,0,116,9,124,0,124,2,131,2, + 125,6,124,6,100,0,117,0,114,82,116,8,116,6,160,7, + 124,0,161,1,124,0,100,4,141,2,130,1,116,10,124,6, + 131,1,125,7,124,3,114,134,116,1,106,2,124,3,25,0, + 125,4,124,0,160,0,100,1,161,1,100,5,25,0,125,8, + 122,9,116,11,124,4,124,8,124,7,131,3,1,0,87,0, + 124,7,83,0,4,0,116,5,121,133,1,0,1,0,1,0, + 100,6,124,3,155,2,100,7,124,8,155,2,157,4,125,5, + 116,12,160,13,124,5,116,14,161,2,1,0,89,0,124,7, + 83,0,119,0,124,7,83,0,41,8,78,114,141,0,0,0, + 114,25,0,0,0,122,23,59,32,123,33,114,125,32,105,115, + 32,110,111,116,32,97,32,112,97,99,107,97,103,101,114,19, + 0,0,0,233,2,0,0,0,122,27,67,97,110,110,111,116, + 32,115,101,116,32,97,110,32,97,116,116,114,105,98,117,116, + 101,32,111,110,32,122,18,32,102,111,114,32,99,104,105,108, + 100,32,109,111,100,117,108,101,32,41,15,114,142,0,0,0, + 114,18,0,0,0,114,105,0,0,0,114,74,0,0,0,114, + 154,0,0,0,114,2,0,0,0,218,8,95,69,82,82,95, + 77,83,71,114,50,0,0,0,218,19,77,111,100,117,108,101, + 78,111,116,70,111,117,110,100,69,114,114,111,114,114,215,0, + 0,0,114,173,0,0,0,114,12,0,0,0,114,101,0,0, + 0,114,102,0,0,0,114,169,0,0,0,41,9,114,20,0, + 0,0,218,7,105,109,112,111,114,116,95,114,181,0,0,0, + 114,143,0,0,0,90,13,112,97,114,101,110,116,95,109,111, + 100,117,108,101,114,108,0,0,0,114,109,0,0,0,114,110, + 0,0,0,90,5,99,104,105,108,100,114,5,0,0,0,114, + 5,0,0,0,114,6,0,0,0,218,23,95,102,105,110,100, + 95,97,110,100,95,108,111,97,100,95,117,110,108,111,99,107, + 101,100,219,3,0,0,115,60,0,0,0,4,1,14,1,4, + 1,10,1,10,1,10,2,10,1,10,1,2,1,10,1,12, + 1,16,1,14,1,2,254,10,3,8,1,18,1,8,2,4, + 1,10,2,14,1,2,1,14,1,4,4,12,253,16,1,14, + 1,4,1,2,253,4,3,114,226,0,0,0,99,2,0,0, + 0,0,0,0,0,0,0,0,0,4,0,0,0,8,0,0, + 0,67,0,0,0,115,128,0,0,0,116,0,124,0,131,1, + 143,31,1,0,116,1,106,2,160,3,124,0,116,4,161,2, + 125,2,124,2,116,4,117,0,114,28,116,5,124,0,124,1, + 131,2,87,0,2,0,100,1,4,0,4,0,131,3,1,0, + 83,0,87,0,100,1,4,0,4,0,131,3,1,0,110,8, + 49,0,115,38,119,1,1,0,1,0,1,0,89,0,1,0, + 124,2,100,1,117,0,114,58,100,2,160,6,124,0,161,1, + 125,3,116,7,124,3,124,0,100,3,141,2,130,1,116,8, + 124,0,131,1,1,0,124,2,83,0,41,4,122,25,70,105, + 110,100,32,97,110,100,32,108,111,97,100,32,116,104,101,32, + 109,111,100,117,108,101,46,78,122,40,105,109,112,111,114,116, + 32,111,102,32,123,125,32,104,97,108,116,101,100,59,32,78, + 111,110,101,32,105,110,32,115,121,115,46,109,111,100,117,108, + 101,115,114,19,0,0,0,41,9,114,57,0,0,0,114,18, + 0,0,0,114,105,0,0,0,114,38,0,0,0,218,14,95, + 78,69,69,68,83,95,76,79,65,68,73,78,71,114,226,0, + 0,0,114,50,0,0,0,114,224,0,0,0,114,72,0,0, + 0,41,4,114,20,0,0,0,114,225,0,0,0,114,110,0, + 0,0,114,82,0,0,0,114,5,0,0,0,114,5,0,0, + 0,114,6,0,0,0,218,14,95,102,105,110,100,95,97,110, + 100,95,108,111,97,100,254,3,0,0,115,28,0,0,0,10, + 2,14,1,8,1,8,1,16,253,2,2,28,254,8,5,2, + 1,6,1,2,255,12,2,8,2,4,1,114,228,0,0,0, + 114,25,0,0,0,99,3,0,0,0,0,0,0,0,0,0, + 0,0,3,0,0,0,4,0,0,0,67,0,0,0,115,42, + 0,0,0,116,0,124,0,124,1,124,2,131,3,1,0,124, + 2,100,1,107,4,114,16,116,1,124,0,124,1,124,2,131, + 3,125,0,116,2,124,0,116,3,131,2,83,0,41,2,97, + 50,1,0,0,73,109,112,111,114,116,32,97,110,100,32,114, + 101,116,117,114,110,32,116,104,101,32,109,111,100,117,108,101, + 32,98,97,115,101,100,32,111,110,32,105,116,115,32,110,97, + 109,101,44,32,116,104,101,32,112,97,99,107,97,103,101,32, + 116,104,101,32,99,97,108,108,32,105,115,10,32,32,32,32, + 98,101,105,110,103,32,109,97,100,101,32,102,114,111,109,44, + 32,97,110,100,32,116,104,101,32,108,101,118,101,108,32,97, + 100,106,117,115,116,109,101,110,116,46,10,10,32,32,32,32, + 84,104,105,115,32,102,117,110,99,116,105,111,110,32,114,101, + 112,114,101,115,101,110,116,115,32,116,104,101,32,103,114,101, + 97,116,101,115,116,32,99,111,109,109,111,110,32,100,101,110, + 111,109,105,110,97,116,111,114,32,111,102,32,102,117,110,99, + 116,105,111,110,97,108,105,116,121,10,32,32,32,32,98,101, + 116,119,101,101,110,32,105,109,112,111,114,116,95,109,111,100, + 117,108,101,32,97,110,100,32,95,95,105,109,112,111,114,116, + 95,95,46,32,84,104,105,115,32,105,110,99,108,117,100,101, + 115,32,115,101,116,116,105,110,103,32,95,95,112,97,99,107, + 97,103,101,95,95,32,105,102,10,32,32,32,32,116,104,101, + 32,108,111,97,100,101,114,32,100,105,100,32,110,111,116,46, + 10,10,32,32,32,32,114,25,0,0,0,41,4,114,221,0, + 0,0,114,211,0,0,0,114,228,0,0,0,218,11,95,103, + 99,100,95,105,109,112,111,114,116,114,220,0,0,0,114,5, + 0,0,0,114,5,0,0,0,114,6,0,0,0,114,229,0, + 0,0,14,4,0,0,115,8,0,0,0,12,9,8,1,12, + 1,10,1,114,229,0,0,0,169,1,218,9,114,101,99,117, + 114,115,105,118,101,99,3,0,0,0,0,0,0,0,1,0, + 0,0,8,0,0,0,11,0,0,0,67,0,0,0,115,218, + 0,0,0,124,1,68,0,93,104,125,4,116,0,124,4,116, + 1,131,2,115,32,124,3,114,17,124,0,106,2,100,1,23, + 0,125,5,110,2,100,2,125,5,116,3,100,3,124,5,155, + 0,100,4,116,4,124,4,131,1,106,2,155,0,157,4,131, + 1,130,1,124,4,100,5,107,2,114,53,124,3,115,52,116, + 5,124,0,100,6,131,2,114,52,116,6,124,0,124,0,106, + 7,124,2,100,7,100,8,141,4,1,0,113,2,116,5,124, + 0,124,4,131,2,115,106,100,9,160,8,124,0,106,2,124, + 4,161,2,125,6,122,7,116,9,124,2,124,6,131,2,1, + 0,87,0,113,2,4,0,116,10,121,105,1,0,125,7,1, + 0,122,21,124,7,106,11,124,6,107,2,114,100,116,12,106, + 13,160,14,124,6,116,15,161,2,100,10,117,1,114,100,87, + 0,89,0,100,10,125,7,126,7,113,2,130,0,100,10,125, + 7,126,7,119,1,119,0,113,2,124,0,83,0,41,11,122, + 238,70,105,103,117,114,101,32,111,117,116,32,119,104,97,116, + 32,95,95,105,109,112,111,114,116,95,95,32,115,104,111,117, + 108,100,32,114,101,116,117,114,110,46,10,10,32,32,32,32, + 84,104,101,32,105,109,112,111,114,116,95,32,112,97,114,97, + 109,101,116,101,114,32,105,115,32,97,32,99,97,108,108,97, + 98,108,101,32,119,104,105,99,104,32,116,97,107,101,115,32, + 116,104,101,32,110,97,109,101,32,111,102,32,109,111,100,117, + 108,101,32,116,111,10,32,32,32,32,105,109,112,111,114,116, + 46,32,73,116,32,105,115,32,114,101,113,117,105,114,101,100, + 32,116,111,32,100,101,99,111,117,112,108,101,32,116,104,101, + 32,102,117,110,99,116,105,111,110,32,102,114,111,109,32,97, + 115,115,117,109,105,110,103,32,105,109,112,111,114,116,108,105, + 98,39,115,10,32,32,32,32,105,109,112,111,114,116,32,105, + 109,112,108,101,109,101,110,116,97,116,105,111,110,32,105,115, + 32,100,101,115,105,114,101,100,46,10,10,32,32,32,32,122, + 8,46,95,95,97,108,108,95,95,122,13,96,96,102,114,111, + 109,32,108,105,115,116,39,39,122,8,73,116,101,109,32,105, + 110,32,122,18,32,109,117,115,116,32,98,101,32,115,116,114, + 44,32,110,111,116,32,250,1,42,218,7,95,95,97,108,108, + 95,95,84,114,230,0,0,0,114,206,0,0,0,78,41,16, + 114,216,0,0,0,114,217,0,0,0,114,9,0,0,0,114, + 218,0,0,0,114,3,0,0,0,114,11,0,0,0,218,16, + 95,104,97,110,100,108,101,95,102,114,111,109,108,105,115,116, + 114,233,0,0,0,114,50,0,0,0,114,74,0,0,0,114, + 224,0,0,0,114,20,0,0,0,114,18,0,0,0,114,105, + 0,0,0,114,38,0,0,0,114,227,0,0,0,41,8,114, + 110,0,0,0,218,8,102,114,111,109,108,105,115,116,114,225, + 0,0,0,114,231,0,0,0,218,1,120,90,5,119,104,101, + 114,101,90,9,102,114,111,109,95,110,97,109,101,90,3,101, + 120,99,114,5,0,0,0,114,5,0,0,0,114,6,0,0, + 0,114,234,0,0,0,29,4,0,0,115,56,0,0,0,8, + 10,10,1,4,1,12,1,4,2,10,1,8,1,8,255,8, + 2,14,1,10,1,2,1,6,255,2,128,10,2,14,1,2, + 1,14,1,14,1,10,4,16,1,2,255,12,2,2,1,8, + 128,2,249,2,252,4,12,114,234,0,0,0,99,1,0,0, + 0,0,0,0,0,0,0,0,0,3,0,0,0,6,0,0, + 0,67,0,0,0,115,146,0,0,0,124,0,160,0,100,1, + 161,1,125,1,124,0,160,0,100,2,161,1,125,2,124,1, + 100,3,117,1,114,41,124,2,100,3,117,1,114,39,124,1, + 124,2,106,1,107,3,114,39,116,2,106,3,100,4,124,1, + 155,2,100,5,124,2,106,1,155,2,100,6,157,5,116,4, + 100,7,100,8,141,3,1,0,124,1,83,0,124,2,100,3, + 117,1,114,48,124,2,106,1,83,0,116,2,106,3,100,9, + 116,4,100,7,100,8,141,3,1,0,124,0,100,10,25,0, + 125,1,100,11,124,0,118,1,114,71,124,1,160,5,100,12, + 161,1,100,13,25,0,125,1,124,1,83,0,41,14,122,167, + 67,97,108,99,117,108,97,116,101,32,119,104,97,116,32,95, + 95,112,97,99,107,97,103,101,95,95,32,115,104,111,117,108, + 100,32,98,101,46,10,10,32,32,32,32,95,95,112,97,99, + 107,97,103,101,95,95,32,105,115,32,110,111,116,32,103,117, + 97,114,97,110,116,101,101,100,32,116,111,32,98,101,32,100, + 101,102,105,110,101,100,32,111,114,32,99,111,117,108,100,32, + 98,101,32,115,101,116,32,116,111,32,78,111,110,101,10,32, + 32,32,32,116,111,32,114,101,112,114,101,115,101,110,116,32, + 116,104,97,116,32,105,116,115,32,112,114,111,112,101,114,32, + 118,97,108,117,101,32,105,115,32,117,110,107,110,111,119,110, + 46,10,10,32,32,32,32,114,158,0,0,0,114,113,0,0, + 0,78,122,32,95,95,112,97,99,107,97,103,101,95,95,32, + 33,61,32,95,95,115,112,101,99,95,95,46,112,97,114,101, + 110,116,32,40,122,4,32,33,61,32,250,1,41,233,3,0, + 0,0,41,1,90,10,115,116,97,99,107,108,101,118,101,108, + 122,89,99,97,110,39,116,32,114,101,115,111,108,118,101,32, + 112,97,99,107,97,103,101,32,102,114,111,109,32,95,95,115, + 112,101,99,95,95,32,111,114,32,95,95,112,97,99,107,97, + 103,101,95,95,44,32,102,97,108,108,105,110,103,32,98,97, + 99,107,32,111,110,32,95,95,110,97,109,101,95,95,32,97, + 110,100,32,95,95,112,97,116,104,95,95,114,9,0,0,0, + 114,154,0,0,0,114,141,0,0,0,114,25,0,0,0,41, + 6,114,38,0,0,0,114,143,0,0,0,114,101,0,0,0, + 114,102,0,0,0,114,169,0,0,0,114,142,0,0,0,41, + 3,218,7,103,108,111,98,97,108,115,114,209,0,0,0,114, + 109,0,0,0,114,5,0,0,0,114,5,0,0,0,114,6, + 0,0,0,218,17,95,99,97,108,99,95,95,95,112,97,99, + 107,97,103,101,95,95,66,4,0,0,115,42,0,0,0,10, + 7,10,1,8,1,18,1,6,1,2,1,4,255,4,1,6, + 255,4,2,6,254,4,3,8,1,6,1,6,2,4,2,6, + 254,8,3,8,1,14,1,4,1,114,240,0,0,0,114,5, + 0,0,0,99,5,0,0,0,0,0,0,0,0,0,0,0, + 9,0,0,0,5,0,0,0,67,0,0,0,115,174,0,0, + 0,124,4,100,1,107,2,114,9,116,0,124,0,131,1,125, + 5,110,18,124,1,100,2,117,1,114,15,124,1,110,1,105, + 0,125,6,116,1,124,6,131,1,125,7,116,0,124,0,124, + 7,124,4,131,3,125,5,124,3,115,74,124,4,100,1,107, + 2,114,42,116,0,124,0,160,2,100,3,161,1,100,1,25, + 0,131,1,83,0,124,0,115,46,124,5,83,0,116,3,124, + 0,131,1,116,3,124,0,160,2,100,3,161,1,100,1,25, + 0,131,1,24,0,125,8,116,4,106,5,124,5,106,6,100, + 2,116,3,124,5,106,6,131,1,124,8,24,0,133,2,25, + 0,25,0,83,0,116,7,124,5,100,4,131,2,114,85,116, + 8,124,5,124,3,116,0,131,3,83,0,124,5,83,0,41, + 5,97,215,1,0,0,73,109,112,111,114,116,32,97,32,109, + 111,100,117,108,101,46,10,10,32,32,32,32,84,104,101,32, + 39,103,108,111,98,97,108,115,39,32,97,114,103,117,109,101, + 110,116,32,105,115,32,117,115,101,100,32,116,111,32,105,110, + 102,101,114,32,119,104,101,114,101,32,116,104,101,32,105,109, + 112,111,114,116,32,105,115,32,111,99,99,117,114,114,105,110, + 103,32,102,114,111,109,10,32,32,32,32,116,111,32,104,97, + 110,100,108,101,32,114,101,108,97,116,105,118,101,32,105,109, + 112,111,114,116,115,46,32,84,104,101,32,39,108,111,99,97, + 108,115,39,32,97,114,103,117,109,101,110,116,32,105,115,32, + 105,103,110,111,114,101,100,46,32,84,104,101,10,32,32,32, + 32,39,102,114,111,109,108,105,115,116,39,32,97,114,103,117, + 109,101,110,116,32,115,112,101,99,105,102,105,101,115,32,119, + 104,97,116,32,115,104,111,117,108,100,32,101,120,105,115,116, + 32,97,115,32,97,116,116,114,105,98,117,116,101,115,32,111, + 110,32,116,104,101,32,109,111,100,117,108,101,10,32,32,32, + 32,98,101,105,110,103,32,105,109,112,111,114,116,101,100,32, + 40,101,46,103,46,32,96,96,102,114,111,109,32,109,111,100, + 117,108,101,32,105,109,112,111,114,116,32,60,102,114,111,109, + 108,105,115,116,62,96,96,41,46,32,32,84,104,101,32,39, + 108,101,118,101,108,39,10,32,32,32,32,97,114,103,117,109, + 101,110,116,32,114,101,112,114,101,115,101,110,116,115,32,116, + 104,101,32,112,97,99,107,97,103,101,32,108,111,99,97,116, + 105,111,110,32,116,111,32,105,109,112,111,114,116,32,102,114, + 111,109,32,105,110,32,97,32,114,101,108,97,116,105,118,101, + 10,32,32,32,32,105,109,112,111,114,116,32,40,101,46,103, + 46,32,96,96,102,114,111,109,32,46,46,112,107,103,32,105, + 109,112,111,114,116,32,109,111,100,96,96,32,119,111,117,108, + 100,32,104,97,118,101,32,97,32,39,108,101,118,101,108,39, + 32,111,102,32,50,41,46,10,10,32,32,32,32,114,25,0, + 0,0,78,114,141,0,0,0,114,154,0,0,0,41,9,114, + 229,0,0,0,114,240,0,0,0,218,9,112,97,114,116,105, + 116,105,111,110,114,208,0,0,0,114,18,0,0,0,114,105, + 0,0,0,114,9,0,0,0,114,11,0,0,0,114,234,0, + 0,0,41,9,114,20,0,0,0,114,239,0,0,0,218,6, + 108,111,99,97,108,115,114,235,0,0,0,114,210,0,0,0, + 114,110,0,0,0,90,8,103,108,111,98,97,108,115,95,114, + 209,0,0,0,90,7,99,117,116,95,111,102,102,114,5,0, + 0,0,114,5,0,0,0,114,6,0,0,0,218,10,95,95, + 105,109,112,111,114,116,95,95,93,4,0,0,115,30,0,0, + 0,8,11,10,1,16,2,8,1,12,1,4,1,8,3,18, + 1,4,1,4,1,26,4,30,3,10,1,12,1,4,2,114, + 243,0,0,0,99,1,0,0,0,0,0,0,0,0,0,0, + 0,2,0,0,0,3,0,0,0,67,0,0,0,115,38,0, + 0,0,116,0,160,1,124,0,161,1,125,1,124,1,100,0, + 117,0,114,15,116,2,100,1,124,0,23,0,131,1,130,1, + 116,3,124,1,131,1,83,0,41,2,78,122,25,110,111,32, + 98,117,105,108,116,45,105,110,32,109,111,100,117,108,101,32, + 110,97,109,101,100,32,41,4,114,175,0,0,0,114,183,0, + 0,0,114,87,0,0,0,114,173,0,0,0,41,2,114,20, + 0,0,0,114,109,0,0,0,114,5,0,0,0,114,5,0, + 0,0,114,6,0,0,0,218,18,95,98,117,105,108,116,105, + 110,95,102,114,111,109,95,110,97,109,101,130,4,0,0,115, + 8,0,0,0,10,1,8,1,12,1,8,1,114,244,0,0, + 0,99,2,0,0,0,0,0,0,0,0,0,0,0,10,0, + 0,0,5,0,0,0,67,0,0,0,115,166,0,0,0,124, + 1,97,0,124,0,97,1,116,2,116,1,131,1,125,2,116, + 1,106,3,160,4,161,0,68,0,93,36,92,2,125,3,125, + 4,116,5,124,4,124,2,131,2,114,49,124,3,116,1,106, + 6,118,0,114,30,116,7,125,5,110,9,116,0,160,8,124, + 3,161,1,114,38,116,9,125,5,110,1,113,13,116,10,124, + 4,124,5,131,2,125,6,116,11,124,6,124,4,131,2,1, + 0,113,13,116,1,106,3,116,12,25,0,125,7,100,1,68, + 0,93,23,125,8,124,8,116,1,106,3,118,1,114,69,116, + 13,124,8,131,1,125,9,110,5,116,1,106,3,124,8,25, + 0,125,9,116,14,124,7,124,8,124,9,131,3,1,0,113, + 57,100,2,83,0,41,3,122,250,83,101,116,117,112,32,105, + 109,112,111,114,116,108,105,98,32,98,121,32,105,109,112,111, + 114,116,105,110,103,32,110,101,101,100,101,100,32,98,117,105, + 108,116,45,105,110,32,109,111,100,117,108,101,115,32,97,110, + 100,32,105,110,106,101,99,116,105,110,103,32,116,104,101,109, + 10,32,32,32,32,105,110,116,111,32,116,104,101,32,103,108, + 111,98,97,108,32,110,97,109,101,115,112,97,99,101,46,10, + 10,32,32,32,32,65,115,32,115,121,115,32,105,115,32,110, + 101,101,100,101,100,32,102,111,114,32,115,121,115,46,109,111, + 100,117,108,101,115,32,97,99,99,101,115,115,32,97,110,100, + 32,95,105,109,112,32,105,115,32,110,101,101,100,101,100,32, + 116,111,32,108,111,97,100,32,98,117,105,108,116,45,105,110, + 10,32,32,32,32,109,111,100,117,108,101,115,44,32,116,104, + 111,115,101,32,116,119,111,32,109,111,100,117,108,101,115,32, + 109,117,115,116,32,98,101,32,101,120,112,108,105,99,105,116, + 108,121,32,112,97,115,115,101,100,32,105,110,46,10,10,32, + 32,32,32,41,3,114,26,0,0,0,114,101,0,0,0,114, + 71,0,0,0,78,41,15,114,64,0,0,0,114,18,0,0, + 0,114,3,0,0,0,114,105,0,0,0,218,5,105,116,101, + 109,115,114,216,0,0,0,114,86,0,0,0,114,175,0,0, + 0,114,98,0,0,0,114,193,0,0,0,114,155,0,0,0, + 114,161,0,0,0,114,9,0,0,0,114,244,0,0,0,114, + 12,0,0,0,41,10,218,10,115,121,115,95,109,111,100,117, + 108,101,218,11,95,105,109,112,95,109,111,100,117,108,101,90, + 11,109,111,100,117,108,101,95,116,121,112,101,114,20,0,0, + 0,114,110,0,0,0,114,122,0,0,0,114,109,0,0,0, + 90,11,115,101,108,102,95,109,111,100,117,108,101,90,12,98, + 117,105,108,116,105,110,95,110,97,109,101,90,14,98,117,105, + 108,116,105,110,95,109,111,100,117,108,101,114,5,0,0,0, + 114,5,0,0,0,114,6,0,0,0,218,6,95,115,101,116, + 117,112,137,4,0,0,115,40,0,0,0,4,9,4,1,8, + 3,18,1,10,1,10,1,6,1,10,1,6,1,2,2,10, + 1,10,1,2,128,10,3,8,1,10,1,10,1,10,2,14, + 1,4,251,114,248,0,0,0,99,2,0,0,0,0,0,0, + 0,0,0,0,0,2,0,0,0,3,0,0,0,67,0,0, + 0,115,38,0,0,0,116,0,124,0,124,1,131,2,1,0, + 116,1,106,2,160,3,116,4,161,1,1,0,116,1,106,2, + 160,3,116,5,161,1,1,0,100,1,83,0,41,2,122,48, + 73,110,115,116,97,108,108,32,105,109,112,111,114,116,101,114, + 115,32,102,111,114,32,98,117,105,108,116,105,110,32,97,110, + 100,32,102,114,111,122,101,110,32,109,111,100,117,108,101,115, + 78,41,6,114,248,0,0,0,114,18,0,0,0,114,214,0, + 0,0,114,132,0,0,0,114,175,0,0,0,114,193,0,0, + 0,41,2,114,246,0,0,0,114,247,0,0,0,114,5,0, + 0,0,114,5,0,0,0,114,6,0,0,0,218,8,95,105, + 110,115,116,97,108,108,172,4,0,0,115,6,0,0,0,10, + 2,12,2,16,1,114,249,0,0,0,99,0,0,0,0,0, + 0,0,0,0,0,0,0,1,0,0,0,4,0,0,0,67, + 0,0,0,115,32,0,0,0,100,1,100,2,108,0,125,0, + 124,0,97,1,124,0,160,2,116,3,106,4,116,5,25,0, + 161,1,1,0,100,2,83,0,41,3,122,57,73,110,115,116, + 97,108,108,32,105,109,112,111,114,116,101,114,115,32,116,104, + 97,116,32,114,101,113,117,105,114,101,32,101,120,116,101,114, + 110,97,108,32,102,105,108,101,115,121,115,116,101,109,32,97, + 99,99,101,115,115,114,25,0,0,0,78,41,6,218,26,95, + 102,114,111,122,101,110,95,105,109,112,111,114,116,108,105,98, + 95,101,120,116,101,114,110,97,108,114,139,0,0,0,114,249, + 0,0,0,114,18,0,0,0,114,105,0,0,0,114,9,0, + 0,0,41,1,114,250,0,0,0,114,5,0,0,0,114,5, + 0,0,0,114,6,0,0,0,218,27,95,105,110,115,116,97, + 108,108,95,101,120,116,101,114,110,97,108,95,105,109,112,111, + 114,116,101,114,115,180,4,0,0,115,6,0,0,0,8,3, + 4,1,20,1,114,251,0,0,0,114,190,0,0,0,114,0, + 0,0,0,114,24,0,0,0,41,4,78,78,114,5,0,0, + 0,114,25,0,0,0,41,54,114,10,0,0,0,114,7,0, + 0,0,114,26,0,0,0,114,101,0,0,0,114,71,0,0, + 0,114,139,0,0,0,114,17,0,0,0,114,21,0,0,0, + 114,66,0,0,0,114,37,0,0,0,114,47,0,0,0,114, + 22,0,0,0,114,23,0,0,0,114,55,0,0,0,114,57, + 0,0,0,114,60,0,0,0,114,72,0,0,0,114,74,0, + 0,0,114,83,0,0,0,114,95,0,0,0,114,100,0,0, + 0,114,111,0,0,0,114,124,0,0,0,114,125,0,0,0, + 114,104,0,0,0,114,155,0,0,0,114,161,0,0,0,114, + 165,0,0,0,114,119,0,0,0,114,106,0,0,0,114,172, + 0,0,0,114,173,0,0,0,114,107,0,0,0,114,175,0, + 0,0,114,193,0,0,0,114,200,0,0,0,114,211,0,0, + 0,114,213,0,0,0,114,215,0,0,0,114,221,0,0,0, + 90,15,95,69,82,82,95,77,83,71,95,80,82,69,70,73, + 88,114,223,0,0,0,114,226,0,0,0,218,6,111,98,106, + 101,99,116,114,227,0,0,0,114,228,0,0,0,114,229,0, + 0,0,114,234,0,0,0,114,240,0,0,0,114,243,0,0, + 0,114,244,0,0,0,114,248,0,0,0,114,249,0,0,0, + 114,251,0,0,0,114,5,0,0,0,114,5,0,0,0,114, + 5,0,0,0,114,6,0,0,0,218,8,60,109,111,100,117, + 108,101,62,1,0,0,0,115,104,0,0,0,4,0,8,22, + 4,9,4,1,4,1,4,3,8,3,8,8,4,8,4,2, + 16,3,14,4,14,77,14,21,8,16,8,37,8,17,14,11, + 8,8,8,11,8,12,8,19,14,26,16,101,10,26,14,45, + 8,72,8,17,8,17,8,30,8,36,8,45,14,15,14,80, + 14,85,8,13,8,9,10,10,8,47,4,16,8,1,8,2, + 6,32,8,3,10,16,14,15,8,37,10,27,8,37,8,7, + 8,35,12,8, }; diff --git a/contrib/tools/python3/src/Python/importlib_external.h b/contrib/tools/python3/src/Python/importlib_external.h index 23af2cd20b9..dcf5505fa74 100644 --- a/contrib/tools/python3/src/Python/importlib_external.h +++ b/contrib/tools/python3/src/Python/importlib_external.h @@ -1,628 +1,626 @@ /* Auto-generated by Programs/_freeze_importlib.c */ const unsigned char _Py_M__importlib_bootstrap_external[] = { 99,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,5,0,0,0,64,0,0,0,115,224,2,0,0,100,0, - 90,0,100,1,100,2,108,1,97,1,100,1,100,2,108,2, - 90,2,100,1,100,2,108,3,97,3,100,1,100,2,108,4, - 90,4,100,1,100,2,108,5,90,5,116,3,106,6,100,3, - 107,2,90,7,101,7,114,76,100,1,100,2,108,8,90,9, - 100,1,100,2,108,10,90,10,110,8,100,1,100,2,108,11, - 90,9,101,7,114,98,100,4,100,5,103,2,90,12,110,6, - 100,5,103,1,90,12,101,13,100,6,100,7,132,0,101,12, - 68,0,131,1,131,1,115,126,74,0,130,1,101,12,100,1, - 25,0,90,14,101,15,101,12,131,1,90,16,100,8,160,17, - 101,12,161,1,90,12,100,9,100,10,132,0,101,12,68,0, - 131,1,90,18,100,11,90,19,100,12,90,20,101,20,101,19, - 23,0,90,21,100,13,100,14,132,0,90,22,100,15,100,16, - 132,0,90,23,100,17,100,18,132,0,90,24,100,19,100,20, - 132,0,90,25,101,7,114,228,100,21,100,22,132,0,90,26, - 110,8,100,23,100,22,132,0,90,26,100,24,100,25,132,0, - 90,27,100,26,100,27,132,0,90,28,100,28,100,29,132,0, - 90,29,100,30,100,31,132,0,90,30,100,32,100,33,132,0, - 90,31,101,7,144,1,114,36,100,34,100,35,132,0,90,32, - 110,8,100,36,100,35,132,0,90,32,100,111,100,38,100,39, - 132,1,90,33,101,34,101,33,106,35,131,1,90,36,100,40, - 160,37,100,41,100,42,161,2,100,43,23,0,90,38,101,39, - 160,40,101,38,100,42,161,2,90,41,100,44,90,42,100,45, - 90,43,100,46,103,1,90,44,100,47,103,1,90,45,101,45, - 4,0,90,46,90,47,100,112,100,2,100,48,156,1,100,49, - 100,50,132,3,90,48,100,51,100,52,132,0,90,49,100,53, - 100,54,132,0,90,50,100,55,100,56,132,0,90,51,100,57, - 100,58,132,0,90,52,100,59,100,60,132,0,90,53,100,61, - 100,62,132,0,90,54,100,63,100,64,132,0,90,55,100,65, - 100,66,132,0,90,56,100,67,100,68,132,0,90,57,100,113, - 100,69,100,70,132,1,90,58,100,114,100,71,100,72,132,1, - 90,59,100,115,100,74,100,75,132,1,90,60,100,76,100,77, - 132,0,90,61,101,62,131,0,90,63,100,116,100,2,101,63, - 100,78,156,2,100,79,100,80,132,3,90,64,71,0,100,81, - 100,82,132,0,100,82,131,2,90,65,71,0,100,83,100,84, - 132,0,100,84,131,2,90,66,71,0,100,85,100,86,132,0, - 100,86,101,66,131,3,90,67,71,0,100,87,100,88,132,0, - 100,88,131,2,90,68,71,0,100,89,100,90,132,0,100,90, - 101,68,101,67,131,4,90,69,71,0,100,91,100,92,132,0, - 100,92,101,68,101,66,131,4,90,70,103,0,90,71,71,0, - 100,93,100,94,132,0,100,94,101,68,101,66,131,4,90,72, - 71,0,100,95,100,96,132,0,100,96,131,2,90,73,71,0, - 100,97,100,98,132,0,100,98,131,2,90,74,71,0,100,99, - 100,100,132,0,100,100,131,2,90,75,71,0,100,101,100,102, - 132,0,100,102,131,2,90,76,100,117,100,103,100,104,132,1, - 90,77,100,105,100,106,132,0,90,78,100,107,100,108,132,0, - 90,79,100,109,100,110,132,0,90,80,100,2,83,0,41,118, - 97,94,1,0,0,67,111,114,101,32,105,109,112,108,101,109, - 101,110,116,97,116,105,111,110,32,111,102,32,112,97,116,104, - 45,98,97,115,101,100,32,105,109,112,111,114,116,46,10,10, - 84,104,105,115,32,109,111,100,117,108,101,32,105,115,32,78, - 79,84,32,109,101,97,110,116,32,116,111,32,98,101,32,100, - 105,114,101,99,116,108,121,32,105,109,112,111,114,116,101,100, - 33,32,73,116,32,104,97,115,32,98,101,101,110,32,100,101, - 115,105,103,110,101,100,32,115,117,99,104,10,116,104,97,116, - 32,105,116,32,99,97,110,32,98,101,32,98,111,111,116,115, - 116,114,97,112,112,101,100,32,105,110,116,111,32,80,121,116, - 104,111,110,32,97,115,32,116,104,101,32,105,109,112,108,101, - 109,101,110,116,97,116,105,111,110,32,111,102,32,105,109,112, - 111,114,116,46,32,65,115,10,115,117,99,104,32,105,116,32, - 114,101,113,117,105,114,101,115,32,116,104,101,32,105,110,106, - 101,99,116,105,111,110,32,111,102,32,115,112,101,99,105,102, - 105,99,32,109,111,100,117,108,101,115,32,97,110,100,32,97, - 116,116,114,105,98,117,116,101,115,32,105,110,32,111,114,100, - 101,114,32,116,111,10,119,111,114,107,46,32,79,110,101,32, - 115,104,111,117,108,100,32,117,115,101,32,105,109,112,111,114, - 116,108,105,98,32,97,115,32,116,104,101,32,112,117,98,108, - 105,99,45,102,97,99,105,110,103,32,118,101,114,115,105,111, - 110,32,111,102,32,116,104,105,115,32,109,111,100,117,108,101, - 46,10,10,233,0,0,0,0,78,90,5,119,105,110,51,50, - 250,1,92,250,1,47,99,1,0,0,0,0,0,0,0,0, - 0,0,0,2,0,0,0,3,0,0,0,99,0,0,0,115, - 26,0,0,0,124,0,93,18,125,1,116,0,124,1,131,1, - 100,0,107,2,86,0,1,0,113,2,100,1,83,0,169,2, - 233,1,0,0,0,78,169,1,218,3,108,101,110,169,2,218, - 2,46,48,218,3,115,101,112,169,0,114,10,0,0,0,250, - 38,60,102,114,111,122,101,110,32,105,109,112,111,114,116,108, - 105,98,46,95,98,111,111,116,115,116,114,97,112,95,101,120, - 116,101,114,110,97,108,62,218,9,60,103,101,110,101,120,112, - 114,62,43,0,0,0,243,0,0,0,0,114,12,0,0,0, + 0,5,0,0,0,64,0,0,0,115,250,2,0,0,100,0, + 90,0,100,1,97,1,100,2,100,1,108,2,90,2,100,2, + 100,1,108,3,90,3,100,2,100,1,108,4,90,4,100,2, + 100,1,108,5,90,5,100,2,100,1,108,6,90,6,101,4, + 106,7,100,3,107,2,90,8,101,8,114,40,100,2,100,1, + 108,9,90,10,100,2,100,1,108,11,90,11,110,4,100,2, + 100,1,108,12,90,10,101,8,114,51,100,4,100,5,103,2, + 90,13,110,3,100,5,103,1,90,13,101,14,100,6,100,7, + 132,0,101,13,68,0,131,1,131,1,115,65,74,0,130,1, + 101,13,100,2,25,0,90,15,101,16,101,13,131,1,90,17, + 100,8,160,18,101,13,161,1,90,13,100,9,100,10,132,0, + 101,13,68,0,131,1,90,19,100,11,90,20,100,12,90,21, + 101,21,101,20,23,0,90,22,100,13,100,14,132,0,90,23, + 101,23,131,0,90,24,100,15,100,16,132,0,90,25,100,17, + 100,18,132,0,90,26,100,19,100,20,132,0,90,27,101,8, + 114,119,100,21,100,22,132,0,90,28,110,4,100,23,100,22, + 132,0,90,28,100,24,100,25,132,0,90,29,100,26,100,27, + 132,0,90,30,100,28,100,29,132,0,90,31,100,30,100,31, + 132,0,90,32,100,32,100,33,132,0,90,33,101,8,114,150, + 100,34,100,35,132,0,90,34,110,4,100,36,100,35,132,0, + 90,34,100,112,100,38,100,39,132,1,90,35,101,36,101,35, + 106,37,131,1,90,38,100,40,160,39,100,41,100,42,161,2, + 100,43,23,0,90,40,101,41,160,42,101,40,100,42,161,2, + 90,43,100,44,90,44,100,45,90,45,100,46,103,1,90,46, + 101,8,114,192,101,46,160,47,100,47,161,1,1,0,101,2, + 160,48,161,0,90,49,100,48,103,1,90,50,101,50,4,0, + 90,51,90,52,100,113,100,1,100,49,156,1,100,50,100,51, + 132,3,90,53,100,52,100,53,132,0,90,54,100,54,100,55, + 132,0,90,55,100,56,100,57,132,0,90,56,100,58,100,59, + 132,0,90,57,100,60,100,61,132,0,90,58,100,62,100,63, + 132,0,90,59,100,64,100,65,132,0,90,60,100,66,100,67, + 132,0,90,61,100,68,100,69,132,0,90,62,100,114,100,70, + 100,71,132,1,90,63,100,115,100,72,100,73,132,1,90,64, + 100,116,100,75,100,76,132,1,90,65,100,77,100,78,132,0, + 90,66,101,67,131,0,90,68,100,113,100,1,101,68,100,79, + 156,2,100,80,100,81,132,3,90,69,71,0,100,82,100,83, + 132,0,100,83,131,2,90,70,71,0,100,84,100,85,132,0, + 100,85,131,2,90,71,71,0,100,86,100,87,132,0,100,87, + 101,71,131,3,90,72,71,0,100,88,100,89,132,0,100,89, + 131,2,90,73,71,0,100,90,100,91,132,0,100,91,101,73, + 101,72,131,4,90,74,71,0,100,92,100,93,132,0,100,93, + 101,73,101,71,131,4,90,75,71,0,100,94,100,95,132,0, + 100,95,101,73,101,71,131,4,90,76,71,0,100,96,100,97, + 132,0,100,97,131,2,90,77,71,0,100,98,100,99,132,0, + 100,99,131,2,90,78,71,0,100,100,100,101,132,0,100,101, + 131,2,90,79,71,0,100,102,100,103,132,0,100,103,131,2, + 90,80,100,113,100,104,100,105,132,1,90,81,100,106,100,107, + 132,0,90,82,100,108,100,109,132,0,90,83,100,110,100,111, + 132,0,90,84,100,1,83,0,41,117,97,94,1,0,0,67, + 111,114,101,32,105,109,112,108,101,109,101,110,116,97,116,105, + 111,110,32,111,102,32,112,97,116,104,45,98,97,115,101,100, + 32,105,109,112,111,114,116,46,10,10,84,104,105,115,32,109, + 111,100,117,108,101,32,105,115,32,78,79,84,32,109,101,97, + 110,116,32,116,111,32,98,101,32,100,105,114,101,99,116,108, + 121,32,105,109,112,111,114,116,101,100,33,32,73,116,32,104, + 97,115,32,98,101,101,110,32,100,101,115,105,103,110,101,100, + 32,115,117,99,104,10,116,104,97,116,32,105,116,32,99,97, + 110,32,98,101,32,98,111,111,116,115,116,114,97,112,112,101, + 100,32,105,110,116,111,32,80,121,116,104,111,110,32,97,115, + 32,116,104,101,32,105,109,112,108,101,109,101,110,116,97,116, + 105,111,110,32,111,102,32,105,109,112,111,114,116,46,32,65, + 115,10,115,117,99,104,32,105,116,32,114,101,113,117,105,114, + 101,115,32,116,104,101,32,105,110,106,101,99,116,105,111,110, + 32,111,102,32,115,112,101,99,105,102,105,99,32,109,111,100, + 117,108,101,115,32,97,110,100,32,97,116,116,114,105,98,117, + 116,101,115,32,105,110,32,111,114,100,101,114,32,116,111,10, + 119,111,114,107,46,32,79,110,101,32,115,104,111,117,108,100, + 32,117,115,101,32,105,109,112,111,114,116,108,105,98,32,97, + 115,32,116,104,101,32,112,117,98,108,105,99,45,102,97,99, + 105,110,103,32,118,101,114,115,105,111,110,32,111,102,32,116, + 104,105,115,32,109,111,100,117,108,101,46,10,10,78,233,0, + 0,0,0,90,5,119,105,110,51,50,250,1,92,250,1,47, + 99,1,0,0,0,0,0,0,0,0,0,0,0,2,0,0, + 0,3,0,0,0,99,0,0,0,115,28,0,0,0,129,0, + 124,0,93,9,125,1,116,0,124,1,131,1,100,0,107,2, + 86,0,1,0,113,2,100,1,83,0,41,2,233,1,0,0, + 0,78,41,1,218,3,108,101,110,41,2,218,2,46,48,218, + 3,115,101,112,169,0,114,7,0,0,0,250,38,60,102,114, + 111,122,101,110,32,105,109,112,111,114,116,108,105,98,46,95, + 98,111,111,116,115,116,114,97,112,95,101,120,116,101,114,110, + 97,108,62,218,9,60,103,101,110,101,120,112,114,62,46,0, + 0,0,115,4,0,0,0,2,128,26,0,114,9,0,0,0, 218,0,99,1,0,0,0,0,0,0,0,0,0,0,0,2, 0,0,0,4,0,0,0,67,0,0,0,115,22,0,0,0, - 104,0,124,0,93,14,125,1,100,0,124,1,155,0,157,2, - 146,2,113,4,83,0,169,1,250,1,58,114,10,0,0,0, - 169,2,114,8,0,0,0,218,1,115,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,218,9,60,115,101,116,99, - 111,109,112,62,47,0,0,0,114,13,0,0,0,114,19,0, - 0,0,41,1,218,3,119,105,110,41,2,90,6,99,121,103, - 119,105,110,90,6,100,97,114,119,105,110,99,0,0,0,0, - 0,0,0,0,0,0,0,0,1,0,0,0,3,0,0,0, - 3,0,0,0,115,60,0,0,0,116,0,106,1,160,2,116, - 3,161,1,114,48,116,0,106,1,160,2,116,4,161,1,114, - 30,100,1,137,0,110,4,100,2,137,0,135,0,102,1,100, - 3,100,4,132,8,125,0,110,8,100,5,100,4,132,0,125, - 0,124,0,83,0,41,6,78,90,12,80,89,84,72,79,78, - 67,65,83,69,79,75,115,12,0,0,0,80,89,84,72,79, - 78,67,65,83,69,79,75,99,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,0,0,2,0,0,0,19,0,0,0, - 115,20,0,0,0,116,0,106,1,106,2,12,0,111,18,136, - 0,116,3,106,4,118,0,83,0,41,1,122,94,84,114,117, - 101,32,105,102,32,102,105,108,101,110,97,109,101,115,32,109, - 117,115,116,32,98,101,32,99,104,101,99,107,101,100,32,99, - 97,115,101,45,105,110,115,101,110,115,105,116,105,118,101,108, - 121,32,97,110,100,32,105,103,110,111,114,101,32,101,110,118, - 105,114,111,110,109,101,110,116,32,102,108,97,103,115,32,97, - 114,101,32,110,111,116,32,115,101,116,46,41,5,218,3,115, - 121,115,218,5,102,108,97,103,115,218,18,105,103,110,111,114, - 101,95,101,110,118,105,114,111,110,109,101,110,116,218,3,95, - 111,115,90,7,101,110,118,105,114,111,110,114,10,0,0,0, - 169,1,218,3,107,101,121,114,10,0,0,0,114,11,0,0, - 0,218,11,95,114,101,108,97,120,95,99,97,115,101,64,0, - 0,0,115,2,0,0,0,0,2,122,37,95,109,97,107,101, - 95,114,101,108,97,120,95,99,97,115,101,46,60,108,111,99, - 97,108,115,62,46,95,114,101,108,97,120,95,99,97,115,101, - 99,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,1,0,0,0,83,0,0,0,115,4,0,0,0,100,1, - 83,0,41,2,122,53,84,114,117,101,32,105,102,32,102,105, - 108,101,110,97,109,101,115,32,109,117,115,116,32,98,101,32, - 99,104,101,99,107,101,100,32,99,97,115,101,45,105,110,115, - 101,110,115,105,116,105,118,101,108,121,46,70,114,10,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,27,0,0,0,68,0,0,0,115,2, - 0,0,0,0,2,41,5,114,21,0,0,0,218,8,112,108, - 97,116,102,111,114,109,218,10,115,116,97,114,116,115,119,105, - 116,104,218,27,95,67,65,83,69,95,73,78,83,69,78,83, - 73,84,73,86,69,95,80,76,65,84,70,79,82,77,83,218, - 35,95,67,65,83,69,95,73,78,83,69,78,83,73,84,73, - 86,69,95,80,76,65,84,70,79,82,77,83,95,83,84,82, - 95,75,69,89,41,1,114,27,0,0,0,114,10,0,0,0, - 114,25,0,0,0,114,11,0,0,0,218,16,95,109,97,107, - 101,95,114,101,108,97,120,95,99,97,115,101,57,0,0,0, - 115,14,0,0,0,0,1,12,1,12,1,6,2,4,2,14, - 4,8,3,114,32,0,0,0,99,1,0,0,0,0,0,0, - 0,0,0,0,0,1,0,0,0,4,0,0,0,67,0,0, - 0,115,20,0,0,0,116,0,124,0,131,1,100,1,64,0, - 160,1,100,2,100,3,161,2,83,0,41,4,122,42,67,111, - 110,118,101,114,116,32,97,32,51,50,45,98,105,116,32,105, - 110,116,101,103,101,114,32,116,111,32,108,105,116,116,108,101, - 45,101,110,100,105,97,110,46,236,3,0,0,0,255,127,255, - 127,3,0,233,4,0,0,0,218,6,108,105,116,116,108,101, - 41,2,218,3,105,110,116,218,8,116,111,95,98,121,116,101, - 115,41,1,218,1,120,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,12,95,112,97,99,107,95,117,105,110, - 116,51,50,74,0,0,0,115,2,0,0,0,0,2,114,39, - 0,0,0,99,1,0,0,0,0,0,0,0,0,0,0,0, - 1,0,0,0,4,0,0,0,67,0,0,0,115,28,0,0, - 0,116,0,124,0,131,1,100,1,107,2,115,16,74,0,130, - 1,116,1,160,2,124,0,100,2,161,2,83,0,41,3,122, - 47,67,111,110,118,101,114,116,32,52,32,98,121,116,101,115, + 104,0,124,0,93,7,125,1,100,0,124,1,155,0,157,2, + 146,2,113,2,83,0,41,1,250,1,58,114,7,0,0,0, + 41,2,114,5,0,0,0,218,1,115,114,7,0,0,0,114, + 7,0,0,0,114,8,0,0,0,218,9,60,115,101,116,99, + 111,109,112,62,50,0,0,0,115,2,0,0,0,22,0,114, + 13,0,0,0,41,1,218,3,119,105,110,41,2,90,6,99, + 121,103,119,105,110,90,6,100,97,114,119,105,110,99,0,0, + 0,0,0,0,0,0,0,0,0,0,1,0,0,0,3,0, + 0,0,3,0,0,0,115,62,0,0,0,116,0,106,1,160, + 2,116,3,161,1,114,25,116,0,106,1,160,2,116,4,161, + 1,114,15,100,1,137,0,110,2,100,2,137,0,135,0,102, + 1,100,3,100,4,132,8,125,0,124,0,83,0,100,5,100, + 4,132,0,125,0,124,0,83,0,41,6,78,90,12,80,89, + 84,72,79,78,67,65,83,69,79,75,115,12,0,0,0,80, + 89,84,72,79,78,67,65,83,69,79,75,99,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0, + 19,0,0,0,115,20,0,0,0,116,0,106,1,106,2,12, + 0,111,9,136,0,116,3,106,4,118,0,83,0,41,1,122, + 94,84,114,117,101,32,105,102,32,102,105,108,101,110,97,109, + 101,115,32,109,117,115,116,32,98,101,32,99,104,101,99,107, + 101,100,32,99,97,115,101,45,105,110,115,101,110,115,105,116, + 105,118,101,108,121,32,97,110,100,32,105,103,110,111,114,101, + 32,101,110,118,105,114,111,110,109,101,110,116,32,102,108,97, + 103,115,32,97,114,101,32,110,111,116,32,115,101,116,46,41, + 5,218,3,115,121,115,218,5,102,108,97,103,115,218,18,105, + 103,110,111,114,101,95,101,110,118,105,114,111,110,109,101,110, + 116,218,3,95,111,115,90,7,101,110,118,105,114,111,110,114, + 7,0,0,0,169,1,218,3,107,101,121,114,7,0,0,0, + 114,8,0,0,0,218,11,95,114,101,108,97,120,95,99,97, + 115,101,67,0,0,0,243,2,0,0,0,20,2,122,37,95, + 109,97,107,101,95,114,101,108,97,120,95,99,97,115,101,46, + 60,108,111,99,97,108,115,62,46,95,114,101,108,97,120,95, + 99,97,115,101,99,0,0,0,0,0,0,0,0,0,0,0, + 0,0,0,0,0,1,0,0,0,83,0,0,0,243,4,0, + 0,0,100,1,83,0,41,2,122,53,84,114,117,101,32,105, + 102,32,102,105,108,101,110,97,109,101,115,32,109,117,115,116, + 32,98,101,32,99,104,101,99,107,101,100,32,99,97,115,101, + 45,105,110,115,101,110,115,105,116,105,118,101,108,121,46,70, + 114,7,0,0,0,114,7,0,0,0,114,7,0,0,0,114, + 7,0,0,0,114,8,0,0,0,114,21,0,0,0,71,0, + 0,0,243,2,0,0,0,4,2,41,5,114,15,0,0,0, + 218,8,112,108,97,116,102,111,114,109,218,10,115,116,97,114, + 116,115,119,105,116,104,218,27,95,67,65,83,69,95,73,78, + 83,69,78,83,73,84,73,86,69,95,80,76,65,84,70,79, + 82,77,83,218,35,95,67,65,83,69,95,73,78,83,69,78, + 83,73,84,73,86,69,95,80,76,65,84,70,79,82,77,83, + 95,83,84,82,95,75,69,89,41,1,114,21,0,0,0,114, + 7,0,0,0,114,19,0,0,0,114,8,0,0,0,218,16, + 95,109,97,107,101,95,114,101,108,97,120,95,99,97,115,101, + 60,0,0,0,115,16,0,0,0,12,1,12,1,6,1,4, + 2,12,2,4,7,8,253,4,3,114,29,0,0,0,99,1, + 0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,4, + 0,0,0,67,0,0,0,115,20,0,0,0,116,0,124,0, + 131,1,100,1,64,0,160,1,100,2,100,3,161,2,83,0, + 41,4,122,42,67,111,110,118,101,114,116,32,97,32,51,50, + 45,98,105,116,32,105,110,116,101,103,101,114,32,116,111,32, + 108,105,116,116,108,101,45,101,110,100,105,97,110,46,236,3, + 0,0,0,255,127,255,127,3,0,233,4,0,0,0,218,6, + 108,105,116,116,108,101,41,2,218,3,105,110,116,218,8,116, + 111,95,98,121,116,101,115,41,1,218,1,120,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,218,12,95,112,97, + 99,107,95,117,105,110,116,51,50,79,0,0,0,114,22,0, + 0,0,114,36,0,0,0,99,1,0,0,0,0,0,0,0, + 0,0,0,0,1,0,0,0,4,0,0,0,67,0,0,0, + 243,28,0,0,0,116,0,124,0,131,1,100,1,107,2,115, + 8,74,0,130,1,116,1,160,2,124,0,100,2,161,2,83, + 0,41,3,122,47,67,111,110,118,101,114,116,32,52,32,98, + 121,116,101,115,32,105,110,32,108,105,116,116,108,101,45,101, + 110,100,105,97,110,32,116,111,32,97,110,32,105,110,116,101, + 103,101,114,46,114,31,0,0,0,114,32,0,0,0,169,3, + 114,4,0,0,0,114,33,0,0,0,218,10,102,114,111,109, + 95,98,121,116,101,115,169,1,218,4,100,97,116,97,114,7, + 0,0,0,114,7,0,0,0,114,8,0,0,0,218,14,95, + 117,110,112,97,99,107,95,117,105,110,116,51,50,84,0,0, + 0,243,4,0,0,0,16,2,12,1,114,42,0,0,0,99, + 1,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0, + 4,0,0,0,67,0,0,0,114,37,0,0,0,41,3,122, + 47,67,111,110,118,101,114,116,32,50,32,98,121,116,101,115, 32,105,110,32,108,105,116,116,108,101,45,101,110,100,105,97, 110,32,116,111,32,97,110,32,105,110,116,101,103,101,114,46, - 114,34,0,0,0,114,35,0,0,0,169,3,114,6,0,0, - 0,114,36,0,0,0,218,10,102,114,111,109,95,98,121,116, - 101,115,169,1,218,4,100,97,116,97,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,218,14,95,117,110,112,97, - 99,107,95,117,105,110,116,51,50,79,0,0,0,115,4,0, - 0,0,0,2,16,1,114,44,0,0,0,99,1,0,0,0, - 0,0,0,0,0,0,0,0,1,0,0,0,4,0,0,0, - 67,0,0,0,115,28,0,0,0,116,0,124,0,131,1,100, - 1,107,2,115,16,74,0,130,1,116,1,160,2,124,0,100, - 2,161,2,83,0,41,3,122,47,67,111,110,118,101,114,116, - 32,50,32,98,121,116,101,115,32,105,110,32,108,105,116,116, - 108,101,45,101,110,100,105,97,110,32,116,111,32,97,110,32, - 105,110,116,101,103,101,114,46,233,2,0,0,0,114,35,0, - 0,0,114,40,0,0,0,114,42,0,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,218,14,95,117,110, - 112,97,99,107,95,117,105,110,116,49,54,84,0,0,0,115, - 4,0,0,0,0,2,16,1,114,46,0,0,0,99,0,0, - 0,0,0,0,0,0,0,0,0,0,5,0,0,0,4,0, - 0,0,71,0,0,0,115,228,0,0,0,124,0,115,8,100, - 1,83,0,116,0,124,0,131,1,100,2,107,2,114,28,124, - 0,100,3,25,0,83,0,100,1,125,1,103,0,125,2,116, - 1,116,2,106,3,124,0,131,2,68,0,93,122,92,2,125, - 3,125,4,124,3,160,4,116,5,161,1,115,76,124,3,160, - 6,116,5,161,1,114,102,124,3,160,7,116,8,161,1,112, - 88,124,1,125,1,116,9,124,4,23,0,103,1,125,2,113, - 48,124,3,160,6,100,4,161,1,114,152,124,1,160,10,161, - 0,124,3,160,10,161,0,107,3,114,140,124,3,125,1,124, - 4,103,1,125,2,113,170,124,2,160,11,124,4,161,1,1, - 0,113,48,124,3,112,158,124,1,125,1,124,2,160,11,124, - 4,161,1,1,0,113,48,100,5,100,6,132,0,124,2,68, - 0,131,1,125,2,116,0,124,2,131,1,100,2,107,2,114, - 214,124,2,100,3,25,0,115,214,124,1,116,9,23,0,83, - 0,124,1,116,9,160,12,124,2,161,1,23,0,83,0,41, - 7,250,31,82,101,112,108,97,99,101,109,101,110,116,32,102, - 111,114,32,111,115,46,112,97,116,104,46,106,111,105,110,40, - 41,46,114,14,0,0,0,114,4,0,0,0,114,0,0,0, - 0,114,16,0,0,0,99,1,0,0,0,0,0,0,0,0, - 0,0,0,2,0,0,0,5,0,0,0,83,0,0,0,115, - 26,0,0,0,103,0,124,0,93,18,125,1,124,1,114,4, - 124,1,160,0,116,1,161,1,145,2,113,4,83,0,114,10, - 0,0,0,169,2,218,6,114,115,116,114,105,112,218,15,112, - 97,116,104,95,115,101,112,97,114,97,116,111,114,115,169,2, - 114,8,0,0,0,218,1,112,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,10,60,108,105,115,116,99,111, - 109,112,62,114,0,0,0,114,13,0,0,0,250,30,95,112, - 97,116,104,95,106,111,105,110,46,60,108,111,99,97,108,115, - 62,46,60,108,105,115,116,99,111,109,112,62,41,13,114,6, - 0,0,0,218,3,109,97,112,114,24,0,0,0,218,15,95, - 112,97,116,104,95,115,112,108,105,116,114,111,111,116,114,29, - 0,0,0,218,14,112,97,116,104,95,115,101,112,95,116,117, - 112,108,101,218,8,101,110,100,115,119,105,116,104,114,49,0, - 0,0,114,50,0,0,0,218,8,112,97,116,104,95,115,101, - 112,218,8,99,97,115,101,102,111,108,100,218,6,97,112,112, - 101,110,100,218,4,106,111,105,110,41,5,218,10,112,97,116, - 104,95,112,97,114,116,115,218,4,114,111,111,116,218,4,112, - 97,116,104,90,8,110,101,119,95,114,111,111,116,218,4,116, - 97,105,108,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,218,10,95,112,97,116,104,95,106,111,105,110,91,0, - 0,0,115,42,0,0,0,0,2,4,1,4,1,12,1,8, - 1,4,1,4,1,20,1,20,1,14,1,12,1,10,1,16, - 3,4,1,8,2,12,2,8,1,12,1,14,1,20,2,8, - 1,114,67,0,0,0,99,0,0,0,0,0,0,0,0,0, - 0,0,0,1,0,0,0,4,0,0,0,71,0,0,0,115, - 20,0,0,0,116,0,160,1,100,1,100,2,132,0,124,0, - 68,0,131,1,161,1,83,0,41,3,114,47,0,0,0,99, - 1,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0, - 5,0,0,0,83,0,0,0,115,26,0,0,0,103,0,124, - 0,93,18,125,1,124,1,114,4,124,1,160,0,116,1,161, - 1,145,2,113,4,83,0,114,10,0,0,0,114,48,0,0, - 0,41,2,114,8,0,0,0,218,4,112,97,114,116,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,114,53,0, - 0,0,123,0,0,0,115,4,0,0,0,6,1,6,255,114, - 54,0,0,0,41,2,114,59,0,0,0,114,62,0,0,0, - 41,1,114,63,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,114,67,0,0,0,121,0,0,0,115, - 6,0,0,0,0,2,10,1,2,255,99,1,0,0,0,0, - 0,0,0,0,0,0,0,2,0,0,0,4,0,0,0,3, - 0,0,0,115,66,0,0,0,116,0,135,0,102,1,100,1, - 100,2,132,8,116,1,68,0,131,1,131,1,125,1,124,1, - 100,3,107,0,114,38,100,4,136,0,102,2,83,0,136,0, - 100,5,124,1,133,2,25,0,136,0,124,1,100,6,23,0, - 100,5,133,2,25,0,102,2,83,0,41,7,122,32,82,101, - 112,108,97,99,101,109,101,110,116,32,102,111,114,32,111,115, - 46,112,97,116,104,46,115,112,108,105,116,40,41,46,99,1, - 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,4, - 0,0,0,51,0,0,0,115,24,0,0,0,124,0,93,16, + 233,2,0,0,0,114,32,0,0,0,114,38,0,0,0,114, + 40,0,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,218,14,95,117,110,112,97,99,107,95,117,105,110, + 116,49,54,89,0,0,0,114,43,0,0,0,114,45,0,0, + 0,99,0,0,0,0,0,0,0,0,0,0,0,0,5,0, + 0,0,4,0,0,0,71,0,0,0,115,228,0,0,0,124, + 0,115,4,100,1,83,0,116,0,124,0,131,1,100,2,107, + 2,114,14,124,0,100,3,25,0,83,0,100,1,125,1,103, + 0,125,2,116,1,116,2,106,3,124,0,131,2,68,0,93, + 61,92,2,125,3,125,4,124,3,160,4,116,5,161,1,115, + 38,124,3,160,6,116,5,161,1,114,51,124,3,160,7,116, + 8,161,1,112,44,124,1,125,1,116,9,124,4,23,0,103, + 1,125,2,113,24,124,3,160,6,100,4,161,1,114,76,124, + 1,160,10,161,0,124,3,160,10,161,0,107,3,114,70,124, + 3,125,1,124,4,103,1,125,2,113,24,124,2,160,11,124, + 4,161,1,1,0,113,24,124,3,112,79,124,1,125,1,124, + 2,160,11,124,4,161,1,1,0,113,24,100,5,100,6,132, + 0,124,2,68,0,131,1,125,2,116,0,124,2,131,1,100, + 2,107,2,114,107,124,2,100,3,25,0,115,107,124,1,116, + 9,23,0,83,0,124,1,116,9,160,12,124,2,161,1,23, + 0,83,0,41,7,250,31,82,101,112,108,97,99,101,109,101, + 110,116,32,102,111,114,32,111,115,46,112,97,116,104,46,106, + 111,105,110,40,41,46,114,10,0,0,0,114,3,0,0,0, + 114,0,0,0,0,114,11,0,0,0,99,1,0,0,0,0, + 0,0,0,0,0,0,0,2,0,0,0,5,0,0,0,83, + 0,0,0,243,26,0,0,0,103,0,124,0,93,9,125,1, + 124,1,114,2,124,1,160,0,116,1,161,1,145,2,113,2, + 83,0,114,7,0,0,0,169,2,218,6,114,115,116,114,105, + 112,218,15,112,97,116,104,95,115,101,112,97,114,97,116,111, + 114,115,169,2,114,5,0,0,0,218,1,112,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,218,10,60,108,105, + 115,116,99,111,109,112,62,119,0,0,0,115,2,0,0,0, + 26,0,250,30,95,112,97,116,104,95,106,111,105,110,46,60, + 108,111,99,97,108,115,62,46,60,108,105,115,116,99,111,109, + 112,62,41,13,114,4,0,0,0,218,3,109,97,112,114,18, + 0,0,0,218,15,95,112,97,116,104,95,115,112,108,105,116, + 114,111,111,116,114,26,0,0,0,218,14,112,97,116,104,95, + 115,101,112,95,116,117,112,108,101,218,8,101,110,100,115,119, + 105,116,104,114,49,0,0,0,114,50,0,0,0,218,8,112, + 97,116,104,95,115,101,112,218,8,99,97,115,101,102,111,108, + 100,218,6,97,112,112,101,110,100,218,4,106,111,105,110,41, + 5,218,10,112,97,116,104,95,112,97,114,116,115,218,4,114, + 111,111,116,218,4,112,97,116,104,90,8,110,101,119,95,114, + 111,111,116,218,4,116,97,105,108,114,7,0,0,0,114,7, + 0,0,0,114,8,0,0,0,218,10,95,112,97,116,104,95, + 106,111,105,110,96,0,0,0,115,42,0,0,0,4,2,4, + 1,12,1,8,1,4,1,4,1,20,1,20,1,14,1,12, + 1,10,1,16,1,4,3,8,1,12,2,8,2,12,1,14, + 1,20,1,8,2,14,1,114,67,0,0,0,99,0,0,0, + 0,0,0,0,0,0,0,0,0,1,0,0,0,4,0,0, + 0,71,0,0,0,115,20,0,0,0,116,0,160,1,100,1, + 100,2,132,0,124,0,68,0,131,1,161,1,83,0,41,3, + 114,46,0,0,0,99,1,0,0,0,0,0,0,0,0,0, + 0,0,2,0,0,0,5,0,0,0,83,0,0,0,114,47, + 0,0,0,114,7,0,0,0,114,48,0,0,0,41,2,114, + 5,0,0,0,218,4,112,97,114,116,114,7,0,0,0,114, + 7,0,0,0,114,8,0,0,0,114,53,0,0,0,128,0, + 0,0,115,6,0,0,0,6,0,4,1,16,255,114,54,0, + 0,0,41,2,114,59,0,0,0,114,62,0,0,0,41,1, + 114,63,0,0,0,114,7,0,0,0,114,7,0,0,0,114, + 8,0,0,0,114,67,0,0,0,126,0,0,0,115,6,0, + 0,0,10,2,2,1,8,255,99,1,0,0,0,0,0,0, + 0,0,0,0,0,2,0,0,0,4,0,0,0,3,0,0, + 0,115,66,0,0,0,116,0,135,0,102,1,100,1,100,2, + 132,8,116,1,68,0,131,1,131,1,125,1,124,1,100,3, + 107,0,114,19,100,4,136,0,102,2,83,0,136,0,100,5, + 124,1,133,2,25,0,136,0,124,1,100,6,23,0,100,5, + 133,2,25,0,102,2,83,0,41,7,122,32,82,101,112,108, + 97,99,101,109,101,110,116,32,102,111,114,32,111,115,46,112, + 97,116,104,46,115,112,108,105,116,40,41,46,99,1,0,0, + 0,0,0,0,0,0,0,0,0,2,0,0,0,4,0,0, + 0,51,0,0,0,115,26,0,0,0,129,0,124,0,93,8, 125,1,136,0,160,0,124,1,161,1,86,0,1,0,113,2, 100,0,83,0,169,1,78,41,1,218,5,114,102,105,110,100, - 114,51,0,0,0,169,1,114,65,0,0,0,114,10,0,0, - 0,114,11,0,0,0,114,12,0,0,0,129,0,0,0,114, - 13,0,0,0,122,30,95,112,97,116,104,95,115,112,108,105, - 116,46,60,108,111,99,97,108,115,62,46,60,103,101,110,101, - 120,112,114,62,114,0,0,0,0,114,14,0,0,0,78,114, - 4,0,0,0,41,2,218,3,109,97,120,114,50,0,0,0, - 41,2,114,65,0,0,0,218,1,105,114,10,0,0,0,114, - 71,0,0,0,114,11,0,0,0,218,11,95,112,97,116,104, - 95,115,112,108,105,116,127,0,0,0,115,8,0,0,0,0, - 2,22,1,8,1,8,1,114,74,0,0,0,99,1,0,0, - 0,0,0,0,0,0,0,0,0,1,0,0,0,3,0,0, - 0,67,0,0,0,115,10,0,0,0,116,0,160,1,124,0, - 161,1,83,0,41,1,122,126,83,116,97,116,32,116,104,101, - 32,112,97,116,104,46,10,10,32,32,32,32,77,97,100,101, - 32,97,32,115,101,112,97,114,97,116,101,32,102,117,110,99, - 116,105,111,110,32,116,111,32,109,97,107,101,32,105,116,32, - 101,97,115,105,101,114,32,116,111,32,111,118,101,114,114,105, - 100,101,32,105,110,32,101,120,112,101,114,105,109,101,110,116, - 115,10,32,32,32,32,40,101,46,103,46,32,99,97,99,104, - 101,32,115,116,97,116,32,114,101,115,117,108,116,115,41,46, - 10,10,32,32,32,32,41,2,114,24,0,0,0,90,4,115, - 116,97,116,114,71,0,0,0,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,10,95,112,97,116,104,95,115, - 116,97,116,135,0,0,0,115,2,0,0,0,0,7,114,75, - 0,0,0,99,2,0,0,0,0,0,0,0,0,0,0,0, - 3,0,0,0,8,0,0,0,67,0,0,0,115,48,0,0, - 0,122,12,116,0,124,0,131,1,125,2,87,0,110,20,4, - 0,116,1,121,32,1,0,1,0,1,0,89,0,100,1,83, - 0,48,0,124,2,106,2,100,2,64,0,124,1,107,2,83, - 0,41,3,122,49,84,101,115,116,32,119,104,101,116,104,101, - 114,32,116,104,101,32,112,97,116,104,32,105,115,32,116,104, - 101,32,115,112,101,99,105,102,105,101,100,32,109,111,100,101, - 32,116,121,112,101,46,70,105,0,240,0,0,41,3,114,75, - 0,0,0,218,7,79,83,69,114,114,111,114,218,7,115,116, - 95,109,111,100,101,41,3,114,65,0,0,0,218,4,109,111, - 100,101,90,9,115,116,97,116,95,105,110,102,111,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,218,18,95,112, - 97,116,104,95,105,115,95,109,111,100,101,95,116,121,112,101, - 145,0,0,0,115,10,0,0,0,0,2,2,1,12,1,12, - 1,8,1,114,79,0,0,0,99,1,0,0,0,0,0,0, - 0,0,0,0,0,1,0,0,0,3,0,0,0,67,0,0, - 0,115,10,0,0,0,116,0,124,0,100,1,131,2,83,0, - 41,2,122,31,82,101,112,108,97,99,101,109,101,110,116,32, - 102,111,114,32,111,115,46,112,97,116,104,46,105,115,102,105, - 108,101,46,105,0,128,0,0,41,1,114,79,0,0,0,114, - 71,0,0,0,114,10,0,0,0,114,10,0,0,0,114,11, - 0,0,0,218,12,95,112,97,116,104,95,105,115,102,105,108, - 101,154,0,0,0,115,2,0,0,0,0,2,114,80,0,0, - 0,99,1,0,0,0,0,0,0,0,0,0,0,0,1,0, - 0,0,3,0,0,0,67,0,0,0,115,22,0,0,0,124, - 0,115,12,116,0,160,1,161,0,125,0,116,2,124,0,100, - 1,131,2,83,0,41,2,122,30,82,101,112,108,97,99,101, - 109,101,110,116,32,102,111,114,32,111,115,46,112,97,116,104, - 46,105,115,100,105,114,46,105,0,64,0,0,41,3,114,24, - 0,0,0,218,6,103,101,116,99,119,100,114,79,0,0,0, - 114,71,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,11,95,112,97,116,104,95,105,115,100,105, - 114,159,0,0,0,115,6,0,0,0,0,2,4,1,8,1, - 114,82,0,0,0,99,1,0,0,0,0,0,0,0,0,0, - 0,0,2,0,0,0,4,0,0,0,67,0,0,0,115,62, - 0,0,0,124,0,115,8,100,1,83,0,116,0,160,1,124, - 0,161,1,100,2,25,0,160,2,100,3,100,4,161,2,125, - 1,116,3,124,1,131,1,100,5,107,4,111,60,124,1,160, - 4,100,6,161,1,112,60,124,1,160,5,100,4,161,1,83, - 0,41,7,250,30,82,101,112,108,97,99,101,109,101,110,116, - 32,102,111,114,32,111,115,46,112,97,116,104,46,105,115,97, - 98,115,46,70,114,0,0,0,0,114,2,0,0,0,114,1, - 0,0,0,114,4,0,0,0,122,2,92,92,41,6,114,24, - 0,0,0,114,56,0,0,0,218,7,114,101,112,108,97,99, - 101,114,6,0,0,0,114,29,0,0,0,114,58,0,0,0, - 41,2,114,65,0,0,0,114,64,0,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,218,11,95,112,97, - 116,104,95,105,115,97,98,115,167,0,0,0,115,8,0,0, - 0,0,2,4,1,4,1,22,1,114,85,0,0,0,99,1, + 114,51,0,0,0,169,1,114,65,0,0,0,114,7,0,0, + 0,114,8,0,0,0,114,9,0,0,0,134,0,0,0,115, + 4,0,0,0,2,128,24,0,122,30,95,112,97,116,104,95, + 115,112,108,105,116,46,60,108,111,99,97,108,115,62,46,60, + 103,101,110,101,120,112,114,62,114,0,0,0,0,114,10,0, + 0,0,78,114,3,0,0,0,41,2,218,3,109,97,120,114, + 50,0,0,0,41,2,114,65,0,0,0,218,1,105,114,7, + 0,0,0,114,71,0,0,0,114,8,0,0,0,218,11,95, + 112,97,116,104,95,115,112,108,105,116,132,0,0,0,115,8, + 0,0,0,22,2,8,1,8,1,28,1,114,74,0,0,0, + 99,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0, + 0,3,0,0,0,67,0,0,0,115,10,0,0,0,116,0, + 160,1,124,0,161,1,83,0,41,1,122,126,83,116,97,116, + 32,116,104,101,32,112,97,116,104,46,10,10,32,32,32,32, + 77,97,100,101,32,97,32,115,101,112,97,114,97,116,101,32, + 102,117,110,99,116,105,111,110,32,116,111,32,109,97,107,101, + 32,105,116,32,101,97,115,105,101,114,32,116,111,32,111,118, + 101,114,114,105,100,101,32,105,110,32,101,120,112,101,114,105, + 109,101,110,116,115,10,32,32,32,32,40,101,46,103,46,32, + 99,97,99,104,101,32,115,116,97,116,32,114,101,115,117,108, + 116,115,41,46,10,10,32,32,32,32,41,2,114,18,0,0, + 0,90,4,115,116,97,116,114,71,0,0,0,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,218,10,95,112,97, + 116,104,95,115,116,97,116,140,0,0,0,115,2,0,0,0, + 10,7,114,75,0,0,0,99,2,0,0,0,0,0,0,0, + 0,0,0,0,3,0,0,0,8,0,0,0,67,0,0,0, + 115,48,0,0,0,122,6,116,0,124,0,131,1,125,2,87, + 0,110,10,4,0,116,1,121,16,1,0,1,0,1,0,89, + 0,100,1,83,0,119,0,124,2,106,2,100,2,64,0,124, + 1,107,2,83,0,41,3,122,49,84,101,115,116,32,119,104, + 101,116,104,101,114,32,116,104,101,32,112,97,116,104,32,105, + 115,32,116,104,101,32,115,112,101,99,105,102,105,101,100,32, + 109,111,100,101,32,116,121,112,101,46,70,105,0,240,0,0, + 41,3,114,75,0,0,0,218,7,79,83,69,114,114,111,114, + 218,7,115,116,95,109,111,100,101,41,3,114,65,0,0,0, + 218,4,109,111,100,101,90,9,115,116,97,116,95,105,110,102, + 111,114,7,0,0,0,114,7,0,0,0,114,8,0,0,0, + 218,18,95,112,97,116,104,95,105,115,95,109,111,100,101,95, + 116,121,112,101,150,0,0,0,115,12,0,0,0,2,2,12, + 1,12,1,6,1,2,255,14,2,114,79,0,0,0,99,1, 0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,3, - 0,0,0,67,0,0,0,115,10,0,0,0,124,0,160,0, - 116,1,161,1,83,0,41,1,114,83,0,0,0,41,2,114, - 29,0,0,0,114,50,0,0,0,114,71,0,0,0,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,114,85,0, - 0,0,175,0,0,0,115,2,0,0,0,0,2,233,182,1, - 0,0,99,3,0,0,0,0,0,0,0,0,0,0,0,6, - 0,0,0,11,0,0,0,67,0,0,0,115,178,0,0,0, - 100,1,160,0,124,0,116,1,124,0,131,1,161,2,125,3, - 116,2,160,3,124,3,116,2,106,4,116,2,106,5,66,0, - 116,2,106,6,66,0,124,2,100,2,64,0,161,3,125,4, - 122,70,116,7,160,8,124,4,100,3,161,2,143,26,125,5, - 124,5,160,9,124,1,161,1,1,0,87,0,100,4,4,0, - 4,0,131,3,1,0,110,16,49,0,115,94,48,0,1,0, - 1,0,1,0,89,0,1,0,116,2,160,10,124,3,124,0, - 161,2,1,0,87,0,110,54,4,0,116,11,121,172,1,0, - 1,0,1,0,122,14,116,2,160,12,124,3,161,1,1,0, - 87,0,110,18,4,0,116,11,121,164,1,0,1,0,1,0, - 89,0,110,2,48,0,130,0,89,0,110,2,48,0,100,4, - 83,0,41,5,122,162,66,101,115,116,45,101,102,102,111,114, - 116,32,102,117,110,99,116,105,111,110,32,116,111,32,119,114, - 105,116,101,32,100,97,116,97,32,116,111,32,97,32,112,97, - 116,104,32,97,116,111,109,105,99,97,108,108,121,46,10,32, - 32,32,32,66,101,32,112,114,101,112,97,114,101,100,32,116, - 111,32,104,97,110,100,108,101,32,97,32,70,105,108,101,69, - 120,105,115,116,115,69,114,114,111,114,32,105,102,32,99,111, - 110,99,117,114,114,101,110,116,32,119,114,105,116,105,110,103, - 32,111,102,32,116,104,101,10,32,32,32,32,116,101,109,112, - 111,114,97,114,121,32,102,105,108,101,32,105,115,32,97,116, - 116,101,109,112,116,101,100,46,250,5,123,125,46,123,125,114, - 86,0,0,0,90,2,119,98,78,41,13,218,6,102,111,114, - 109,97,116,218,2,105,100,114,24,0,0,0,90,4,111,112, - 101,110,90,6,79,95,69,88,67,76,90,7,79,95,67,82, - 69,65,84,90,8,79,95,87,82,79,78,76,89,218,3,95, - 105,111,218,6,70,105,108,101,73,79,218,5,119,114,105,116, - 101,114,84,0,0,0,114,76,0,0,0,90,6,117,110,108, - 105,110,107,41,6,114,65,0,0,0,114,43,0,0,0,114, - 78,0,0,0,90,8,112,97,116,104,95,116,109,112,90,2, - 102,100,218,4,102,105,108,101,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,13,95,119,114,105,116,101,95, - 97,116,111,109,105,99,180,0,0,0,115,28,0,0,0,0, - 5,16,1,6,1,22,255,4,2,2,3,14,1,40,1,16, - 1,12,1,2,1,14,1,12,1,6,1,114,94,0,0,0, - 105,97,13,0,0,114,45,0,0,0,114,35,0,0,0,115, - 2,0,0,0,13,10,90,11,95,95,112,121,99,97,99,104, - 101,95,95,122,4,111,112,116,45,122,3,46,112,121,122,4, - 46,112,121,99,41,1,218,12,111,112,116,105,109,105,122,97, - 116,105,111,110,99,2,0,0,0,0,0,0,0,1,0,0, - 0,12,0,0,0,5,0,0,0,67,0,0,0,115,88,1, - 0,0,124,1,100,1,117,1,114,52,116,0,160,1,100,2, - 116,2,161,2,1,0,124,2,100,1,117,1,114,40,100,3, - 125,3,116,3,124,3,131,1,130,1,124,1,114,48,100,4, - 110,2,100,5,125,2,116,4,160,5,124,0,161,1,125,0, - 116,6,124,0,131,1,92,2,125,4,125,5,124,5,160,7, - 100,6,161,1,92,3,125,6,125,7,125,8,116,8,106,9, - 106,10,125,9,124,9,100,1,117,0,114,114,116,11,100,7, - 131,1,130,1,100,4,160,12,124,6,114,126,124,6,110,2, - 124,8,124,7,124,9,103,3,161,1,125,10,124,2,100,1, - 117,0,114,172,116,8,106,13,106,14,100,8,107,2,114,164, - 100,4,125,2,110,8,116,8,106,13,106,14,125,2,116,15, - 124,2,131,1,125,2,124,2,100,4,107,3,114,224,124,2, - 160,16,161,0,115,210,116,17,100,9,160,18,124,2,161,1, - 131,1,130,1,100,10,160,18,124,10,116,19,124,2,161,3, - 125,10,124,10,116,20,100,8,25,0,23,0,125,11,116,8, - 106,21,100,1,117,1,144,1,114,76,116,22,124,4,131,1, - 144,1,115,16,116,23,116,4,160,24,161,0,124,4,131,2, - 125,4,124,4,100,5,25,0,100,11,107,2,144,1,114,56, - 124,4,100,8,25,0,116,25,118,1,144,1,114,56,124,4, - 100,12,100,1,133,2,25,0,125,4,116,23,116,8,106,21, - 124,4,160,26,116,25,161,1,124,11,131,3,83,0,116,23, - 124,4,116,27,124,11,131,3,83,0,41,13,97,254,2,0, - 0,71,105,118,101,110,32,116,104,101,32,112,97,116,104,32, - 116,111,32,97,32,46,112,121,32,102,105,108,101,44,32,114, - 101,116,117,114,110,32,116,104,101,32,112,97,116,104,32,116, - 111,32,105,116,115,32,46,112,121,99,32,102,105,108,101,46, - 10,10,32,32,32,32,84,104,101,32,46,112,121,32,102,105, - 108,101,32,100,111,101,115,32,110,111,116,32,110,101,101,100, - 32,116,111,32,101,120,105,115,116,59,32,116,104,105,115,32, - 115,105,109,112,108,121,32,114,101,116,117,114,110,115,32,116, - 104,101,32,112,97,116,104,32,116,111,32,116,104,101,10,32, - 32,32,32,46,112,121,99,32,102,105,108,101,32,99,97,108, - 99,117,108,97,116,101,100,32,97,115,32,105,102,32,116,104, - 101,32,46,112,121,32,102,105,108,101,32,119,101,114,101,32, - 105,109,112,111,114,116,101,100,46,10,10,32,32,32,32,84, - 104,101,32,39,111,112,116,105,109,105,122,97,116,105,111,110, - 39,32,112,97,114,97,109,101,116,101,114,32,99,111,110,116, - 114,111,108,115,32,116,104,101,32,112,114,101,115,117,109,101, - 100,32,111,112,116,105,109,105,122,97,116,105,111,110,32,108, - 101,118,101,108,32,111,102,10,32,32,32,32,116,104,101,32, - 98,121,116,101,99,111,100,101,32,102,105,108,101,46,32,73, - 102,32,39,111,112,116,105,109,105,122,97,116,105,111,110,39, - 32,105,115,32,110,111,116,32,78,111,110,101,44,32,116,104, - 101,32,115,116,114,105,110,103,32,114,101,112,114,101,115,101, - 110,116,97,116,105,111,110,10,32,32,32,32,111,102,32,116, - 104,101,32,97,114,103,117,109,101,110,116,32,105,115,32,116, - 97,107,101,110,32,97,110,100,32,118,101,114,105,102,105,101, - 100,32,116,111,32,98,101,32,97,108,112,104,97,110,117,109, - 101,114,105,99,32,40,101,108,115,101,32,86,97,108,117,101, - 69,114,114,111,114,10,32,32,32,32,105,115,32,114,97,105, - 115,101,100,41,46,10,10,32,32,32,32,84,104,101,32,100, - 101,98,117,103,95,111,118,101,114,114,105,100,101,32,112,97, - 114,97,109,101,116,101,114,32,105,115,32,100,101,112,114,101, - 99,97,116,101,100,46,32,73,102,32,100,101,98,117,103,95, - 111,118,101,114,114,105,100,101,32,105,115,32,110,111,116,32, - 78,111,110,101,44,10,32,32,32,32,97,32,84,114,117,101, - 32,118,97,108,117,101,32,105,115,32,116,104,101,32,115,97, - 109,101,32,97,115,32,115,101,116,116,105,110,103,32,39,111, - 112,116,105,109,105,122,97,116,105,111,110,39,32,116,111,32, - 116,104,101,32,101,109,112,116,121,32,115,116,114,105,110,103, - 10,32,32,32,32,119,104,105,108,101,32,97,32,70,97,108, - 115,101,32,118,97,108,117,101,32,105,115,32,101,113,117,105, - 118,97,108,101,110,116,32,116,111,32,115,101,116,116,105,110, - 103,32,39,111,112,116,105,109,105,122,97,116,105,111,110,39, - 32,116,111,32,39,49,39,46,10,10,32,32,32,32,73,102, - 32,115,121,115,46,105,109,112,108,101,109,101,110,116,97,116, - 105,111,110,46,99,97,99,104,101,95,116,97,103,32,105,115, - 32,78,111,110,101,32,116,104,101,110,32,78,111,116,73,109, - 112,108,101,109,101,110,116,101,100,69,114,114,111,114,32,105, - 115,32,114,97,105,115,101,100,46,10,10,32,32,32,32,78, - 122,70,116,104,101,32,100,101,98,117,103,95,111,118,101,114, - 114,105,100,101,32,112,97,114,97,109,101,116,101,114,32,105, - 115,32,100,101,112,114,101,99,97,116,101,100,59,32,117,115, - 101,32,39,111,112,116,105,109,105,122,97,116,105,111,110,39, - 32,105,110,115,116,101,97,100,122,50,100,101,98,117,103,95, - 111,118,101,114,114,105,100,101,32,111,114,32,111,112,116,105, - 109,105,122,97,116,105,111,110,32,109,117,115,116,32,98,101, - 32,115,101,116,32,116,111,32,78,111,110,101,114,14,0,0, - 0,114,4,0,0,0,218,1,46,250,36,115,121,115,46,105, - 109,112,108,101,109,101,110,116,97,116,105,111,110,46,99,97, - 99,104,101,95,116,97,103,32,105,115,32,78,111,110,101,114, - 0,0,0,0,122,24,123,33,114,125,32,105,115,32,110,111, - 116,32,97,108,112,104,97,110,117,109,101,114,105,99,122,7, - 123,125,46,123,125,123,125,114,16,0,0,0,114,45,0,0, - 0,41,28,218,9,95,119,97,114,110,105,110,103,115,218,4, - 119,97,114,110,218,18,68,101,112,114,101,99,97,116,105,111, - 110,87,97,114,110,105,110,103,218,9,84,121,112,101,69,114, - 114,111,114,114,24,0,0,0,218,6,102,115,112,97,116,104, - 114,74,0,0,0,218,10,114,112,97,114,116,105,116,105,111, - 110,114,21,0,0,0,218,14,105,109,112,108,101,109,101,110, - 116,97,116,105,111,110,218,9,99,97,99,104,101,95,116,97, - 103,218,19,78,111,116,73,109,112,108,101,109,101,110,116,101, - 100,69,114,114,111,114,114,62,0,0,0,114,22,0,0,0, - 218,8,111,112,116,105,109,105,122,101,218,3,115,116,114,218, - 7,105,115,97,108,110,117,109,218,10,86,97,108,117,101,69, - 114,114,111,114,114,88,0,0,0,218,4,95,79,80,84,218, - 17,66,89,84,69,67,79,68,69,95,83,85,70,70,73,88, - 69,83,218,14,112,121,99,97,99,104,101,95,112,114,101,102, - 105,120,114,85,0,0,0,114,67,0,0,0,114,81,0,0, - 0,114,50,0,0,0,218,6,108,115,116,114,105,112,218,8, - 95,80,89,67,65,67,72,69,41,12,114,65,0,0,0,90, - 14,100,101,98,117,103,95,111,118,101,114,114,105,100,101,114, - 95,0,0,0,218,7,109,101,115,115,97,103,101,218,4,104, - 101,97,100,114,66,0,0,0,90,4,98,97,115,101,114,9, - 0,0,0,218,4,114,101,115,116,90,3,116,97,103,90,15, - 97,108,109,111,115,116,95,102,105,108,101,110,97,109,101,218, - 8,102,105,108,101,110,97,109,101,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,218,17,99,97,99,104,101,95, - 102,114,111,109,95,115,111,117,114,99,101,105,1,0,0,115, - 72,0,0,0,0,18,8,1,6,1,2,255,4,2,8,1, + 0,0,0,67,0,0,0,115,10,0,0,0,116,0,124,0, + 100,1,131,2,83,0,41,2,122,31,82,101,112,108,97,99, + 101,109,101,110,116,32,102,111,114,32,111,115,46,112,97,116, + 104,46,105,115,102,105,108,101,46,105,0,128,0,0,41,1, + 114,79,0,0,0,114,71,0,0,0,114,7,0,0,0,114, + 7,0,0,0,114,8,0,0,0,218,12,95,112,97,116,104, + 95,105,115,102,105,108,101,159,0,0,0,243,2,0,0,0, + 10,2,114,80,0,0,0,99,1,0,0,0,0,0,0,0, + 0,0,0,0,1,0,0,0,3,0,0,0,67,0,0,0, + 115,22,0,0,0,124,0,115,6,116,0,160,1,161,0,125, + 0,116,2,124,0,100,1,131,2,83,0,41,2,122,30,82, + 101,112,108,97,99,101,109,101,110,116,32,102,111,114,32,111, + 115,46,112,97,116,104,46,105,115,100,105,114,46,105,0,64, + 0,0,41,3,114,18,0,0,0,218,6,103,101,116,99,119, + 100,114,79,0,0,0,114,71,0,0,0,114,7,0,0,0, + 114,7,0,0,0,114,8,0,0,0,218,11,95,112,97,116, + 104,95,105,115,100,105,114,164,0,0,0,115,6,0,0,0, + 4,2,8,1,10,1,114,83,0,0,0,99,1,0,0,0, + 0,0,0,0,0,0,0,0,2,0,0,0,4,0,0,0, + 67,0,0,0,115,62,0,0,0,124,0,115,4,100,1,83, + 0,116,0,160,1,124,0,161,1,100,2,25,0,160,2,100, + 3,100,4,161,2,125,1,116,3,124,1,131,1,100,5,107, + 4,111,30,124,1,160,4,100,6,161,1,112,30,124,1,160, + 5,100,4,161,1,83,0,41,7,250,30,82,101,112,108,97, + 99,101,109,101,110,116,32,102,111,114,32,111,115,46,112,97, + 116,104,46,105,115,97,98,115,46,70,114,0,0,0,0,114, + 2,0,0,0,114,1,0,0,0,114,3,0,0,0,122,2, + 92,92,41,6,114,18,0,0,0,114,56,0,0,0,218,7, + 114,101,112,108,97,99,101,114,4,0,0,0,114,26,0,0, + 0,114,58,0,0,0,41,2,114,65,0,0,0,114,64,0, + 0,0,114,7,0,0,0,114,7,0,0,0,114,8,0,0, + 0,218,11,95,112,97,116,104,95,105,115,97,98,115,172,0, + 0,0,115,8,0,0,0,4,2,4,1,22,1,32,1,114, + 86,0,0,0,99,1,0,0,0,0,0,0,0,0,0,0, + 0,1,0,0,0,3,0,0,0,67,0,0,0,115,10,0, + 0,0,124,0,160,0,116,1,161,1,83,0,41,1,114,84, + 0,0,0,41,2,114,26,0,0,0,114,50,0,0,0,114, + 71,0,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,114,86,0,0,0,180,0,0,0,114,81,0,0, + 0,233,182,1,0,0,99,3,0,0,0,0,0,0,0,0, + 0,0,0,6,0,0,0,11,0,0,0,67,0,0,0,115, + 170,0,0,0,100,1,160,0,124,0,116,1,124,0,131,1, + 161,2,125,3,116,2,160,3,124,3,116,2,106,4,116,2, + 106,5,66,0,116,2,106,6,66,0,124,2,100,2,64,0, + 161,3,125,4,122,36,116,7,160,8,124,4,100,3,161,2, + 143,13,125,5,124,5,160,9,124,1,161,1,1,0,87,0, + 100,4,4,0,4,0,131,3,1,0,110,8,49,0,115,47, + 119,1,1,0,1,0,1,0,89,0,1,0,116,2,160,10, + 124,3,124,0,161,2,1,0,87,0,100,4,83,0,4,0, + 116,11,121,84,1,0,1,0,1,0,122,7,116,2,160,12, + 124,3,161,1,1,0,87,0,130,0,4,0,116,11,121,83, + 1,0,1,0,1,0,89,0,130,0,119,0,119,0,41,5, + 122,162,66,101,115,116,45,101,102,102,111,114,116,32,102,117, + 110,99,116,105,111,110,32,116,111,32,119,114,105,116,101,32, + 100,97,116,97,32,116,111,32,97,32,112,97,116,104,32,97, + 116,111,109,105,99,97,108,108,121,46,10,32,32,32,32,66, + 101,32,112,114,101,112,97,114,101,100,32,116,111,32,104,97, + 110,100,108,101,32,97,32,70,105,108,101,69,120,105,115,116, + 115,69,114,114,111,114,32,105,102,32,99,111,110,99,117,114, + 114,101,110,116,32,119,114,105,116,105,110,103,32,111,102,32, + 116,104,101,10,32,32,32,32,116,101,109,112,111,114,97,114, + 121,32,102,105,108,101,32,105,115,32,97,116,116,101,109,112, + 116,101,100,46,250,5,123,125,46,123,125,114,87,0,0,0, + 90,2,119,98,78,41,13,218,6,102,111,114,109,97,116,218, + 2,105,100,114,18,0,0,0,90,4,111,112,101,110,90,6, + 79,95,69,88,67,76,90,7,79,95,67,82,69,65,84,90, + 8,79,95,87,82,79,78,76,89,218,3,95,105,111,218,6, + 70,105,108,101,73,79,218,5,119,114,105,116,101,114,85,0, + 0,0,114,76,0,0,0,90,6,117,110,108,105,110,107,41, + 6,114,65,0,0,0,114,41,0,0,0,114,78,0,0,0, + 90,8,112,97,116,104,95,116,109,112,90,2,102,100,218,4, + 102,105,108,101,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,218,13,95,119,114,105,116,101,95,97,116,111,109, + 105,99,185,0,0,0,115,36,0,0,0,16,5,6,1,22, + 1,4,255,2,2,14,3,12,1,28,255,18,2,12,1,2, + 1,12,1,2,3,12,254,2,1,2,1,2,254,2,253,114, + 95,0,0,0,105,111,13,0,0,114,44,0,0,0,114,32, + 0,0,0,115,2,0,0,0,13,10,90,11,95,95,112,121, + 99,97,99,104,101,95,95,122,4,111,112,116,45,122,3,46, + 112,121,122,4,46,112,121,119,122,4,46,112,121,99,41,1, + 218,12,111,112,116,105,109,105,122,97,116,105,111,110,99,2, + 0,0,0,0,0,0,0,1,0,0,0,12,0,0,0,5, + 0,0,0,67,0,0,0,115,80,1,0,0,124,1,100,1, + 117,1,114,26,116,0,160,1,100,2,116,2,161,2,1,0, + 124,2,100,1,117,1,114,20,100,3,125,3,116,3,124,3, + 131,1,130,1,124,1,114,24,100,4,110,1,100,5,125,2, + 116,4,160,5,124,0,161,1,125,0,116,6,124,0,131,1, + 92,2,125,4,125,5,124,5,160,7,100,6,161,1,92,3, + 125,6,125,7,125,8,116,8,106,9,106,10,125,9,124,9, + 100,1,117,0,114,57,116,11,100,7,131,1,130,1,100,4, + 160,12,124,6,114,63,124,6,110,1,124,8,124,7,124,9, + 103,3,161,1,125,10,124,2,100,1,117,0,114,86,116,8, + 106,13,106,14,100,8,107,2,114,82,100,4,125,2,110,4, + 116,8,106,13,106,14,125,2,116,15,124,2,131,1,125,2, + 124,2,100,4,107,3,114,112,124,2,160,16,161,0,115,105, + 116,17,100,9,160,18,124,2,161,1,131,1,130,1,100,10, + 160,18,124,10,116,19,124,2,161,3,125,10,124,10,116,20, + 100,8,25,0,23,0,125,11,116,8,106,21,100,1,117,1, + 114,162,116,22,124,4,131,1,115,134,116,23,116,4,160,24, + 161,0,124,4,131,2,125,4,124,4,100,5,25,0,100,11, + 107,2,114,152,124,4,100,8,25,0,116,25,118,1,114,152, + 124,4,100,12,100,1,133,2,25,0,125,4,116,23,116,8, + 106,21,124,4,160,26,116,25,161,1,124,11,131,3,83,0, + 116,23,124,4,116,27,124,11,131,3,83,0,41,13,97,254, + 2,0,0,71,105,118,101,110,32,116,104,101,32,112,97,116, + 104,32,116,111,32,97,32,46,112,121,32,102,105,108,101,44, + 32,114,101,116,117,114,110,32,116,104,101,32,112,97,116,104, + 32,116,111,32,105,116,115,32,46,112,121,99,32,102,105,108, + 101,46,10,10,32,32,32,32,84,104,101,32,46,112,121,32, + 102,105,108,101,32,100,111,101,115,32,110,111,116,32,110,101, + 101,100,32,116,111,32,101,120,105,115,116,59,32,116,104,105, + 115,32,115,105,109,112,108,121,32,114,101,116,117,114,110,115, + 32,116,104,101,32,112,97,116,104,32,116,111,32,116,104,101, + 10,32,32,32,32,46,112,121,99,32,102,105,108,101,32,99, + 97,108,99,117,108,97,116,101,100,32,97,115,32,105,102,32, + 116,104,101,32,46,112,121,32,102,105,108,101,32,119,101,114, + 101,32,105,109,112,111,114,116,101,100,46,10,10,32,32,32, + 32,84,104,101,32,39,111,112,116,105,109,105,122,97,116,105, + 111,110,39,32,112,97,114,97,109,101,116,101,114,32,99,111, + 110,116,114,111,108,115,32,116,104,101,32,112,114,101,115,117, + 109,101,100,32,111,112,116,105,109,105,122,97,116,105,111,110, + 32,108,101,118,101,108,32,111,102,10,32,32,32,32,116,104, + 101,32,98,121,116,101,99,111,100,101,32,102,105,108,101,46, + 32,73,102,32,39,111,112,116,105,109,105,122,97,116,105,111, + 110,39,32,105,115,32,110,111,116,32,78,111,110,101,44,32, + 116,104,101,32,115,116,114,105,110,103,32,114,101,112,114,101, + 115,101,110,116,97,116,105,111,110,10,32,32,32,32,111,102, + 32,116,104,101,32,97,114,103,117,109,101,110,116,32,105,115, + 32,116,97,107,101,110,32,97,110,100,32,118,101,114,105,102, + 105,101,100,32,116,111,32,98,101,32,97,108,112,104,97,110, + 117,109,101,114,105,99,32,40,101,108,115,101,32,86,97,108, + 117,101,69,114,114,111,114,10,32,32,32,32,105,115,32,114, + 97,105,115,101,100,41,46,10,10,32,32,32,32,84,104,101, + 32,100,101,98,117,103,95,111,118,101,114,114,105,100,101,32, + 112,97,114,97,109,101,116,101,114,32,105,115,32,100,101,112, + 114,101,99,97,116,101,100,46,32,73,102,32,100,101,98,117, + 103,95,111,118,101,114,114,105,100,101,32,105,115,32,110,111, + 116,32,78,111,110,101,44,10,32,32,32,32,97,32,84,114, + 117,101,32,118,97,108,117,101,32,105,115,32,116,104,101,32, + 115,97,109,101,32,97,115,32,115,101,116,116,105,110,103,32, + 39,111,112,116,105,109,105,122,97,116,105,111,110,39,32,116, + 111,32,116,104,101,32,101,109,112,116,121,32,115,116,114,105, + 110,103,10,32,32,32,32,119,104,105,108,101,32,97,32,70, + 97,108,115,101,32,118,97,108,117,101,32,105,115,32,101,113, + 117,105,118,97,108,101,110,116,32,116,111,32,115,101,116,116, + 105,110,103,32,39,111,112,116,105,109,105,122,97,116,105,111, + 110,39,32,116,111,32,39,49,39,46,10,10,32,32,32,32, + 73,102,32,115,121,115,46,105,109,112,108,101,109,101,110,116, + 97,116,105,111,110,46,99,97,99,104,101,95,116,97,103,32, + 105,115,32,78,111,110,101,32,116,104,101,110,32,78,111,116, + 73,109,112,108,101,109,101,110,116,101,100,69,114,114,111,114, + 32,105,115,32,114,97,105,115,101,100,46,10,10,32,32,32, + 32,78,122,70,116,104,101,32,100,101,98,117,103,95,111,118, + 101,114,114,105,100,101,32,112,97,114,97,109,101,116,101,114, + 32,105,115,32,100,101,112,114,101,99,97,116,101,100,59,32, + 117,115,101,32,39,111,112,116,105,109,105,122,97,116,105,111, + 110,39,32,105,110,115,116,101,97,100,122,50,100,101,98,117, + 103,95,111,118,101,114,114,105,100,101,32,111,114,32,111,112, + 116,105,109,105,122,97,116,105,111,110,32,109,117,115,116,32, + 98,101,32,115,101,116,32,116,111,32,78,111,110,101,114,10, + 0,0,0,114,3,0,0,0,218,1,46,250,36,115,121,115, + 46,105,109,112,108,101,109,101,110,116,97,116,105,111,110,46, + 99,97,99,104,101,95,116,97,103,32,105,115,32,78,111,110, + 101,114,0,0,0,0,122,24,123,33,114,125,32,105,115,32, + 110,111,116,32,97,108,112,104,97,110,117,109,101,114,105,99, + 122,7,123,125,46,123,125,123,125,114,11,0,0,0,114,44, + 0,0,0,41,28,218,9,95,119,97,114,110,105,110,103,115, + 218,4,119,97,114,110,218,18,68,101,112,114,101,99,97,116, + 105,111,110,87,97,114,110,105,110,103,218,9,84,121,112,101, + 69,114,114,111,114,114,18,0,0,0,218,6,102,115,112,97, + 116,104,114,74,0,0,0,218,10,114,112,97,114,116,105,116, + 105,111,110,114,15,0,0,0,218,14,105,109,112,108,101,109, + 101,110,116,97,116,105,111,110,218,9,99,97,99,104,101,95, + 116,97,103,218,19,78,111,116,73,109,112,108,101,109,101,110, + 116,101,100,69,114,114,111,114,114,62,0,0,0,114,16,0, + 0,0,218,8,111,112,116,105,109,105,122,101,218,3,115,116, + 114,218,7,105,115,97,108,110,117,109,218,10,86,97,108,117, + 101,69,114,114,111,114,114,89,0,0,0,218,4,95,79,80, + 84,218,17,66,89,84,69,67,79,68,69,95,83,85,70,70, + 73,88,69,83,218,14,112,121,99,97,99,104,101,95,112,114, + 101,102,105,120,114,86,0,0,0,114,67,0,0,0,114,82, + 0,0,0,114,50,0,0,0,218,6,108,115,116,114,105,112, + 218,8,95,80,89,67,65,67,72,69,41,12,114,65,0,0, + 0,90,14,100,101,98,117,103,95,111,118,101,114,114,105,100, + 101,114,96,0,0,0,218,7,109,101,115,115,97,103,101,218, + 4,104,101,97,100,114,66,0,0,0,90,4,98,97,115,101, + 114,6,0,0,0,218,4,114,101,115,116,90,3,116,97,103, + 90,15,97,108,109,111,115,116,95,102,105,108,101,110,97,109, + 101,218,8,102,105,108,101,110,97,109,101,114,7,0,0,0, + 114,7,0,0,0,114,8,0,0,0,218,17,99,97,99,104, + 101,95,102,114,111,109,95,115,111,117,114,99,101,124,1,0, + 0,115,72,0,0,0,8,18,6,1,2,1,4,255,8,2, 4,1,8,1,12,1,10,1,12,1,16,1,8,1,8,1, - 8,1,24,1,8,1,12,1,6,2,8,1,8,1,8,1, - 8,1,14,1,14,1,12,1,12,9,10,1,14,5,28,1, - 12,4,2,1,4,1,8,1,2,253,4,5,114,120,0,0, - 0,99,1,0,0,0,0,0,0,0,0,0,0,0,10,0, - 0,0,5,0,0,0,67,0,0,0,115,46,1,0,0,116, - 0,106,1,106,2,100,1,117,0,114,20,116,3,100,2,131, - 1,130,1,116,4,160,5,124,0,161,1,125,0,116,6,124, - 0,131,1,92,2,125,1,125,2,100,3,125,3,116,0,106, - 7,100,1,117,1,114,102,116,0,106,7,160,8,116,9,161, - 1,125,4,124,1,160,10,124,4,116,11,23,0,161,1,114, - 102,124,1,116,12,124,4,131,1,100,1,133,2,25,0,125, - 1,100,4,125,3,124,3,115,144,116,6,124,1,131,1,92, - 2,125,1,125,5,124,5,116,13,107,3,114,144,116,14,116, - 13,155,0,100,5,124,0,155,2,157,3,131,1,130,1,124, - 2,160,15,100,6,161,1,125,6,124,6,100,7,118,1,114, - 178,116,14,100,8,124,2,155,2,157,2,131,1,130,1,110, - 92,124,6,100,9,107,2,144,1,114,14,124,2,160,16,100, - 6,100,10,161,2,100,11,25,0,125,7,124,7,160,10,116, - 17,161,1,115,228,116,14,100,12,116,17,155,2,157,2,131, - 1,130,1,124,7,116,12,116,17,131,1,100,1,133,2,25, - 0,125,8,124,8,160,18,161,0,144,1,115,14,116,14,100, - 13,124,7,155,2,100,14,157,3,131,1,130,1,124,2,160, - 19,100,6,161,1,100,15,25,0,125,9,116,20,124,1,124, - 9,116,21,100,15,25,0,23,0,131,2,83,0,41,16,97, - 110,1,0,0,71,105,118,101,110,32,116,104,101,32,112,97, - 116,104,32,116,111,32,97,32,46,112,121,99,46,32,102,105, - 108,101,44,32,114,101,116,117,114,110,32,116,104,101,32,112, - 97,116,104,32,116,111,32,105,116,115,32,46,112,121,32,102, - 105,108,101,46,10,10,32,32,32,32,84,104,101,32,46,112, - 121,99,32,102,105,108,101,32,100,111,101,115,32,110,111,116, - 32,110,101,101,100,32,116,111,32,101,120,105,115,116,59,32, - 116,104,105,115,32,115,105,109,112,108,121,32,114,101,116,117, - 114,110,115,32,116,104,101,32,112,97,116,104,32,116,111,10, - 32,32,32,32,116,104,101,32,46,112,121,32,102,105,108,101, - 32,99,97,108,99,117,108,97,116,101,100,32,116,111,32,99, - 111,114,114,101,115,112,111,110,100,32,116,111,32,116,104,101, - 32,46,112,121,99,32,102,105,108,101,46,32,32,73,102,32, - 112,97,116,104,32,100,111,101,115,10,32,32,32,32,110,111, - 116,32,99,111,110,102,111,114,109,32,116,111,32,80,69,80, - 32,51,49,52,55,47,52,56,56,32,102,111,114,109,97,116, - 44,32,86,97,108,117,101,69,114,114,111,114,32,119,105,108, - 108,32,98,101,32,114,97,105,115,101,100,46,32,73,102,10, - 32,32,32,32,115,121,115,46,105,109,112,108,101,109,101,110, - 116,97,116,105,111,110,46,99,97,99,104,101,95,116,97,103, - 32,105,115,32,78,111,110,101,32,116,104,101,110,32,78,111, - 116,73,109,112,108,101,109,101,110,116,101,100,69,114,114,111, - 114,32,105,115,32,114,97,105,115,101,100,46,10,10,32,32, - 32,32,78,114,97,0,0,0,70,84,122,31,32,110,111,116, - 32,98,111,116,116,111,109,45,108,101,118,101,108,32,100,105, - 114,101,99,116,111,114,121,32,105,110,32,114,96,0,0,0, - 62,2,0,0,0,114,45,0,0,0,233,3,0,0,0,122, - 29,101,120,112,101,99,116,101,100,32,111,110,108,121,32,50, - 32,111,114,32,51,32,100,111,116,115,32,105,110,32,114,121, - 0,0,0,114,45,0,0,0,233,254,255,255,255,122,53,111, - 112,116,105,109,105,122,97,116,105,111,110,32,112,111,114,116, - 105,111,110,32,111,102,32,102,105,108,101,110,97,109,101,32, - 100,111,101,115,32,110,111,116,32,115,116,97,114,116,32,119, - 105,116,104,32,122,19,111,112,116,105,109,105,122,97,116,105, - 111,110,32,108,101,118,101,108,32,122,29,32,105,115,32,110, - 111,116,32,97,110,32,97,108,112,104,97,110,117,109,101,114, - 105,99,32,118,97,108,117,101,114,0,0,0,0,41,22,114, - 21,0,0,0,114,104,0,0,0,114,105,0,0,0,114,106, - 0,0,0,114,24,0,0,0,114,102,0,0,0,114,74,0, - 0,0,114,113,0,0,0,114,49,0,0,0,114,50,0,0, - 0,114,29,0,0,0,114,59,0,0,0,114,6,0,0,0, - 114,115,0,0,0,114,110,0,0,0,218,5,99,111,117,110, - 116,218,6,114,115,112,108,105,116,114,111,0,0,0,114,109, - 0,0,0,218,9,112,97,114,116,105,116,105,111,110,114,67, - 0,0,0,218,15,83,79,85,82,67,69,95,83,85,70,70, - 73,88,69,83,41,10,114,65,0,0,0,114,117,0,0,0, - 90,16,112,121,99,97,99,104,101,95,102,105,108,101,110,97, - 109,101,90,23,102,111,117,110,100,95,105,110,95,112,121,99, - 97,99,104,101,95,112,114,101,102,105,120,90,13,115,116,114, - 105,112,112,101,100,95,112,97,116,104,90,7,112,121,99,97, - 99,104,101,90,9,100,111,116,95,99,111,117,110,116,114,95, - 0,0,0,90,9,111,112,116,95,108,101,118,101,108,90,13, - 98,97,115,101,95,102,105,108,101,110,97,109,101,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,218,17,115,111, - 117,114,99,101,95,102,114,111,109,95,99,97,99,104,101,176, - 1,0,0,115,60,0,0,0,0,9,12,1,8,1,10,1, - 12,1,4,1,10,1,12,1,14,1,16,1,4,1,4,1, - 12,1,8,1,8,1,2,255,8,2,10,1,8,1,16,1, - 10,1,16,1,10,1,4,1,2,255,8,2,16,1,10,1, - 16,2,14,1,114,127,0,0,0,99,1,0,0,0,0,0, - 0,0,0,0,0,0,5,0,0,0,9,0,0,0,67,0, - 0,0,115,124,0,0,0,116,0,124,0,131,1,100,1,107, - 2,114,16,100,2,83,0,124,0,160,1,100,3,161,1,92, - 3,125,1,125,2,125,3,124,1,114,56,124,3,160,2,161, - 0,100,4,100,5,133,2,25,0,100,6,107,3,114,60,124, - 0,83,0,122,12,116,3,124,0,131,1,125,4,87,0,110, - 34,4,0,116,4,116,5,102,2,121,106,1,0,1,0,1, - 0,124,0,100,2,100,5,133,2,25,0,125,4,89,0,110, - 2,48,0,116,6,124,4,131,1,114,120,124,4,83,0,124, - 0,83,0,41,7,122,188,67,111,110,118,101,114,116,32,97, - 32,98,121,116,101,99,111,100,101,32,102,105,108,101,32,112, - 97,116,104,32,116,111,32,97,32,115,111,117,114,99,101,32, - 112,97,116,104,32,40,105,102,32,112,111,115,115,105,98,108, - 101,41,46,10,10,32,32,32,32,84,104,105,115,32,102,117, - 110,99,116,105,111,110,32,101,120,105,115,116,115,32,112,117, - 114,101,108,121,32,102,111,114,32,98,97,99,107,119,97,114, - 100,115,45,99,111,109,112,97,116,105,98,105,108,105,116,121, - 32,102,111,114,10,32,32,32,32,80,121,73,109,112,111,114, - 116,95,69,120,101,99,67,111,100,101,77,111,100,117,108,101, - 87,105,116,104,70,105,108,101,110,97,109,101,115,40,41,32, - 105,110,32,116,104,101,32,67,32,65,80,73,46,10,10,32, - 32,32,32,114,0,0,0,0,78,114,96,0,0,0,233,253, - 255,255,255,233,255,255,255,255,90,2,112,121,41,7,114,6, - 0,0,0,114,103,0,0,0,218,5,108,111,119,101,114,114, - 127,0,0,0,114,106,0,0,0,114,110,0,0,0,114,80, - 0,0,0,41,5,218,13,98,121,116,101,99,111,100,101,95, - 112,97,116,104,114,118,0,0,0,218,1,95,90,9,101,120, - 116,101,110,115,105,111,110,218,11,115,111,117,114,99,101,95, - 112,97,116,104,114,10,0,0,0,114,10,0,0,0,114,11, - 0,0,0,218,15,95,103,101,116,95,115,111,117,114,99,101, - 102,105,108,101,216,1,0,0,115,20,0,0,0,0,7,12, - 1,4,1,16,1,24,1,4,1,2,1,12,1,16,1,18, - 1,114,134,0,0,0,99,1,0,0,0,0,0,0,0,0, - 0,0,0,1,0,0,0,8,0,0,0,67,0,0,0,115, - 72,0,0,0,124,0,160,0,116,1,116,2,131,1,161,1, - 114,46,122,10,116,3,124,0,131,1,87,0,83,0,4,0, - 116,4,121,42,1,0,1,0,1,0,89,0,113,68,48,0, - 110,22,124,0,160,0,116,1,116,5,131,1,161,1,114,64, - 124,0,83,0,100,0,83,0,100,0,83,0,114,69,0,0, - 0,41,6,114,58,0,0,0,218,5,116,117,112,108,101,114, - 126,0,0,0,114,120,0,0,0,114,106,0,0,0,114,112, - 0,0,0,41,1,114,119,0,0,0,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,218,11,95,103,101,116,95, - 99,97,99,104,101,100,235,1,0,0,115,16,0,0,0,0, - 1,14,1,2,1,10,1,12,1,8,1,14,1,4,2,114, - 136,0,0,0,99,1,0,0,0,0,0,0,0,0,0,0, - 0,2,0,0,0,8,0,0,0,67,0,0,0,115,50,0, - 0,0,122,14,116,0,124,0,131,1,106,1,125,1,87,0, - 110,22,4,0,116,2,121,36,1,0,1,0,1,0,100,1, - 125,1,89,0,110,2,48,0,124,1,100,2,79,0,125,1, - 124,1,83,0,41,3,122,51,67,97,108,99,117,108,97,116, - 101,32,116,104,101,32,109,111,100,101,32,112,101,114,109,105, - 115,115,105,111,110,115,32,102,111,114,32,97,32,98,121,116, - 101,99,111,100,101,32,102,105,108,101,46,114,86,0,0,0, - 233,128,0,0,0,41,3,114,75,0,0,0,114,77,0,0, - 0,114,76,0,0,0,41,2,114,65,0,0,0,114,78,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,218,10,95,99,97,108,99,95,109,111,100,101,247,1,0, - 0,115,12,0,0,0,0,2,2,1,14,1,12,1,10,3, - 8,1,114,138,0,0,0,99,1,0,0,0,0,0,0,0, - 0,0,0,0,3,0,0,0,8,0,0,0,3,0,0,0, - 115,66,0,0,0,100,6,135,0,102,1,100,2,100,3,132, - 9,125,1,122,10,116,0,106,1,125,2,87,0,110,26,4, - 0,116,2,121,50,1,0,1,0,1,0,100,4,100,5,132, - 0,125,2,89,0,110,2,48,0,124,2,124,1,136,0,131, + 8,1,24,1,8,1,12,1,6,1,8,2,8,1,8,1, + 8,1,14,1,14,1,12,1,10,1,8,9,14,1,24,5, + 12,1,2,4,4,1,8,1,2,1,4,253,12,5,114,121, + 0,0,0,99,1,0,0,0,0,0,0,0,0,0,0,0, + 10,0,0,0,5,0,0,0,67,0,0,0,115,40,1,0, + 0,116,0,106,1,106,2,100,1,117,0,114,10,116,3,100, + 2,131,1,130,1,116,4,160,5,124,0,161,1,125,0,116, + 6,124,0,131,1,92,2,125,1,125,2,100,3,125,3,116, + 0,106,7,100,1,117,1,114,51,116,0,106,7,160,8,116, + 9,161,1,125,4,124,1,160,10,124,4,116,11,23,0,161, + 1,114,51,124,1,116,12,124,4,131,1,100,1,133,2,25, + 0,125,1,100,4,125,3,124,3,115,72,116,6,124,1,131, + 1,92,2,125,1,125,5,124,5,116,13,107,3,114,72,116, + 14,116,13,155,0,100,5,124,0,155,2,157,3,131,1,130, + 1,124,2,160,15,100,6,161,1,125,6,124,6,100,7,118, + 1,114,88,116,14,100,8,124,2,155,2,157,2,131,1,130, + 1,124,6,100,9,107,2,114,132,124,2,160,16,100,6,100, + 10,161,2,100,11,25,0,125,7,124,7,160,10,116,17,161, + 1,115,112,116,14,100,12,116,17,155,2,157,2,131,1,130, + 1,124,7,116,12,116,17,131,1,100,1,133,2,25,0,125, + 8,124,8,160,18,161,0,115,132,116,14,100,13,124,7,155, + 2,100,14,157,3,131,1,130,1,124,2,160,19,100,6,161, + 1,100,15,25,0,125,9,116,20,124,1,124,9,116,21,100, + 15,25,0,23,0,131,2,83,0,41,16,97,110,1,0,0, + 71,105,118,101,110,32,116,104,101,32,112,97,116,104,32,116, + 111,32,97,32,46,112,121,99,46,32,102,105,108,101,44,32, + 114,101,116,117,114,110,32,116,104,101,32,112,97,116,104,32, + 116,111,32,105,116,115,32,46,112,121,32,102,105,108,101,46, + 10,10,32,32,32,32,84,104,101,32,46,112,121,99,32,102, + 105,108,101,32,100,111,101,115,32,110,111,116,32,110,101,101, + 100,32,116,111,32,101,120,105,115,116,59,32,116,104,105,115, + 32,115,105,109,112,108,121,32,114,101,116,117,114,110,115,32, + 116,104,101,32,112,97,116,104,32,116,111,10,32,32,32,32, + 116,104,101,32,46,112,121,32,102,105,108,101,32,99,97,108, + 99,117,108,97,116,101,100,32,116,111,32,99,111,114,114,101, + 115,112,111,110,100,32,116,111,32,116,104,101,32,46,112,121, + 99,32,102,105,108,101,46,32,32,73,102,32,112,97,116,104, + 32,100,111,101,115,10,32,32,32,32,110,111,116,32,99,111, + 110,102,111,114,109,32,116,111,32,80,69,80,32,51,49,52, + 55,47,52,56,56,32,102,111,114,109,97,116,44,32,86,97, + 108,117,101,69,114,114,111,114,32,119,105,108,108,32,98,101, + 32,114,97,105,115,101,100,46,32,73,102,10,32,32,32,32, + 115,121,115,46,105,109,112,108,101,109,101,110,116,97,116,105, + 111,110,46,99,97,99,104,101,95,116,97,103,32,105,115,32, + 78,111,110,101,32,116,104,101,110,32,78,111,116,73,109,112, + 108,101,109,101,110,116,101,100,69,114,114,111,114,32,105,115, + 32,114,97,105,115,101,100,46,10,10,32,32,32,32,78,114, + 98,0,0,0,70,84,122,31,32,110,111,116,32,98,111,116, + 116,111,109,45,108,101,118,101,108,32,100,105,114,101,99,116, + 111,114,121,32,105,110,32,114,97,0,0,0,62,2,0,0, + 0,114,44,0,0,0,233,3,0,0,0,122,29,101,120,112, + 101,99,116,101,100,32,111,110,108,121,32,50,32,111,114,32, + 51,32,100,111,116,115,32,105,110,32,114,122,0,0,0,114, + 44,0,0,0,233,254,255,255,255,122,53,111,112,116,105,109, + 105,122,97,116,105,111,110,32,112,111,114,116,105,111,110,32, + 111,102,32,102,105,108,101,110,97,109,101,32,100,111,101,115, + 32,110,111,116,32,115,116,97,114,116,32,119,105,116,104,32, + 122,19,111,112,116,105,109,105,122,97,116,105,111,110,32,108, + 101,118,101,108,32,122,29,32,105,115,32,110,111,116,32,97, + 110,32,97,108,112,104,97,110,117,109,101,114,105,99,32,118, + 97,108,117,101,114,0,0,0,0,41,22,114,15,0,0,0, + 114,105,0,0,0,114,106,0,0,0,114,107,0,0,0,114, + 18,0,0,0,114,103,0,0,0,114,74,0,0,0,114,114, + 0,0,0,114,49,0,0,0,114,50,0,0,0,114,26,0, + 0,0,114,59,0,0,0,114,4,0,0,0,114,116,0,0, + 0,114,111,0,0,0,218,5,99,111,117,110,116,218,6,114, + 115,112,108,105,116,114,112,0,0,0,114,110,0,0,0,218, + 9,112,97,114,116,105,116,105,111,110,114,67,0,0,0,218, + 15,83,79,85,82,67,69,95,83,85,70,70,73,88,69,83, + 41,10,114,65,0,0,0,114,118,0,0,0,90,16,112,121, + 99,97,99,104,101,95,102,105,108,101,110,97,109,101,90,23, + 102,111,117,110,100,95,105,110,95,112,121,99,97,99,104,101, + 95,112,114,101,102,105,120,90,13,115,116,114,105,112,112,101, + 100,95,112,97,116,104,90,7,112,121,99,97,99,104,101,90, + 9,100,111,116,95,99,111,117,110,116,114,96,0,0,0,90, + 9,111,112,116,95,108,101,118,101,108,90,13,98,97,115,101, + 95,102,105,108,101,110,97,109,101,114,7,0,0,0,114,7, + 0,0,0,114,8,0,0,0,218,17,115,111,117,114,99,101, + 95,102,114,111,109,95,99,97,99,104,101,195,1,0,0,115, + 60,0,0,0,12,9,8,1,10,1,12,1,4,1,10,1, + 12,1,14,1,16,1,4,1,4,1,12,1,8,1,8,1, + 2,1,8,255,10,2,8,1,14,1,8,1,16,1,10,1, + 4,1,2,1,8,255,16,2,8,1,16,1,14,2,18,1, + 114,128,0,0,0,99,1,0,0,0,0,0,0,0,0,0, + 0,0,5,0,0,0,9,0,0,0,67,0,0,0,115,124, + 0,0,0,116,0,124,0,131,1,100,1,107,2,114,8,100, + 2,83,0,124,0,160,1,100,3,161,1,92,3,125,1,125, + 2,125,3,124,1,114,28,124,3,160,2,161,0,100,4,100, + 5,133,2,25,0,100,6,107,3,114,30,124,0,83,0,122, + 6,116,3,124,0,131,1,125,4,87,0,110,17,4,0,116, + 4,116,5,102,2,121,53,1,0,1,0,1,0,124,0,100, + 2,100,5,133,2,25,0,125,4,89,0,110,1,119,0,116, + 6,124,4,131,1,114,60,124,4,83,0,124,0,83,0,41, + 7,122,188,67,111,110,118,101,114,116,32,97,32,98,121,116, + 101,99,111,100,101,32,102,105,108,101,32,112,97,116,104,32, + 116,111,32,97,32,115,111,117,114,99,101,32,112,97,116,104, + 32,40,105,102,32,112,111,115,115,105,98,108,101,41,46,10, + 10,32,32,32,32,84,104,105,115,32,102,117,110,99,116,105, + 111,110,32,101,120,105,115,116,115,32,112,117,114,101,108,121, + 32,102,111,114,32,98,97,99,107,119,97,114,100,115,45,99, + 111,109,112,97,116,105,98,105,108,105,116,121,32,102,111,114, + 10,32,32,32,32,80,121,73,109,112,111,114,116,95,69,120, + 101,99,67,111,100,101,77,111,100,117,108,101,87,105,116,104, + 70,105,108,101,110,97,109,101,115,40,41,32,105,110,32,116, + 104,101,32,67,32,65,80,73,46,10,10,32,32,32,32,114, + 0,0,0,0,78,114,97,0,0,0,233,253,255,255,255,233, + 255,255,255,255,90,2,112,121,41,7,114,4,0,0,0,114, + 104,0,0,0,218,5,108,111,119,101,114,114,128,0,0,0, + 114,107,0,0,0,114,111,0,0,0,114,80,0,0,0,41, + 5,218,13,98,121,116,101,99,111,100,101,95,112,97,116,104, + 114,119,0,0,0,218,1,95,90,9,101,120,116,101,110,115, + 105,111,110,218,11,115,111,117,114,99,101,95,112,97,116,104, + 114,7,0,0,0,114,7,0,0,0,114,8,0,0,0,218, + 15,95,103,101,116,95,115,111,117,114,99,101,102,105,108,101, + 235,1,0,0,115,22,0,0,0,12,7,4,1,16,1,24, + 1,4,1,2,1,12,1,16,1,16,1,2,255,16,2,114, + 135,0,0,0,99,1,0,0,0,0,0,0,0,0,0,0, + 0,1,0,0,0,8,0,0,0,67,0,0,0,115,68,0, + 0,0,124,0,160,0,116,1,116,2,131,1,161,1,114,23, + 122,5,116,3,124,0,131,1,87,0,83,0,4,0,116,4, + 121,22,1,0,1,0,1,0,89,0,100,0,83,0,119,0, + 124,0,160,0,116,1,116,5,131,1,161,1,114,32,124,0, + 83,0,100,0,83,0,114,69,0,0,0,41,6,114,58,0, + 0,0,218,5,116,117,112,108,101,114,127,0,0,0,114,121, + 0,0,0,114,107,0,0,0,114,113,0,0,0,41,1,114, + 120,0,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,218,11,95,103,101,116,95,99,97,99,104,101,100, + 254,1,0,0,115,18,0,0,0,14,1,2,1,10,1,12, + 1,6,1,2,255,14,2,4,1,4,2,114,137,0,0,0, + 99,1,0,0,0,0,0,0,0,0,0,0,0,2,0,0, + 0,8,0,0,0,67,0,0,0,115,50,0,0,0,122,7, + 116,0,124,0,131,1,106,1,125,1,87,0,110,11,4,0, + 116,2,121,18,1,0,1,0,1,0,100,1,125,1,89,0, + 110,1,119,0,124,1,100,2,79,0,125,1,124,1,83,0, + 41,3,122,51,67,97,108,99,117,108,97,116,101,32,116,104, + 101,32,109,111,100,101,32,112,101,114,109,105,115,115,105,111, + 110,115,32,102,111,114,32,97,32,98,121,116,101,99,111,100, + 101,32,102,105,108,101,46,114,87,0,0,0,233,128,0,0, + 0,41,3,114,75,0,0,0,114,77,0,0,0,114,76,0, + 0,0,41,2,114,65,0,0,0,114,78,0,0,0,114,7, + 0,0,0,114,7,0,0,0,114,8,0,0,0,218,10,95, + 99,97,108,99,95,109,111,100,101,10,2,0,0,115,14,0, + 0,0,2,2,14,1,12,1,8,1,2,255,8,4,4,1, + 114,139,0,0,0,99,1,0,0,0,0,0,0,0,0,0, + 0,0,3,0,0,0,4,0,0,0,3,0,0,0,115,52, + 0,0,0,100,6,135,0,102,1,100,2,100,3,132,9,125, + 1,116,0,100,1,117,1,114,15,116,0,106,1,125,2,110, + 4,100,4,100,5,132,0,125,2,124,2,124,1,136,0,131, 2,1,0,124,1,83,0,41,7,122,252,68,101,99,111,114, 97,116,111,114,32,116,111,32,118,101,114,105,102,121,32,116, 104,97,116,32,116,104,101,32,109,111,100,117,108,101,32,98, @@ -641,28 +639,28 @@ const unsigned char _Py_M__importlib_bootstrap_external[] = { 116,69,114,114,111,114,32,105,115,32,114,97,105,115,101,100, 46,10,10,32,32,32,32,78,99,2,0,0,0,0,0,0, 0,0,0,0,0,4,0,0,0,4,0,0,0,31,0,0, - 0,115,72,0,0,0,124,1,100,0,117,0,114,16,124,0, - 106,0,125,1,110,32,124,0,106,0,124,1,107,3,114,48, + 0,115,72,0,0,0,124,1,100,0,117,0,114,8,124,0, + 106,0,125,1,110,16,124,0,106,0,124,1,107,3,114,24, 116,1,100,1,124,0,106,0,124,1,102,2,22,0,124,1, 100,2,141,2,130,1,136,0,124,0,124,1,103,2,124,2, 162,1,82,0,105,0,124,3,164,1,142,1,83,0,41,3, 78,122,30,108,111,97,100,101,114,32,102,111,114,32,37,115, 32,99,97,110,110,111,116,32,104,97,110,100,108,101,32,37, - 115,169,1,218,4,110,97,109,101,41,2,114,140,0,0,0, + 115,169,1,218,4,110,97,109,101,41,2,114,141,0,0,0, 218,11,73,109,112,111,114,116,69,114,114,111,114,41,4,218, - 4,115,101,108,102,114,140,0,0,0,218,4,97,114,103,115, + 4,115,101,108,102,114,141,0,0,0,218,4,97,114,103,115, 218,6,107,119,97,114,103,115,169,1,218,6,109,101,116,104, - 111,100,114,10,0,0,0,114,11,0,0,0,218,19,95,99, + 111,100,114,7,0,0,0,114,8,0,0,0,218,19,95,99, 104,101,99,107,95,110,97,109,101,95,119,114,97,112,112,101, - 114,11,2,0,0,115,18,0,0,0,0,1,8,1,8,1, - 10,1,4,1,8,255,2,1,2,255,6,2,122,40,95,99, + 114,30,2,0,0,115,18,0,0,0,8,1,8,1,10,1, + 4,1,8,1,2,255,2,1,6,255,24,2,122,40,95,99, 104,101,99,107,95,110,97,109,101,46,60,108,111,99,97,108, 115,62,46,95,99,104,101,99,107,95,110,97,109,101,95,119, 114,97,112,112,101,114,99,2,0,0,0,0,0,0,0,0, 0,0,0,3,0,0,0,7,0,0,0,83,0,0,0,115, - 56,0,0,0,100,1,68,0,93,32,125,2,116,0,124,1, - 124,2,131,2,114,4,116,1,124,0,124,2,116,2,124,1, - 124,2,131,2,131,3,1,0,113,4,124,0,106,3,160,4, + 56,0,0,0,100,1,68,0,93,16,125,2,116,0,124,1, + 124,2,131,2,114,18,116,1,124,0,124,2,116,2,124,1, + 124,2,131,2,131,3,1,0,113,2,124,0,106,3,160,4, 124,1,106,3,161,1,1,0,100,0,83,0,41,2,78,41, 4,218,10,95,95,109,111,100,117,108,101,95,95,218,8,95, 95,110,97,109,101,95,95,218,12,95,95,113,117,97,108,110, @@ -670,75 +668,149 @@ const unsigned char _Py_M__importlib_bootstrap_external[] = { 218,7,104,97,115,97,116,116,114,218,7,115,101,116,97,116, 116,114,218,7,103,101,116,97,116,116,114,218,8,95,95,100, 105,99,116,95,95,218,6,117,112,100,97,116,101,41,3,90, - 3,110,101,119,90,3,111,108,100,114,84,0,0,0,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,218,5,95, - 119,114,97,112,22,2,0,0,115,8,0,0,0,0,1,8, - 1,10,1,20,1,122,26,95,99,104,101,99,107,95,110,97, - 109,101,46,60,108,111,99,97,108,115,62,46,95,119,114,97, - 112,41,1,78,41,3,218,10,95,98,111,111,116,115,116,114, - 97,112,114,157,0,0,0,218,9,78,97,109,101,69,114,114, - 111,114,41,3,114,146,0,0,0,114,147,0,0,0,114,157, - 0,0,0,114,10,0,0,0,114,145,0,0,0,114,11,0, - 0,0,218,11,95,99,104,101,99,107,95,110,97,109,101,3, - 2,0,0,115,14,0,0,0,0,8,14,7,2,1,10,1, - 12,2,14,5,10,1,114,160,0,0,0,99,2,0,0,0, - 0,0,0,0,0,0,0,0,5,0,0,0,6,0,0,0, - 67,0,0,0,115,60,0,0,0,124,0,160,0,124,1,161, - 1,92,2,125,2,125,3,124,2,100,1,117,0,114,56,116, - 1,124,3,131,1,114,56,100,2,125,4,116,2,160,3,124, - 4,160,4,124,3,100,3,25,0,161,1,116,5,161,2,1, - 0,124,2,83,0,41,4,122,155,84,114,121,32,116,111,32, - 102,105,110,100,32,97,32,108,111,97,100,101,114,32,102,111, - 114,32,116,104,101,32,115,112,101,99,105,102,105,101,100,32, - 109,111,100,117,108,101,32,98,121,32,100,101,108,101,103,97, - 116,105,110,103,32,116,111,10,32,32,32,32,115,101,108,102, - 46,102,105,110,100,95,108,111,97,100,101,114,40,41,46,10, - 10,32,32,32,32,84,104,105,115,32,109,101,116,104,111,100, - 32,105,115,32,100,101,112,114,101,99,97,116,101,100,32,105, - 110,32,102,97,118,111,114,32,111,102,32,102,105,110,100,101, - 114,46,102,105,110,100,95,115,112,101,99,40,41,46,10,10, - 32,32,32,32,78,122,44,78,111,116,32,105,109,112,111,114, - 116,105,110,103,32,100,105,114,101,99,116,111,114,121,32,123, - 125,58,32,109,105,115,115,105,110,103,32,95,95,105,110,105, - 116,95,95,114,0,0,0,0,41,6,218,11,102,105,110,100, - 95,108,111,97,100,101,114,114,6,0,0,0,114,98,0,0, - 0,114,99,0,0,0,114,88,0,0,0,218,13,73,109,112, - 111,114,116,87,97,114,110,105,110,103,41,5,114,142,0,0, - 0,218,8,102,117,108,108,110,97,109,101,218,6,108,111,97, - 100,101,114,218,8,112,111,114,116,105,111,110,115,218,3,109, - 115,103,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,218,17,95,102,105,110,100,95,109,111,100,117,108,101,95, - 115,104,105,109,31,2,0,0,115,10,0,0,0,0,10,14, - 1,16,1,4,1,22,1,114,167,0,0,0,99,3,0,0, - 0,0,0,0,0,0,0,0,0,6,0,0,0,4,0,0, - 0,67,0,0,0,115,166,0,0,0,124,0,100,1,100,2, - 133,2,25,0,125,3,124,3,116,0,107,3,114,64,100,3, - 124,1,155,2,100,4,124,3,155,2,157,4,125,4,116,1, - 160,2,100,5,124,4,161,2,1,0,116,3,124,4,102,1, - 105,0,124,2,164,1,142,1,130,1,116,4,124,0,131,1, - 100,6,107,0,114,106,100,7,124,1,155,2,157,2,125,4, - 116,1,160,2,100,5,124,4,161,2,1,0,116,5,124,4, - 131,1,130,1,116,6,124,0,100,2,100,8,133,2,25,0, - 131,1,125,5,124,5,100,9,64,0,114,162,100,10,124,5, - 155,2,100,11,124,1,155,2,157,4,125,4,116,3,124,4, - 102,1,105,0,124,2,164,1,142,1,130,1,124,5,83,0, - 41,12,97,84,2,0,0,80,101,114,102,111,114,109,32,98, - 97,115,105,99,32,118,97,108,105,100,105,116,121,32,99,104, - 101,99,107,105,110,103,32,111,102,32,97,32,112,121,99,32, - 104,101,97,100,101,114,32,97,110,100,32,114,101,116,117,114, - 110,32,116,104,101,32,102,108,97,103,115,32,102,105,101,108, - 100,44,10,32,32,32,32,119,104,105,99,104,32,100,101,116, - 101,114,109,105,110,101,115,32,104,111,119,32,116,104,101,32, - 112,121,99,32,115,104,111,117,108,100,32,98,101,32,102,117, - 114,116,104,101,114,32,118,97,108,105,100,97,116,101,100,32, - 97,103,97,105,110,115,116,32,116,104,101,32,115,111,117,114, - 99,101,46,10,10,32,32,32,32,42,100,97,116,97,42,32, - 105,115,32,116,104,101,32,99,111,110,116,101,110,116,115,32, - 111,102,32,116,104,101,32,112,121,99,32,102,105,108,101,46, - 32,40,79,110,108,121,32,116,104,101,32,102,105,114,115,116, - 32,49,54,32,98,121,116,101,115,32,97,114,101,10,32,32, - 32,32,114,101,113,117,105,114,101,100,44,32,116,104,111,117, - 103,104,46,41,10,10,32,32,32,32,42,110,97,109,101,42, + 3,110,101,119,90,3,111,108,100,114,85,0,0,0,114,7, + 0,0,0,114,7,0,0,0,114,8,0,0,0,218,5,95, + 119,114,97,112,43,2,0,0,115,10,0,0,0,8,1,10, + 1,18,1,2,128,18,1,122,26,95,99,104,101,99,107,95, + 110,97,109,101,46,60,108,111,99,97,108,115,62,46,95,119, + 114,97,112,114,69,0,0,0,41,2,218,10,95,98,111,111, + 116,115,116,114,97,112,114,158,0,0,0,41,3,114,147,0, + 0,0,114,148,0,0,0,114,158,0,0,0,114,7,0,0, + 0,114,146,0,0,0,114,8,0,0,0,218,11,95,99,104, + 101,99,107,95,110,97,109,101,22,2,0,0,115,12,0,0, + 0,14,8,8,10,8,1,8,2,10,6,4,1,114,160,0, + 0,0,99,2,0,0,0,0,0,0,0,0,0,0,0,5, + 0,0,0,6,0,0,0,67,0,0,0,115,72,0,0,0, + 116,0,160,1,100,1,116,2,161,2,1,0,124,0,160,3, + 124,1,161,1,92,2,125,2,125,3,124,2,100,2,117,0, + 114,34,116,4,124,3,131,1,114,34,100,3,125,4,116,0, + 160,1,124,4,160,5,124,3,100,4,25,0,161,1,116,6, + 161,2,1,0,124,2,83,0,41,5,122,155,84,114,121,32, + 116,111,32,102,105,110,100,32,97,32,108,111,97,100,101,114, + 32,102,111,114,32,116,104,101,32,115,112,101,99,105,102,105, + 101,100,32,109,111,100,117,108,101,32,98,121,32,100,101,108, + 101,103,97,116,105,110,103,32,116,111,10,32,32,32,32,115, + 101,108,102,46,102,105,110,100,95,108,111,97,100,101,114,40, + 41,46,10,10,32,32,32,32,84,104,105,115,32,109,101,116, + 104,111,100,32,105,115,32,100,101,112,114,101,99,97,116,101, + 100,32,105,110,32,102,97,118,111,114,32,111,102,32,102,105, + 110,100,101,114,46,102,105,110,100,95,115,112,101,99,40,41, + 46,10,10,32,32,32,32,122,90,102,105,110,100,95,109,111, + 100,117,108,101,40,41,32,105,115,32,100,101,112,114,101,99, + 97,116,101,100,32,97,110,100,32,115,108,97,116,101,100,32, + 102,111,114,32,114,101,109,111,118,97,108,32,105,110,32,80, + 121,116,104,111,110,32,51,46,49,50,59,32,117,115,101,32, + 102,105,110,100,95,115,112,101,99,40,41,32,105,110,115,116, + 101,97,100,78,122,44,78,111,116,32,105,109,112,111,114,116, + 105,110,103,32,100,105,114,101,99,116,111,114,121,32,123,125, + 58,32,109,105,115,115,105,110,103,32,95,95,105,110,105,116, + 95,95,114,0,0,0,0,41,7,114,99,0,0,0,114,100, + 0,0,0,114,101,0,0,0,218,11,102,105,110,100,95,108, + 111,97,100,101,114,114,4,0,0,0,114,89,0,0,0,218, + 13,73,109,112,111,114,116,87,97,114,110,105,110,103,41,5, + 114,143,0,0,0,218,8,102,117,108,108,110,97,109,101,218, + 6,108,111,97,100,101,114,218,8,112,111,114,116,105,111,110, + 115,218,3,109,115,103,114,7,0,0,0,114,7,0,0,0, + 114,8,0,0,0,218,17,95,102,105,110,100,95,109,111,100, + 117,108,101,95,115,104,105,109,53,2,0,0,115,16,0,0, + 0,6,7,2,2,4,254,14,6,16,1,4,1,22,1,4, + 1,114,167,0,0,0,99,3,0,0,0,0,0,0,0,0, + 0,0,0,6,0,0,0,4,0,0,0,67,0,0,0,115, + 166,0,0,0,124,0,100,1,100,2,133,2,25,0,125,3, + 124,3,116,0,107,3,114,32,100,3,124,1,155,2,100,4, + 124,3,155,2,157,4,125,4,116,1,160,2,100,5,124,4, + 161,2,1,0,116,3,124,4,102,1,105,0,124,2,164,1, + 142,1,130,1,116,4,124,0,131,1,100,6,107,0,114,53, + 100,7,124,1,155,2,157,2,125,4,116,1,160,2,100,5, + 124,4,161,2,1,0,116,5,124,4,131,1,130,1,116,6, + 124,0,100,2,100,8,133,2,25,0,131,1,125,5,124,5, + 100,9,64,0,114,81,100,10,124,5,155,2,100,11,124,1, + 155,2,157,4,125,4,116,3,124,4,102,1,105,0,124,2, + 164,1,142,1,130,1,124,5,83,0,41,12,97,84,2,0, + 0,80,101,114,102,111,114,109,32,98,97,115,105,99,32,118, + 97,108,105,100,105,116,121,32,99,104,101,99,107,105,110,103, + 32,111,102,32,97,32,112,121,99,32,104,101,97,100,101,114, + 32,97,110,100,32,114,101,116,117,114,110,32,116,104,101,32, + 102,108,97,103,115,32,102,105,101,108,100,44,10,32,32,32, + 32,119,104,105,99,104,32,100,101,116,101,114,109,105,110,101, + 115,32,104,111,119,32,116,104,101,32,112,121,99,32,115,104, + 111,117,108,100,32,98,101,32,102,117,114,116,104,101,114,32, + 118,97,108,105,100,97,116,101,100,32,97,103,97,105,110,115, + 116,32,116,104,101,32,115,111,117,114,99,101,46,10,10,32, + 32,32,32,42,100,97,116,97,42,32,105,115,32,116,104,101, + 32,99,111,110,116,101,110,116,115,32,111,102,32,116,104,101, + 32,112,121,99,32,102,105,108,101,46,32,40,79,110,108,121, + 32,116,104,101,32,102,105,114,115,116,32,49,54,32,98,121, + 116,101,115,32,97,114,101,10,32,32,32,32,114,101,113,117, + 105,114,101,100,44,32,116,104,111,117,103,104,46,41,10,10, + 32,32,32,32,42,110,97,109,101,42,32,105,115,32,116,104, + 101,32,110,97,109,101,32,111,102,32,116,104,101,32,109,111, + 100,117,108,101,32,98,101,105,110,103,32,105,109,112,111,114, + 116,101,100,46,32,73,116,32,105,115,32,117,115,101,100,32, + 102,111,114,32,108,111,103,103,105,110,103,46,10,10,32,32, + 32,32,42,101,120,99,95,100,101,116,97,105,108,115,42,32, + 105,115,32,97,32,100,105,99,116,105,111,110,97,114,121,32, + 112,97,115,115,101,100,32,116,111,32,73,109,112,111,114,116, + 69,114,114,111,114,32,105,102,32,105,116,32,114,97,105,115, + 101,100,32,102,111,114,10,32,32,32,32,105,109,112,114,111, + 118,101,100,32,100,101,98,117,103,103,105,110,103,46,10,10, + 32,32,32,32,73,109,112,111,114,116,69,114,114,111,114,32, + 105,115,32,114,97,105,115,101,100,32,119,104,101,110,32,116, + 104,101,32,109,97,103,105,99,32,110,117,109,98,101,114,32, + 105,115,32,105,110,99,111,114,114,101,99,116,32,111,114,32, + 119,104,101,110,32,116,104,101,32,102,108,97,103,115,10,32, + 32,32,32,102,105,101,108,100,32,105,115,32,105,110,118,97, + 108,105,100,46,32,69,79,70,69,114,114,111,114,32,105,115, + 32,114,97,105,115,101,100,32,119,104,101,110,32,116,104,101, + 32,100,97,116,97,32,105,115,32,102,111,117,110,100,32,116, + 111,32,98,101,32,116,114,117,110,99,97,116,101,100,46,10, + 10,32,32,32,32,78,114,31,0,0,0,122,20,98,97,100, + 32,109,97,103,105,99,32,110,117,109,98,101,114,32,105,110, + 32,122,2,58,32,250,2,123,125,233,16,0,0,0,122,40, + 114,101,97,99,104,101,100,32,69,79,70,32,119,104,105,108, + 101,32,114,101,97,100,105,110,103,32,112,121,99,32,104,101, + 97,100,101,114,32,111,102,32,233,8,0,0,0,233,252,255, + 255,255,122,14,105,110,118,97,108,105,100,32,102,108,97,103, + 115,32,122,4,32,105,110,32,41,7,218,12,77,65,71,73, + 67,95,78,85,77,66,69,82,114,159,0,0,0,218,16,95, + 118,101,114,98,111,115,101,95,109,101,115,115,97,103,101,114, + 142,0,0,0,114,4,0,0,0,218,8,69,79,70,69,114, + 114,111,114,114,42,0,0,0,41,6,114,41,0,0,0,114, + 141,0,0,0,218,11,101,120,99,95,100,101,116,97,105,108, + 115,90,5,109,97,103,105,99,114,117,0,0,0,114,16,0, + 0,0,114,7,0,0,0,114,7,0,0,0,114,8,0,0, + 0,218,13,95,99,108,97,115,115,105,102,121,95,112,121,99, + 73,2,0,0,115,28,0,0,0,12,16,8,1,16,1,12, + 1,16,1,12,1,10,1,12,1,8,1,16,1,8,2,16, + 1,16,1,4,1,114,176,0,0,0,99,5,0,0,0,0, + 0,0,0,0,0,0,0,6,0,0,0,4,0,0,0,67, + 0,0,0,115,124,0,0,0,116,0,124,0,100,1,100,2, + 133,2,25,0,131,1,124,1,100,3,64,0,107,3,114,31, + 100,4,124,3,155,2,157,2,125,5,116,1,160,2,100,5, + 124,5,161,2,1,0,116,3,124,5,102,1,105,0,124,4, + 164,1,142,1,130,1,124,2,100,6,117,1,114,58,116,0, + 124,0,100,2,100,7,133,2,25,0,131,1,124,2,100,3, + 64,0,107,3,114,60,116,3,100,4,124,3,155,2,157,2, + 102,1,105,0,124,4,164,1,142,1,130,1,100,6,83,0, + 100,6,83,0,41,8,97,7,2,0,0,86,97,108,105,100, + 97,116,101,32,97,32,112,121,99,32,97,103,97,105,110,115, + 116,32,116,104,101,32,115,111,117,114,99,101,32,108,97,115, + 116,45,109,111,100,105,102,105,101,100,32,116,105,109,101,46, + 10,10,32,32,32,32,42,100,97,116,97,42,32,105,115,32, + 116,104,101,32,99,111,110,116,101,110,116,115,32,111,102,32, + 116,104,101,32,112,121,99,32,102,105,108,101,46,32,40,79, + 110,108,121,32,116,104,101,32,102,105,114,115,116,32,49,54, + 32,98,121,116,101,115,32,97,114,101,10,32,32,32,32,114, + 101,113,117,105,114,101,100,46,41,10,10,32,32,32,32,42, + 115,111,117,114,99,101,95,109,116,105,109,101,42,32,105,115, + 32,116,104,101,32,108,97,115,116,32,109,111,100,105,102,105, + 101,100,32,116,105,109,101,115,116,97,109,112,32,111,102,32, + 116,104,101,32,115,111,117,114,99,101,32,102,105,108,101,46, + 10,10,32,32,32,32,42,115,111,117,114,99,101,95,115,105, + 122,101,42,32,105,115,32,78,111,110,101,32,111,114,32,116, + 104,101,32,115,105,122,101,32,111,102,32,116,104,101,32,115, + 111,117,114,99,101,32,102,105,108,101,32,105,110,32,98,121, + 116,101,115,46,10,10,32,32,32,32,42,110,97,109,101,42, 32,105,115,32,116,104,101,32,110,97,109,101,32,111,102,32, 116,104,101,32,109,111,100,117,108,101,32,98,101,105,110,103, 32,105,109,112,111,114,116,101,100,46,32,73,116,32,105,115, @@ -749,93 +821,26 @@ const unsigned char _Py_M__importlib_bootstrap_external[] = { 73,109,112,111,114,116,69,114,114,111,114,32,105,102,32,105, 116,32,114,97,105,115,101,100,32,102,111,114,10,32,32,32, 32,105,109,112,114,111,118,101,100,32,100,101,98,117,103,103, - 105,110,103,46,10,10,32,32,32,32,73,109,112,111,114,116, - 69,114,114,111,114,32,105,115,32,114,97,105,115,101,100,32, - 119,104,101,110,32,116,104,101,32,109,97,103,105,99,32,110, - 117,109,98,101,114,32,105,115,32,105,110,99,111,114,114,101, - 99,116,32,111,114,32,119,104,101,110,32,116,104,101,32,102, - 108,97,103,115,10,32,32,32,32,102,105,101,108,100,32,105, - 115,32,105,110,118,97,108,105,100,46,32,69,79,70,69,114, - 114,111,114,32,105,115,32,114,97,105,115,101,100,32,119,104, - 101,110,32,116,104,101,32,100,97,116,97,32,105,115,32,102, - 111,117,110,100,32,116,111,32,98,101,32,116,114,117,110,99, - 97,116,101,100,46,10,10,32,32,32,32,78,114,34,0,0, - 0,122,20,98,97,100,32,109,97,103,105,99,32,110,117,109, - 98,101,114,32,105,110,32,122,2,58,32,250,2,123,125,233, - 16,0,0,0,122,40,114,101,97,99,104,101,100,32,69,79, - 70,32,119,104,105,108,101,32,114,101,97,100,105,110,103,32, - 112,121,99,32,104,101,97,100,101,114,32,111,102,32,233,8, - 0,0,0,233,252,255,255,255,122,14,105,110,118,97,108,105, - 100,32,102,108,97,103,115,32,122,4,32,105,110,32,41,7, - 218,12,77,65,71,73,67,95,78,85,77,66,69,82,114,158, - 0,0,0,218,16,95,118,101,114,98,111,115,101,95,109,101, - 115,115,97,103,101,114,141,0,0,0,114,6,0,0,0,218, - 8,69,79,70,69,114,114,111,114,114,44,0,0,0,41,6, - 114,43,0,0,0,114,140,0,0,0,218,11,101,120,99,95, - 100,101,116,97,105,108,115,90,5,109,97,103,105,99,114,116, - 0,0,0,114,22,0,0,0,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,13,95,99,108,97,115,115,105, - 102,121,95,112,121,99,48,2,0,0,115,28,0,0,0,0, - 16,12,1,8,1,16,1,12,1,16,1,12,1,10,1,12, - 1,8,1,16,2,8,1,16,1,16,1,114,176,0,0,0, - 99,5,0,0,0,0,0,0,0,0,0,0,0,6,0,0, - 0,4,0,0,0,67,0,0,0,115,120,0,0,0,116,0, - 124,0,100,1,100,2,133,2,25,0,131,1,124,1,100,3, - 64,0,107,3,114,62,100,4,124,3,155,2,157,2,125,5, - 116,1,160,2,100,5,124,5,161,2,1,0,116,3,124,5, - 102,1,105,0,124,4,164,1,142,1,130,1,124,2,100,6, - 117,1,114,116,116,0,124,0,100,2,100,7,133,2,25,0, - 131,1,124,2,100,3,64,0,107,3,114,116,116,3,100,4, - 124,3,155,2,157,2,102,1,105,0,124,4,164,1,142,1, - 130,1,100,6,83,0,41,8,97,7,2,0,0,86,97,108, - 105,100,97,116,101,32,97,32,112,121,99,32,97,103,97,105, - 110,115,116,32,116,104,101,32,115,111,117,114,99,101,32,108, - 97,115,116,45,109,111,100,105,102,105,101,100,32,116,105,109, - 101,46,10,10,32,32,32,32,42,100,97,116,97,42,32,105, - 115,32,116,104,101,32,99,111,110,116,101,110,116,115,32,111, - 102,32,116,104,101,32,112,121,99,32,102,105,108,101,46,32, - 40,79,110,108,121,32,116,104,101,32,102,105,114,115,116,32, - 49,54,32,98,121,116,101,115,32,97,114,101,10,32,32,32, - 32,114,101,113,117,105,114,101,100,46,41,10,10,32,32,32, - 32,42,115,111,117,114,99,101,95,109,116,105,109,101,42,32, - 105,115,32,116,104,101,32,108,97,115,116,32,109,111,100,105, - 102,105,101,100,32,116,105,109,101,115,116,97,109,112,32,111, - 102,32,116,104,101,32,115,111,117,114,99,101,32,102,105,108, - 101,46,10,10,32,32,32,32,42,115,111,117,114,99,101,95, - 115,105,122,101,42,32,105,115,32,78,111,110,101,32,111,114, - 32,116,104,101,32,115,105,122,101,32,111,102,32,116,104,101, - 32,115,111,117,114,99,101,32,102,105,108,101,32,105,110,32, - 98,121,116,101,115,46,10,10,32,32,32,32,42,110,97,109, - 101,42,32,105,115,32,116,104,101,32,110,97,109,101,32,111, - 102,32,116,104,101,32,109,111,100,117,108,101,32,98,101,105, - 110,103,32,105,109,112,111,114,116,101,100,46,32,73,116,32, - 105,115,32,117,115,101,100,32,102,111,114,32,108,111,103,103, - 105,110,103,46,10,10,32,32,32,32,42,101,120,99,95,100, - 101,116,97,105,108,115,42,32,105,115,32,97,32,100,105,99, - 116,105,111,110,97,114,121,32,112,97,115,115,101,100,32,116, - 111,32,73,109,112,111,114,116,69,114,114,111,114,32,105,102, - 32,105,116,32,114,97,105,115,101,100,32,102,111,114,10,32, - 32,32,32,105,109,112,114,111,118,101,100,32,100,101,98,117, - 103,103,105,110,103,46,10,10,32,32,32,32,65,110,32,73, - 109,112,111,114,116,69,114,114,111,114,32,105,115,32,114,97, - 105,115,101,100,32,105,102,32,116,104,101,32,98,121,116,101, - 99,111,100,101,32,105,115,32,115,116,97,108,101,46,10,10, - 32,32,32,32,114,170,0,0,0,233,12,0,0,0,114,33, - 0,0,0,122,22,98,121,116,101,99,111,100,101,32,105,115, - 32,115,116,97,108,101,32,102,111,114,32,114,168,0,0,0, - 78,114,169,0,0,0,41,4,114,44,0,0,0,114,158,0, - 0,0,114,173,0,0,0,114,141,0,0,0,41,6,114,43, - 0,0,0,218,12,115,111,117,114,99,101,95,109,116,105,109, - 101,218,11,115,111,117,114,99,101,95,115,105,122,101,114,140, - 0,0,0,114,175,0,0,0,114,116,0,0,0,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,218,23,95,118, - 97,108,105,100,97,116,101,95,116,105,109,101,115,116,97,109, - 112,95,112,121,99,81,2,0,0,115,16,0,0,0,0,19, - 24,1,10,1,12,1,16,1,8,1,22,255,2,2,114,180, + 105,110,103,46,10,10,32,32,32,32,65,110,32,73,109,112, + 111,114,116,69,114,114,111,114,32,105,115,32,114,97,105,115, + 101,100,32,105,102,32,116,104,101,32,98,121,116,101,99,111, + 100,101,32,105,115,32,115,116,97,108,101,46,10,10,32,32, + 32,32,114,170,0,0,0,233,12,0,0,0,114,30,0,0, + 0,122,22,98,121,116,101,99,111,100,101,32,105,115,32,115, + 116,97,108,101,32,102,111,114,32,114,168,0,0,0,78,114, + 169,0,0,0,41,4,114,42,0,0,0,114,159,0,0,0, + 114,173,0,0,0,114,142,0,0,0,41,6,114,41,0,0, + 0,218,12,115,111,117,114,99,101,95,109,116,105,109,101,218, + 11,115,111,117,114,99,101,95,115,105,122,101,114,141,0,0, + 0,114,175,0,0,0,114,117,0,0,0,114,7,0,0,0, + 114,7,0,0,0,114,8,0,0,0,218,23,95,118,97,108, + 105,100,97,116,101,95,116,105,109,101,115,116,97,109,112,95, + 112,121,99,106,2,0,0,115,18,0,0,0,24,19,10,1, + 12,1,16,1,8,1,22,1,2,255,22,2,8,254,114,180, 0,0,0,99,4,0,0,0,0,0,0,0,0,0,0,0, 4,0,0,0,4,0,0,0,67,0,0,0,115,42,0,0, 0,124,0,100,1,100,2,133,2,25,0,124,1,107,3,114, - 38,116,0,100,3,124,2,155,2,157,2,102,1,105,0,124, + 19,116,0,100,3,124,2,155,2,157,2,102,1,105,0,124, 3,164,1,142,1,130,1,100,4,83,0,41,5,97,243,1, 0,0,86,97,108,105,100,97,116,101,32,97,32,104,97,115, 104,45,98,97,115,101,100,32,112,121,99,32,98,121,32,99, @@ -872,1245 +877,1212 @@ const unsigned char _Py_M__importlib_bootstrap_external[] = { 46,104,97,115,104,32,105,110,32,98,121,116,101,99,111,100, 101,32,100,111,101,115,110,39,116,32,109,97,116,99,104,32, 104,97,115,104,32,111,102,32,115,111,117,114,99,101,32,78, - 41,1,114,141,0,0,0,41,4,114,43,0,0,0,218,11, - 115,111,117,114,99,101,95,104,97,115,104,114,140,0,0,0, - 114,175,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,18,95,118,97,108,105,100,97,116,101,95, - 104,97,115,104,95,112,121,99,109,2,0,0,115,12,0,0, - 0,0,17,16,1,2,1,8,255,4,2,2,254,114,182,0, - 0,0,99,4,0,0,0,0,0,0,0,0,0,0,0,5, - 0,0,0,5,0,0,0,67,0,0,0,115,80,0,0,0, - 116,0,160,1,124,0,161,1,125,4,116,2,124,4,116,3, - 131,2,114,56,116,4,160,5,100,1,124,2,161,2,1,0, - 124,3,100,2,117,1,114,52,116,6,160,7,124,4,124,3, - 161,2,1,0,124,4,83,0,116,8,100,3,160,9,124,2, - 161,1,124,1,124,2,100,4,141,3,130,1,100,2,83,0, - 41,5,122,35,67,111,109,112,105,108,101,32,98,121,116,101, - 99,111,100,101,32,97,115,32,102,111,117,110,100,32,105,110, - 32,97,32,112,121,99,46,122,21,99,111,100,101,32,111,98, - 106,101,99,116,32,102,114,111,109,32,123,33,114,125,78,122, - 23,78,111,110,45,99,111,100,101,32,111,98,106,101,99,116, - 32,105,110,32,123,33,114,125,169,2,114,140,0,0,0,114, - 65,0,0,0,41,10,218,7,109,97,114,115,104,97,108,90, - 5,108,111,97,100,115,218,10,105,115,105,110,115,116,97,110, - 99,101,218,10,95,99,111,100,101,95,116,121,112,101,114,158, - 0,0,0,114,173,0,0,0,218,4,95,105,109,112,90,16, - 95,102,105,120,95,99,111,95,102,105,108,101,110,97,109,101, - 114,141,0,0,0,114,88,0,0,0,41,5,114,43,0,0, - 0,114,140,0,0,0,114,131,0,0,0,114,133,0,0,0, - 218,4,99,111,100,101,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,17,95,99,111,109,112,105,108,101,95, - 98,121,116,101,99,111,100,101,133,2,0,0,115,18,0,0, - 0,0,2,10,1,10,1,12,1,8,1,12,1,4,2,10, - 1,4,255,114,189,0,0,0,99,3,0,0,0,0,0,0, - 0,0,0,0,0,4,0,0,0,5,0,0,0,67,0,0, - 0,115,70,0,0,0,116,0,116,1,131,1,125,3,124,3, - 160,2,116,3,100,1,131,1,161,1,1,0,124,3,160,2, - 116,3,124,1,131,1,161,1,1,0,124,3,160,2,116,3, - 124,2,131,1,161,1,1,0,124,3,160,2,116,4,160,5, - 124,0,161,1,161,1,1,0,124,3,83,0,41,2,122,43, - 80,114,111,100,117,99,101,32,116,104,101,32,100,97,116,97, - 32,102,111,114,32,97,32,116,105,109,101,115,116,97,109,112, - 45,98,97,115,101,100,32,112,121,99,46,114,0,0,0,0, - 41,6,218,9,98,121,116,101,97,114,114,97,121,114,172,0, - 0,0,218,6,101,120,116,101,110,100,114,39,0,0,0,114, - 184,0,0,0,218,5,100,117,109,112,115,41,4,114,188,0, - 0,0,218,5,109,116,105,109,101,114,179,0,0,0,114,43, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,218,22,95,99,111,100,101,95,116,111,95,116,105,109, - 101,115,116,97,109,112,95,112,121,99,146,2,0,0,115,12, - 0,0,0,0,2,8,1,14,1,14,1,14,1,16,1,114, - 194,0,0,0,84,99,3,0,0,0,0,0,0,0,0,0, - 0,0,5,0,0,0,5,0,0,0,67,0,0,0,115,80, - 0,0,0,116,0,116,1,131,1,125,3,100,1,124,2,100, - 1,62,0,66,0,125,4,124,3,160,2,116,3,124,4,131, - 1,161,1,1,0,116,4,124,1,131,1,100,2,107,2,115, - 50,74,0,130,1,124,3,160,2,124,1,161,1,1,0,124, - 3,160,2,116,5,160,6,124,0,161,1,161,1,1,0,124, - 3,83,0,41,3,122,38,80,114,111,100,117,99,101,32,116, - 104,101,32,100,97,116,97,32,102,111,114,32,97,32,104,97, - 115,104,45,98,97,115,101,100,32,112,121,99,46,114,4,0, - 0,0,114,170,0,0,0,41,7,114,190,0,0,0,114,172, - 0,0,0,114,191,0,0,0,114,39,0,0,0,114,6,0, - 0,0,114,184,0,0,0,114,192,0,0,0,41,5,114,188, - 0,0,0,114,181,0,0,0,90,7,99,104,101,99,107,101, - 100,114,43,0,0,0,114,22,0,0,0,114,10,0,0,0, - 114,10,0,0,0,114,11,0,0,0,218,17,95,99,111,100, - 101,95,116,111,95,104,97,115,104,95,112,121,99,156,2,0, - 0,115,14,0,0,0,0,2,8,1,12,1,14,1,16,1, - 10,1,16,1,114,195,0,0,0,99,1,0,0,0,0,0, - 0,0,0,0,0,0,5,0,0,0,6,0,0,0,67,0, - 0,0,115,62,0,0,0,100,1,100,2,108,0,125,1,116, - 1,160,2,124,0,161,1,106,3,125,2,124,1,160,4,124, - 2,161,1,125,3,116,1,160,5,100,2,100,3,161,2,125, - 4,124,4,160,6,124,0,160,6,124,3,100,1,25,0,161, - 1,161,1,83,0,41,4,122,121,68,101,99,111,100,101,32, - 98,121,116,101,115,32,114,101,112,114,101,115,101,110,116,105, - 110,103,32,115,111,117,114,99,101,32,99,111,100,101,32,97, - 110,100,32,114,101,116,117,114,110,32,116,104,101,32,115,116, - 114,105,110,103,46,10,10,32,32,32,32,85,110,105,118,101, - 114,115,97,108,32,110,101,119,108,105,110,101,32,115,117,112, - 112,111,114,116,32,105,115,32,117,115,101,100,32,105,110,32, - 116,104,101,32,100,101,99,111,100,105,110,103,46,10,32,32, - 32,32,114,0,0,0,0,78,84,41,7,218,8,116,111,107, - 101,110,105,122,101,114,90,0,0,0,90,7,66,121,116,101, - 115,73,79,90,8,114,101,97,100,108,105,110,101,90,15,100, - 101,116,101,99,116,95,101,110,99,111,100,105,110,103,90,25, - 73,110,99,114,101,109,101,110,116,97,108,78,101,119,108,105, - 110,101,68,101,99,111,100,101,114,218,6,100,101,99,111,100, - 101,41,5,218,12,115,111,117,114,99,101,95,98,121,116,101, - 115,114,196,0,0,0,90,21,115,111,117,114,99,101,95,98, - 121,116,101,115,95,114,101,97,100,108,105,110,101,218,8,101, - 110,99,111,100,105,110,103,90,15,110,101,119,108,105,110,101, - 95,100,101,99,111,100,101,114,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,13,100,101,99,111,100,101,95, - 115,111,117,114,99,101,167,2,0,0,115,10,0,0,0,0, - 5,8,1,12,1,10,1,12,1,114,200,0,0,0,169,2, - 114,164,0,0,0,218,26,115,117,98,109,111,100,117,108,101, - 95,115,101,97,114,99,104,95,108,111,99,97,116,105,111,110, - 115,99,2,0,0,0,0,0,0,0,2,0,0,0,9,0, - 0,0,8,0,0,0,67,0,0,0,115,12,1,0,0,124, - 1,100,1,117,0,114,58,100,2,125,1,116,0,124,2,100, - 3,131,2,114,68,122,14,124,2,160,1,124,0,161,1,125, - 1,87,0,113,68,4,0,116,2,121,54,1,0,1,0,1, - 0,89,0,113,68,48,0,110,10,116,3,160,4,124,1,161, - 1,125,1,116,5,106,6,124,0,124,2,124,1,100,4,141, - 3,125,4,100,5,124,4,95,7,124,2,100,1,117,0,114, - 152,116,8,131,0,68,0,93,42,92,2,125,5,125,6,124, - 1,160,9,116,10,124,6,131,1,161,1,114,104,124,5,124, - 0,124,1,131,2,125,2,124,2,124,4,95,11,1,0,113, - 152,113,104,100,1,83,0,124,3,116,12,117,0,114,216,116, - 0,124,2,100,6,131,2,114,222,122,14,124,2,160,13,124, - 0,161,1,125,7,87,0,110,18,4,0,116,2,121,202,1, - 0,1,0,1,0,89,0,113,222,48,0,124,7,114,222,103, - 0,124,4,95,14,110,6,124,3,124,4,95,14,124,4,106, - 14,103,0,107,2,144,1,114,8,124,1,144,1,114,8,116, - 15,124,1,131,1,100,7,25,0,125,8,124,4,106,14,160, - 16,124,8,161,1,1,0,124,4,83,0,41,8,97,61,1, - 0,0,82,101,116,117,114,110,32,97,32,109,111,100,117,108, - 101,32,115,112,101,99,32,98,97,115,101,100,32,111,110,32, - 97,32,102,105,108,101,32,108,111,99,97,116,105,111,110,46, - 10,10,32,32,32,32,84,111,32,105,110,100,105,99,97,116, - 101,32,116,104,97,116,32,116,104,101,32,109,111,100,117,108, - 101,32,105,115,32,97,32,112,97,99,107,97,103,101,44,32, - 115,101,116,10,32,32,32,32,115,117,98,109,111,100,117,108, - 101,95,115,101,97,114,99,104,95,108,111,99,97,116,105,111, - 110,115,32,116,111,32,97,32,108,105,115,116,32,111,102,32, - 100,105,114,101,99,116,111,114,121,32,112,97,116,104,115,46, - 32,32,65,110,10,32,32,32,32,101,109,112,116,121,32,108, - 105,115,116,32,105,115,32,115,117,102,102,105,99,105,101,110, - 116,44,32,116,104,111,117,103,104,32,105,116,115,32,110,111, - 116,32,111,116,104,101,114,119,105,115,101,32,117,115,101,102, - 117,108,32,116,111,32,116,104,101,10,32,32,32,32,105,109, - 112,111,114,116,32,115,121,115,116,101,109,46,10,10,32,32, - 32,32,84,104,101,32,108,111,97,100,101,114,32,109,117,115, - 116,32,116,97,107,101,32,97,32,115,112,101,99,32,97,115, - 32,105,116,115,32,111,110,108,121,32,95,95,105,110,105,116, - 95,95,40,41,32,97,114,103,46,10,10,32,32,32,32,78, - 122,9,60,117,110,107,110,111,119,110,62,218,12,103,101,116, - 95,102,105,108,101,110,97,109,101,169,1,218,6,111,114,105, - 103,105,110,84,218,10,105,115,95,112,97,99,107,97,103,101, - 114,0,0,0,0,41,17,114,152,0,0,0,114,203,0,0, - 0,114,141,0,0,0,114,24,0,0,0,114,102,0,0,0, - 114,158,0,0,0,218,10,77,111,100,117,108,101,83,112,101, - 99,90,13,95,115,101,116,95,102,105,108,101,97,116,116,114, - 218,27,95,103,101,116,95,115,117,112,112,111,114,116,101,100, - 95,102,105,108,101,95,108,111,97,100,101,114,115,114,58,0, - 0,0,114,135,0,0,0,114,164,0,0,0,218,9,95,80, - 79,80,85,76,65,84,69,114,206,0,0,0,114,202,0,0, - 0,114,74,0,0,0,114,61,0,0,0,41,9,114,140,0, - 0,0,90,8,108,111,99,97,116,105,111,110,114,164,0,0, - 0,114,202,0,0,0,218,4,115,112,101,99,218,12,108,111, - 97,100,101,114,95,99,108,97,115,115,218,8,115,117,102,102, - 105,120,101,115,114,206,0,0,0,90,7,100,105,114,110,97, - 109,101,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,218,23,115,112,101,99,95,102,114,111,109,95,102,105,108, - 101,95,108,111,99,97,116,105,111,110,184,2,0,0,115,62, - 0,0,0,0,12,8,4,4,1,10,2,2,1,14,1,12, - 1,8,2,10,8,16,1,6,3,8,1,14,1,14,1,10, - 1,6,1,6,2,4,3,8,2,10,1,2,1,14,1,12, - 1,6,2,4,1,8,2,6,1,12,1,6,1,12,1,12, - 2,114,213,0,0,0,99,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,0,4,0,0,0,64,0,0,0,115, - 80,0,0,0,101,0,90,1,100,0,90,2,100,1,90,3, - 100,2,90,4,100,3,90,5,100,4,90,6,101,7,100,5, - 100,6,132,0,131,1,90,8,101,7,100,7,100,8,132,0, - 131,1,90,9,101,7,100,14,100,10,100,11,132,1,131,1, - 90,10,101,7,100,15,100,12,100,13,132,1,131,1,90,11, - 100,9,83,0,41,16,218,21,87,105,110,100,111,119,115,82, - 101,103,105,115,116,114,121,70,105,110,100,101,114,122,62,77, - 101,116,97,32,112,97,116,104,32,102,105,110,100,101,114,32, - 102,111,114,32,109,111,100,117,108,101,115,32,100,101,99,108, - 97,114,101,100,32,105,110,32,116,104,101,32,87,105,110,100, - 111,119,115,32,114,101,103,105,115,116,114,121,46,122,59,83, - 111,102,116,119,97,114,101,92,80,121,116,104,111,110,92,80, - 121,116,104,111,110,67,111,114,101,92,123,115,121,115,95,118, - 101,114,115,105,111,110,125,92,77,111,100,117,108,101,115,92, - 123,102,117,108,108,110,97,109,101,125,122,65,83,111,102,116, - 119,97,114,101,92,80,121,116,104,111,110,92,80,121,116,104, - 111,110,67,111,114,101,92,123,115,121,115,95,118,101,114,115, - 105,111,110,125,92,77,111,100,117,108,101,115,92,123,102,117, - 108,108,110,97,109,101,125,92,68,101,98,117,103,70,99,2, - 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,8, - 0,0,0,67,0,0,0,115,54,0,0,0,122,16,116,0, - 160,1,116,0,106,2,124,1,161,2,87,0,83,0,4,0, - 116,3,121,48,1,0,1,0,1,0,116,0,160,1,116,0, - 106,4,124,1,161,2,6,0,89,0,83,0,48,0,100,0, - 83,0,114,69,0,0,0,41,5,218,6,119,105,110,114,101, - 103,90,7,79,112,101,110,75,101,121,90,17,72,75,69,89, - 95,67,85,82,82,69,78,84,95,85,83,69,82,114,76,0, - 0,0,90,18,72,75,69,89,95,76,79,67,65,76,95,77, - 65,67,72,73,78,69,41,2,218,3,99,108,115,114,26,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,218,14,95,111,112,101,110,95,114,101,103,105,115,116,114, - 121,8,3,0,0,115,8,0,0,0,0,2,2,1,16,1, - 12,1,122,36,87,105,110,100,111,119,115,82,101,103,105,115, - 116,114,121,70,105,110,100,101,114,46,95,111,112,101,110,95, - 114,101,103,105,115,116,114,121,99,2,0,0,0,0,0,0, - 0,0,0,0,0,6,0,0,0,8,0,0,0,67,0,0, - 0,115,132,0,0,0,124,0,106,0,114,14,124,0,106,1, - 125,2,110,6,124,0,106,2,125,2,124,2,106,3,124,1, - 100,1,116,4,106,5,100,0,100,2,133,2,25,0,22,0, - 100,3,141,2,125,3,122,58,124,0,160,6,124,3,161,1, - 143,28,125,4,116,7,160,8,124,4,100,4,161,2,125,5, - 87,0,100,0,4,0,4,0,131,3,1,0,110,16,49,0, - 115,94,48,0,1,0,1,0,1,0,89,0,1,0,87,0, - 110,20,4,0,116,9,121,126,1,0,1,0,1,0,89,0, - 100,0,83,0,48,0,124,5,83,0,41,5,78,122,5,37, - 100,46,37,100,114,45,0,0,0,41,2,114,163,0,0,0, - 90,11,115,121,115,95,118,101,114,115,105,111,110,114,14,0, - 0,0,41,10,218,11,68,69,66,85,71,95,66,85,73,76, - 68,218,18,82,69,71,73,83,84,82,89,95,75,69,89,95, - 68,69,66,85,71,218,12,82,69,71,73,83,84,82,89,95, - 75,69,89,114,88,0,0,0,114,21,0,0,0,218,12,118, - 101,114,115,105,111,110,95,105,110,102,111,114,217,0,0,0, - 114,215,0,0,0,90,10,81,117,101,114,121,86,97,108,117, - 101,114,76,0,0,0,41,6,114,216,0,0,0,114,163,0, - 0,0,90,12,114,101,103,105,115,116,114,121,95,107,101,121, - 114,26,0,0,0,90,4,104,107,101,121,218,8,102,105,108, - 101,112,97,116,104,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,16,95,115,101,97,114,99,104,95,114,101, - 103,105,115,116,114,121,15,3,0,0,115,24,0,0,0,0, - 2,6,1,8,2,6,1,6,1,16,255,6,2,2,1,12, - 1,46,1,12,1,8,1,122,38,87,105,110,100,111,119,115, - 82,101,103,105,115,116,114,121,70,105,110,100,101,114,46,95, - 115,101,97,114,99,104,95,114,101,103,105,115,116,114,121,78, - 99,4,0,0,0,0,0,0,0,0,0,0,0,8,0,0, - 0,8,0,0,0,67,0,0,0,115,120,0,0,0,124,0, - 160,0,124,1,161,1,125,4,124,4,100,0,117,0,114,22, - 100,0,83,0,122,12,116,1,124,4,131,1,1,0,87,0, - 110,20,4,0,116,2,121,54,1,0,1,0,1,0,89,0, - 100,0,83,0,48,0,116,3,131,0,68,0,93,52,92,2, - 125,5,125,6,124,4,160,4,116,5,124,6,131,1,161,1, - 114,62,116,6,106,7,124,1,124,5,124,1,124,4,131,2, - 124,4,100,1,141,3,125,7,124,7,2,0,1,0,83,0, - 113,62,100,0,83,0,41,2,78,114,204,0,0,0,41,8, - 114,223,0,0,0,114,75,0,0,0,114,76,0,0,0,114, - 208,0,0,0,114,58,0,0,0,114,135,0,0,0,114,158, - 0,0,0,218,16,115,112,101,99,95,102,114,111,109,95,108, - 111,97,100,101,114,41,8,114,216,0,0,0,114,163,0,0, - 0,114,65,0,0,0,218,6,116,97,114,103,101,116,114,222, - 0,0,0,114,164,0,0,0,114,212,0,0,0,114,210,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,218,9,102,105,110,100,95,115,112,101,99,30,3,0,0, - 115,28,0,0,0,0,2,10,1,8,1,4,1,2,1,12, - 1,12,1,8,1,14,1,14,1,6,1,8,1,2,254,6, - 3,122,31,87,105,110,100,111,119,115,82,101,103,105,115,116, - 114,121,70,105,110,100,101,114,46,102,105,110,100,95,115,112, - 101,99,99,3,0,0,0,0,0,0,0,0,0,0,0,4, - 0,0,0,4,0,0,0,67,0,0,0,115,34,0,0,0, - 124,0,160,0,124,1,124,2,161,2,125,3,124,3,100,1, - 117,1,114,26,124,3,106,1,83,0,100,1,83,0,100,1, - 83,0,41,2,122,108,70,105,110,100,32,109,111,100,117,108, + 41,1,114,142,0,0,0,41,4,114,41,0,0,0,218,11, + 115,111,117,114,99,101,95,104,97,115,104,114,141,0,0,0, + 114,175,0,0,0,114,7,0,0,0,114,7,0,0,0,114, + 8,0,0,0,218,18,95,118,97,108,105,100,97,116,101,95, + 104,97,115,104,95,112,121,99,134,2,0,0,115,14,0,0, + 0,16,17,2,1,8,1,4,255,2,2,6,254,4,255,114, + 182,0,0,0,99,4,0,0,0,0,0,0,0,0,0,0, + 0,5,0,0,0,5,0,0,0,67,0,0,0,115,76,0, + 0,0,116,0,160,1,124,0,161,1,125,4,116,2,124,4, + 116,3,131,2,114,28,116,4,160,5,100,1,124,2,161,2, + 1,0,124,3,100,2,117,1,114,26,116,6,160,7,124,4, + 124,3,161,2,1,0,124,4,83,0,116,8,100,3,160,9, + 124,2,161,1,124,1,124,2,100,4,141,3,130,1,41,5, + 122,35,67,111,109,112,105,108,101,32,98,121,116,101,99,111, + 100,101,32,97,115,32,102,111,117,110,100,32,105,110,32,97, + 32,112,121,99,46,122,21,99,111,100,101,32,111,98,106,101, + 99,116,32,102,114,111,109,32,123,33,114,125,78,122,23,78, + 111,110,45,99,111,100,101,32,111,98,106,101,99,116,32,105, + 110,32,123,33,114,125,169,2,114,141,0,0,0,114,65,0, + 0,0,41,10,218,7,109,97,114,115,104,97,108,90,5,108, + 111,97,100,115,218,10,105,115,105,110,115,116,97,110,99,101, + 218,10,95,99,111,100,101,95,116,121,112,101,114,159,0,0, + 0,114,173,0,0,0,218,4,95,105,109,112,90,16,95,102, + 105,120,95,99,111,95,102,105,108,101,110,97,109,101,114,142, + 0,0,0,114,89,0,0,0,41,5,114,41,0,0,0,114, + 141,0,0,0,114,132,0,0,0,114,134,0,0,0,218,4, + 99,111,100,101,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,218,17,95,99,111,109,112,105,108,101,95,98,121, + 116,101,99,111,100,101,158,2,0,0,115,18,0,0,0,10, + 2,10,1,12,1,8,1,12,1,4,1,10,2,4,1,6, + 255,114,189,0,0,0,99,3,0,0,0,0,0,0,0,0, + 0,0,0,4,0,0,0,5,0,0,0,67,0,0,0,115, + 70,0,0,0,116,0,116,1,131,1,125,3,124,3,160,2, + 116,3,100,1,131,1,161,1,1,0,124,3,160,2,116,3, + 124,1,131,1,161,1,1,0,124,3,160,2,116,3,124,2, + 131,1,161,1,1,0,124,3,160,2,116,4,160,5,124,0, + 161,1,161,1,1,0,124,3,83,0,41,2,122,43,80,114, + 111,100,117,99,101,32,116,104,101,32,100,97,116,97,32,102, + 111,114,32,97,32,116,105,109,101,115,116,97,109,112,45,98, + 97,115,101,100,32,112,121,99,46,114,0,0,0,0,41,6, + 218,9,98,121,116,101,97,114,114,97,121,114,172,0,0,0, + 218,6,101,120,116,101,110,100,114,36,0,0,0,114,184,0, + 0,0,218,5,100,117,109,112,115,41,4,114,188,0,0,0, + 218,5,109,116,105,109,101,114,179,0,0,0,114,41,0,0, + 0,114,7,0,0,0,114,7,0,0,0,114,8,0,0,0, + 218,22,95,99,111,100,101,95,116,111,95,116,105,109,101,115, + 116,97,109,112,95,112,121,99,171,2,0,0,115,12,0,0, + 0,8,2,14,1,14,1,14,1,16,1,4,1,114,194,0, + 0,0,84,99,3,0,0,0,0,0,0,0,0,0,0,0, + 5,0,0,0,5,0,0,0,67,0,0,0,115,80,0,0, + 0,116,0,116,1,131,1,125,3,100,1,124,2,100,1,62, + 0,66,0,125,4,124,3,160,2,116,3,124,4,131,1,161, + 1,1,0,116,4,124,1,131,1,100,2,107,2,115,25,74, + 0,130,1,124,3,160,2,124,1,161,1,1,0,124,3,160, + 2,116,5,160,6,124,0,161,1,161,1,1,0,124,3,83, + 0,41,3,122,38,80,114,111,100,117,99,101,32,116,104,101, + 32,100,97,116,97,32,102,111,114,32,97,32,104,97,115,104, + 45,98,97,115,101,100,32,112,121,99,46,114,3,0,0,0, + 114,170,0,0,0,41,7,114,190,0,0,0,114,172,0,0, + 0,114,191,0,0,0,114,36,0,0,0,114,4,0,0,0, + 114,184,0,0,0,114,192,0,0,0,41,5,114,188,0,0, + 0,114,181,0,0,0,90,7,99,104,101,99,107,101,100,114, + 41,0,0,0,114,16,0,0,0,114,7,0,0,0,114,7, + 0,0,0,114,8,0,0,0,218,17,95,99,111,100,101,95, + 116,111,95,104,97,115,104,95,112,121,99,181,2,0,0,115, + 14,0,0,0,8,2,12,1,14,1,16,1,10,1,16,1, + 4,1,114,195,0,0,0,99,1,0,0,0,0,0,0,0, + 0,0,0,0,5,0,0,0,6,0,0,0,67,0,0,0, + 115,62,0,0,0,100,1,100,2,108,0,125,1,116,1,160, + 2,124,0,161,1,106,3,125,2,124,1,160,4,124,2,161, + 1,125,3,116,1,160,5,100,2,100,3,161,2,125,4,124, + 4,160,6,124,0,160,6,124,3,100,1,25,0,161,1,161, + 1,83,0,41,4,122,121,68,101,99,111,100,101,32,98,121, + 116,101,115,32,114,101,112,114,101,115,101,110,116,105,110,103, + 32,115,111,117,114,99,101,32,99,111,100,101,32,97,110,100, + 32,114,101,116,117,114,110,32,116,104,101,32,115,116,114,105, + 110,103,46,10,10,32,32,32,32,85,110,105,118,101,114,115, + 97,108,32,110,101,119,108,105,110,101,32,115,117,112,112,111, + 114,116,32,105,115,32,117,115,101,100,32,105,110,32,116,104, + 101,32,100,101,99,111,100,105,110,103,46,10,32,32,32,32, + 114,0,0,0,0,78,84,41,7,218,8,116,111,107,101,110, + 105,122,101,114,91,0,0,0,90,7,66,121,116,101,115,73, + 79,90,8,114,101,97,100,108,105,110,101,90,15,100,101,116, + 101,99,116,95,101,110,99,111,100,105,110,103,90,25,73,110, + 99,114,101,109,101,110,116,97,108,78,101,119,108,105,110,101, + 68,101,99,111,100,101,114,218,6,100,101,99,111,100,101,41, + 5,218,12,115,111,117,114,99,101,95,98,121,116,101,115,114, + 196,0,0,0,90,21,115,111,117,114,99,101,95,98,121,116, + 101,115,95,114,101,97,100,108,105,110,101,218,8,101,110,99, + 111,100,105,110,103,90,15,110,101,119,108,105,110,101,95,100, + 101,99,111,100,101,114,114,7,0,0,0,114,7,0,0,0, + 114,8,0,0,0,218,13,100,101,99,111,100,101,95,115,111, + 117,114,99,101,192,2,0,0,115,10,0,0,0,8,5,12, + 1,10,1,12,1,20,1,114,200,0,0,0,169,2,114,164, + 0,0,0,218,26,115,117,98,109,111,100,117,108,101,95,115, + 101,97,114,99,104,95,108,111,99,97,116,105,111,110,115,99, + 2,0,0,0,0,0,0,0,2,0,0,0,9,0,0,0, + 8,0,0,0,67,0,0,0,115,54,1,0,0,124,1,100, + 1,117,0,114,29,100,2,125,1,116,0,124,2,100,3,131, + 2,114,28,122,7,124,2,160,1,124,0,161,1,125,1,87, + 0,110,38,4,0,116,2,121,27,1,0,1,0,1,0,89, + 0,110,30,119,0,110,28,116,3,160,4,124,1,161,1,125, + 1,116,5,124,1,131,1,115,57,122,9,116,6,116,3,160, + 7,161,0,124,1,131,2,125,1,87,0,110,9,4,0,116, + 8,121,56,1,0,1,0,1,0,89,0,110,1,119,0,116, + 9,106,10,124,0,124,2,124,1,100,4,141,3,125,4,100, + 5,124,4,95,11,124,2,100,1,117,0,114,99,116,12,131, + 0,68,0,93,21,92,2,125,5,125,6,124,1,160,13,116, + 14,124,6,131,1,161,1,114,96,124,5,124,0,124,1,131, + 2,125,2,124,2,124,4,95,15,1,0,110,3,113,75,100, + 1,83,0,124,3,116,16,117,0,114,131,116,0,124,2,100, + 6,131,2,114,130,122,7,124,2,160,17,124,0,161,1,125, + 7,87,0,110,9,4,0,116,2,121,124,1,0,1,0,1, + 0,89,0,110,10,119,0,124,7,114,130,103,0,124,4,95, + 18,110,3,124,3,124,4,95,18,124,4,106,18,103,0,107, + 2,114,153,124,1,114,153,116,19,124,1,131,1,100,7,25, + 0,125,8,124,4,106,18,160,20,124,8,161,1,1,0,124, + 4,83,0,41,8,97,61,1,0,0,82,101,116,117,114,110, + 32,97,32,109,111,100,117,108,101,32,115,112,101,99,32,98, + 97,115,101,100,32,111,110,32,97,32,102,105,108,101,32,108, + 111,99,97,116,105,111,110,46,10,10,32,32,32,32,84,111, + 32,105,110,100,105,99,97,116,101,32,116,104,97,116,32,116, + 104,101,32,109,111,100,117,108,101,32,105,115,32,97,32,112, + 97,99,107,97,103,101,44,32,115,101,116,10,32,32,32,32, + 115,117,98,109,111,100,117,108,101,95,115,101,97,114,99,104, + 95,108,111,99,97,116,105,111,110,115,32,116,111,32,97,32, + 108,105,115,116,32,111,102,32,100,105,114,101,99,116,111,114, + 121,32,112,97,116,104,115,46,32,32,65,110,10,32,32,32, + 32,101,109,112,116,121,32,108,105,115,116,32,105,115,32,115, + 117,102,102,105,99,105,101,110,116,44,32,116,104,111,117,103, + 104,32,105,116,115,32,110,111,116,32,111,116,104,101,114,119, + 105,115,101,32,117,115,101,102,117,108,32,116,111,32,116,104, + 101,10,32,32,32,32,105,109,112,111,114,116,32,115,121,115, + 116,101,109,46,10,10,32,32,32,32,84,104,101,32,108,111, + 97,100,101,114,32,109,117,115,116,32,116,97,107,101,32,97, + 32,115,112,101,99,32,97,115,32,105,116,115,32,111,110,108, + 121,32,95,95,105,110,105,116,95,95,40,41,32,97,114,103, + 46,10,10,32,32,32,32,78,122,9,60,117,110,107,110,111, + 119,110,62,218,12,103,101,116,95,102,105,108,101,110,97,109, + 101,169,1,218,6,111,114,105,103,105,110,84,218,10,105,115, + 95,112,97,99,107,97,103,101,114,0,0,0,0,41,21,114, + 153,0,0,0,114,203,0,0,0,114,142,0,0,0,114,18, + 0,0,0,114,103,0,0,0,114,86,0,0,0,114,67,0, + 0,0,114,82,0,0,0,114,76,0,0,0,114,159,0,0, + 0,218,10,77,111,100,117,108,101,83,112,101,99,90,13,95, + 115,101,116,95,102,105,108,101,97,116,116,114,218,27,95,103, + 101,116,95,115,117,112,112,111,114,116,101,100,95,102,105,108, + 101,95,108,111,97,100,101,114,115,114,58,0,0,0,114,136, + 0,0,0,114,164,0,0,0,218,9,95,80,79,80,85,76, + 65,84,69,114,206,0,0,0,114,202,0,0,0,114,74,0, + 0,0,114,61,0,0,0,41,9,114,141,0,0,0,90,8, + 108,111,99,97,116,105,111,110,114,164,0,0,0,114,202,0, + 0,0,218,4,115,112,101,99,218,12,108,111,97,100,101,114, + 95,99,108,97,115,115,218,8,115,117,102,102,105,120,101,115, + 114,206,0,0,0,90,7,100,105,114,110,97,109,101,114,7, + 0,0,0,114,7,0,0,0,114,8,0,0,0,218,23,115, + 112,101,99,95,102,114,111,109,95,102,105,108,101,95,108,111, + 99,97,116,105,111,110,209,2,0,0,115,84,0,0,0,8, + 12,4,4,10,1,2,2,14,1,12,1,4,1,2,255,2, + 252,10,7,8,1,2,1,18,1,12,1,4,1,2,255,16, + 9,6,1,8,3,14,1,14,1,10,1,6,1,4,1,2, + 253,4,5,8,3,10,2,2,1,14,1,12,1,4,1,2, + 255,4,3,6,1,2,128,6,2,10,1,4,1,12,1,12, + 1,4,2,114,213,0,0,0,99,0,0,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,4,0,0,0,64,0,0, + 0,115,88,0,0,0,101,0,90,1,100,0,90,2,100,1, + 90,3,100,2,90,4,100,3,90,5,101,6,111,15,100,4, + 101,7,118,0,90,8,101,9,100,5,100,6,132,0,131,1, + 90,10,101,11,100,7,100,8,132,0,131,1,90,12,101,11, + 100,14,100,10,100,11,132,1,131,1,90,13,101,11,100,15, + 100,12,100,13,132,1,131,1,90,14,100,9,83,0,41,16, + 218,21,87,105,110,100,111,119,115,82,101,103,105,115,116,114, + 121,70,105,110,100,101,114,122,62,77,101,116,97,32,112,97, + 116,104,32,102,105,110,100,101,114,32,102,111,114,32,109,111, + 100,117,108,101,115,32,100,101,99,108,97,114,101,100,32,105, + 110,32,116,104,101,32,87,105,110,100,111,119,115,32,114,101, + 103,105,115,116,114,121,46,122,59,83,111,102,116,119,97,114, + 101,92,80,121,116,104,111,110,92,80,121,116,104,111,110,67, + 111,114,101,92,123,115,121,115,95,118,101,114,115,105,111,110, + 125,92,77,111,100,117,108,101,115,92,123,102,117,108,108,110, + 97,109,101,125,122,65,83,111,102,116,119,97,114,101,92,80, + 121,116,104,111,110,92,80,121,116,104,111,110,67,111,114,101, + 92,123,115,121,115,95,118,101,114,115,105,111,110,125,92,77, + 111,100,117,108,101,115,92,123,102,117,108,108,110,97,109,101, + 125,92,68,101,98,117,103,122,6,95,100,46,112,121,100,99, + 1,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0, + 8,0,0,0,67,0,0,0,115,50,0,0,0,122,8,116, + 0,160,1,116,0,106,2,124,0,161,2,87,0,83,0,4, + 0,116,3,121,24,1,0,1,0,1,0,116,0,160,1,116, + 0,106,4,124,0,161,2,6,0,89,0,83,0,119,0,114, + 69,0,0,0,41,5,218,6,119,105,110,114,101,103,90,7, + 79,112,101,110,75,101,121,90,17,72,75,69,89,95,67,85, + 82,82,69,78,84,95,85,83,69,82,114,76,0,0,0,90, + 18,72,75,69,89,95,76,79,67,65,76,95,77,65,67,72, + 73,78,69,114,19,0,0,0,114,7,0,0,0,114,7,0, + 0,0,114,8,0,0,0,218,14,95,111,112,101,110,95,114, + 101,103,105,115,116,114,121,38,3,0,0,115,10,0,0,0, + 2,2,16,1,12,1,18,1,2,255,122,36,87,105,110,100, + 111,119,115,82,101,103,105,115,116,114,121,70,105,110,100,101, + 114,46,95,111,112,101,110,95,114,101,103,105,115,116,114,121, + 99,2,0,0,0,0,0,0,0,0,0,0,0,6,0,0, + 0,8,0,0,0,67,0,0,0,115,134,0,0,0,124,0, + 106,0,114,7,124,0,106,1,125,2,110,3,124,0,106,2, + 125,2,124,2,106,3,124,1,100,1,116,4,106,5,100,0, + 100,2,133,2,25,0,22,0,100,3,141,2,125,3,122,32, + 124,0,160,6,124,3,161,1,143,16,125,4,116,7,160,8, + 124,4,100,4,161,2,125,5,87,0,100,0,4,0,4,0, + 131,3,1,0,87,0,124,5,83,0,49,0,115,49,119,1, + 1,0,1,0,1,0,89,0,1,0,87,0,124,5,83,0, + 4,0,116,9,121,66,1,0,1,0,1,0,89,0,100,0, + 83,0,119,0,41,5,78,122,5,37,100,46,37,100,114,44, + 0,0,0,41,2,114,163,0,0,0,90,11,115,121,115,95, + 118,101,114,115,105,111,110,114,10,0,0,0,41,10,218,11, + 68,69,66,85,71,95,66,85,73,76,68,218,18,82,69,71, + 73,83,84,82,89,95,75,69,89,95,68,69,66,85,71,218, + 12,82,69,71,73,83,84,82,89,95,75,69,89,114,89,0, + 0,0,114,15,0,0,0,218,12,118,101,114,115,105,111,110, + 95,105,110,102,111,114,216,0,0,0,114,215,0,0,0,90, + 10,81,117,101,114,121,86,97,108,117,101,114,76,0,0,0, + 41,6,218,3,99,108,115,114,163,0,0,0,90,12,114,101, + 103,105,115,116,114,121,95,107,101,121,114,20,0,0,0,90, + 4,104,107,101,121,218,8,102,105,108,101,112,97,116,104,114, + 7,0,0,0,114,7,0,0,0,114,8,0,0,0,218,16, + 95,115,101,97,114,99,104,95,114,101,103,105,115,116,114,121, + 45,3,0,0,115,32,0,0,0,6,2,8,1,6,2,6, + 1,16,1,6,255,2,2,12,1,14,1,12,255,4,4,18, + 252,4,4,12,254,6,1,2,255,122,38,87,105,110,100,111, + 119,115,82,101,103,105,115,116,114,121,70,105,110,100,101,114, + 46,95,115,101,97,114,99,104,95,114,101,103,105,115,116,114, + 121,78,99,4,0,0,0,0,0,0,0,0,0,0,0,8, + 0,0,0,8,0,0,0,67,0,0,0,115,120,0,0,0, + 124,0,160,0,124,1,161,1,125,4,124,4,100,0,117,0, + 114,11,100,0,83,0,122,6,116,1,124,4,131,1,1,0, + 87,0,110,10,4,0,116,2,121,27,1,0,1,0,1,0, + 89,0,100,0,83,0,119,0,116,3,131,0,68,0,93,26, + 92,2,125,5,125,6,124,4,160,4,116,5,124,6,131,1, + 161,1,114,57,116,6,106,7,124,1,124,5,124,1,124,4, + 131,2,124,4,100,1,141,3,125,7,124,7,2,0,1,0, + 83,0,113,31,100,0,83,0,41,2,78,114,204,0,0,0, + 41,8,114,223,0,0,0,114,75,0,0,0,114,76,0,0, + 0,114,208,0,0,0,114,58,0,0,0,114,136,0,0,0, + 114,159,0,0,0,218,16,115,112,101,99,95,102,114,111,109, + 95,108,111,97,100,101,114,41,8,114,221,0,0,0,114,163, + 0,0,0,114,65,0,0,0,218,6,116,97,114,103,101,116, + 114,222,0,0,0,114,164,0,0,0,114,212,0,0,0,114, + 210,0,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,218,9,102,105,110,100,95,115,112,101,99,60,3, + 0,0,115,34,0,0,0,10,2,8,1,4,1,2,1,12, + 1,12,1,6,1,2,255,14,2,14,1,6,1,8,1,2, + 1,6,254,8,3,2,252,4,255,122,31,87,105,110,100,111, + 119,115,82,101,103,105,115,116,114,121,70,105,110,100,101,114, + 46,102,105,110,100,95,115,112,101,99,99,3,0,0,0,0, + 0,0,0,0,0,0,0,4,0,0,0,4,0,0,0,67, + 0,0,0,115,42,0,0,0,116,0,160,1,100,1,116,2, + 161,2,1,0,124,0,160,3,124,1,124,2,161,2,125,3, + 124,3,100,2,117,1,114,19,124,3,106,4,83,0,100,2, + 83,0,41,3,122,106,70,105,110,100,32,109,111,100,117,108, 101,32,110,97,109,101,100,32,105,110,32,116,104,101,32,114, 101,103,105,115,116,114,121,46,10,10,32,32,32,32,32,32, 32,32,84,104,105,115,32,109,101,116,104,111,100,32,105,115, 32,100,101,112,114,101,99,97,116,101,100,46,32,32,85,115, - 101,32,101,120,101,99,95,109,111,100,117,108,101,40,41,32, - 105,110,115,116,101,97,100,46,10,10,32,32,32,32,32,32, - 32,32,78,169,2,114,226,0,0,0,114,164,0,0,0,169, - 4,114,216,0,0,0,114,163,0,0,0,114,65,0,0,0, - 114,210,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,11,102,105,110,100,95,109,111,100,117,108, - 101,46,3,0,0,115,8,0,0,0,0,7,12,1,8,1, - 6,2,122,33,87,105,110,100,111,119,115,82,101,103,105,115, - 116,114,121,70,105,110,100,101,114,46,102,105,110,100,95,109, - 111,100,117,108,101,41,2,78,78,41,1,78,41,12,114,149, - 0,0,0,114,148,0,0,0,114,150,0,0,0,114,151,0, - 0,0,114,220,0,0,0,114,219,0,0,0,114,218,0,0, - 0,218,11,99,108,97,115,115,109,101,116,104,111,100,114,217, - 0,0,0,114,223,0,0,0,114,226,0,0,0,114,229,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,114,214,0,0,0,252,2,0,0,115, - 28,0,0,0,8,2,4,3,2,255,2,4,2,255,2,3, - 4,2,2,1,10,6,2,1,10,14,2,1,12,15,2,1, - 114,214,0,0,0,99,0,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,2,0,0,0,64,0,0,0,115,48, - 0,0,0,101,0,90,1,100,0,90,2,100,1,90,3,100, - 2,100,3,132,0,90,4,100,4,100,5,132,0,90,5,100, - 6,100,7,132,0,90,6,100,8,100,9,132,0,90,7,100, - 10,83,0,41,11,218,13,95,76,111,97,100,101,114,66,97, - 115,105,99,115,122,83,66,97,115,101,32,99,108,97,115,115, - 32,111,102,32,99,111,109,109,111,110,32,99,111,100,101,32, - 110,101,101,100,101,100,32,98,121,32,98,111,116,104,32,83, - 111,117,114,99,101,76,111,97,100,101,114,32,97,110,100,10, - 32,32,32,32,83,111,117,114,99,101,108,101,115,115,70,105, - 108,101,76,111,97,100,101,114,46,99,2,0,0,0,0,0, - 0,0,0,0,0,0,5,0,0,0,4,0,0,0,67,0, - 0,0,115,64,0,0,0,116,0,124,0,160,1,124,1,161, - 1,131,1,100,1,25,0,125,2,124,2,160,2,100,2,100, - 1,161,2,100,3,25,0,125,3,124,1,160,3,100,2,161, - 1,100,4,25,0,125,4,124,3,100,5,107,2,111,62,124, - 4,100,5,107,3,83,0,41,6,122,141,67,111,110,99,114, - 101,116,101,32,105,109,112,108,101,109,101,110,116,97,116,105, - 111,110,32,111,102,32,73,110,115,112,101,99,116,76,111,97, - 100,101,114,46,105,115,95,112,97,99,107,97,103,101,32,98, - 121,32,99,104,101,99,107,105,110,103,32,105,102,10,32,32, - 32,32,32,32,32,32,116,104,101,32,112,97,116,104,32,114, - 101,116,117,114,110,101,100,32,98,121,32,103,101,116,95,102, - 105,108,101,110,97,109,101,32,104,97,115,32,97,32,102,105, - 108,101,110,97,109,101,32,111,102,32,39,95,95,105,110,105, - 116,95,95,46,112,121,39,46,114,4,0,0,0,114,96,0, - 0,0,114,0,0,0,0,114,45,0,0,0,218,8,95,95, - 105,110,105,116,95,95,41,4,114,74,0,0,0,114,203,0, - 0,0,114,124,0,0,0,114,103,0,0,0,41,5,114,142, - 0,0,0,114,163,0,0,0,114,119,0,0,0,90,13,102, - 105,108,101,110,97,109,101,95,98,97,115,101,90,9,116,97, - 105,108,95,110,97,109,101,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,114,206,0,0,0,65,3,0,0,115, - 8,0,0,0,0,3,18,1,16,1,14,1,122,24,95,76, - 111,97,100,101,114,66,97,115,105,99,115,46,105,115,95,112, - 97,99,107,97,103,101,99,2,0,0,0,0,0,0,0,0, - 0,0,0,2,0,0,0,1,0,0,0,67,0,0,0,115, - 4,0,0,0,100,1,83,0,169,2,122,42,85,115,101,32, - 100,101,102,97,117,108,116,32,115,101,109,97,110,116,105,99, - 115,32,102,111,114,32,109,111,100,117,108,101,32,99,114,101, - 97,116,105,111,110,46,78,114,10,0,0,0,169,2,114,142, - 0,0,0,114,210,0,0,0,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,13,99,114,101,97,116,101,95, - 109,111,100,117,108,101,73,3,0,0,115,2,0,0,0,0, - 1,122,27,95,76,111,97,100,101,114,66,97,115,105,99,115, - 46,99,114,101,97,116,101,95,109,111,100,117,108,101,99,2, - 0,0,0,0,0,0,0,0,0,0,0,3,0,0,0,5, - 0,0,0,67,0,0,0,115,56,0,0,0,124,0,160,0, - 124,1,106,1,161,1,125,2,124,2,100,1,117,0,114,36, - 116,2,100,2,160,3,124,1,106,1,161,1,131,1,130,1, - 116,4,160,5,116,6,124,2,124,1,106,7,161,3,1,0, - 100,1,83,0,41,3,122,19,69,120,101,99,117,116,101,32, - 116,104,101,32,109,111,100,117,108,101,46,78,122,52,99,97, - 110,110,111,116,32,108,111,97,100,32,109,111,100,117,108,101, - 32,123,33,114,125,32,119,104,101,110,32,103,101,116,95,99, - 111,100,101,40,41,32,114,101,116,117,114,110,115,32,78,111, - 110,101,41,8,218,8,103,101,116,95,99,111,100,101,114,149, - 0,0,0,114,141,0,0,0,114,88,0,0,0,114,158,0, - 0,0,218,25,95,99,97,108,108,95,119,105,116,104,95,102, - 114,97,109,101,115,95,114,101,109,111,118,101,100,218,4,101, - 120,101,99,114,155,0,0,0,41,3,114,142,0,0,0,218, - 6,109,111,100,117,108,101,114,188,0,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,218,11,101,120,101, - 99,95,109,111,100,117,108,101,76,3,0,0,115,12,0,0, - 0,0,2,12,1,8,1,6,1,4,255,6,2,122,25,95, - 76,111,97,100,101,114,66,97,115,105,99,115,46,101,120,101, - 99,95,109,111,100,117,108,101,99,2,0,0,0,0,0,0, - 0,0,0,0,0,2,0,0,0,4,0,0,0,67,0,0, - 0,115,12,0,0,0,116,0,160,1,124,0,124,1,161,2, - 83,0,41,1,122,26,84,104,105,115,32,109,111,100,117,108, - 101,32,105,115,32,100,101,112,114,101,99,97,116,101,100,46, - 41,2,114,158,0,0,0,218,17,95,108,111,97,100,95,109, - 111,100,117,108,101,95,115,104,105,109,169,2,114,142,0,0, - 0,114,163,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,11,108,111,97,100,95,109,111,100,117, - 108,101,84,3,0,0,115,2,0,0,0,0,2,122,25,95, - 76,111,97,100,101,114,66,97,115,105,99,115,46,108,111,97, - 100,95,109,111,100,117,108,101,78,41,8,114,149,0,0,0, - 114,148,0,0,0,114,150,0,0,0,114,151,0,0,0,114, - 206,0,0,0,114,235,0,0,0,114,240,0,0,0,114,243, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,114,231,0,0,0,60,3,0,0, - 115,10,0,0,0,8,2,4,3,8,8,8,3,8,8,114, - 231,0,0,0,99,0,0,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,3,0,0,0,64,0,0,0,115,74,0, - 0,0,101,0,90,1,100,0,90,2,100,1,100,2,132,0, - 90,3,100,3,100,4,132,0,90,4,100,5,100,6,132,0, - 90,5,100,7,100,8,132,0,90,6,100,9,100,10,132,0, - 90,7,100,11,100,12,156,1,100,13,100,14,132,2,90,8, - 100,15,100,16,132,0,90,9,100,17,83,0,41,18,218,12, - 83,111,117,114,99,101,76,111,97,100,101,114,99,2,0,0, - 0,0,0,0,0,0,0,0,0,2,0,0,0,1,0,0, - 0,67,0,0,0,115,8,0,0,0,116,0,130,1,100,1, - 83,0,41,2,122,165,79,112,116,105,111,110,97,108,32,109, - 101,116,104,111,100,32,116,104,97,116,32,114,101,116,117,114, - 110,115,32,116,104,101,32,109,111,100,105,102,105,99,97,116, - 105,111,110,32,116,105,109,101,32,40,97,110,32,105,110,116, - 41,32,102,111,114,32,116,104,101,10,32,32,32,32,32,32, - 32,32,115,112,101,99,105,102,105,101,100,32,112,97,116,104, - 32,40,97,32,115,116,114,41,46,10,10,32,32,32,32,32, - 32,32,32,82,97,105,115,101,115,32,79,83,69,114,114,111, - 114,32,119,104,101,110,32,116,104,101,32,112,97,116,104,32, - 99,97,110,110,111,116,32,98,101,32,104,97,110,100,108,101, - 100,46,10,32,32,32,32,32,32,32,32,78,41,1,114,76, - 0,0,0,169,2,114,142,0,0,0,114,65,0,0,0,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,218,10, - 112,97,116,104,95,109,116,105,109,101,91,3,0,0,115,2, - 0,0,0,0,6,122,23,83,111,117,114,99,101,76,111,97, - 100,101,114,46,112,97,116,104,95,109,116,105,109,101,99,2, - 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,4, - 0,0,0,67,0,0,0,115,14,0,0,0,100,1,124,0, - 160,0,124,1,161,1,105,1,83,0,41,2,97,158,1,0, - 0,79,112,116,105,111,110,97,108,32,109,101,116,104,111,100, - 32,114,101,116,117,114,110,105,110,103,32,97,32,109,101,116, - 97,100,97,116,97,32,100,105,99,116,32,102,111,114,32,116, - 104,101,32,115,112,101,99,105,102,105,101,100,10,32,32,32, - 32,32,32,32,32,112,97,116,104,32,40,97,32,115,116,114, - 41,46,10,10,32,32,32,32,32,32,32,32,80,111,115,115, - 105,98,108,101,32,107,101,121,115,58,10,32,32,32,32,32, - 32,32,32,45,32,39,109,116,105,109,101,39,32,40,109,97, - 110,100,97,116,111,114,121,41,32,105,115,32,116,104,101,32, - 110,117,109,101,114,105,99,32,116,105,109,101,115,116,97,109, - 112,32,111,102,32,108,97,115,116,32,115,111,117,114,99,101, - 10,32,32,32,32,32,32,32,32,32,32,99,111,100,101,32, - 109,111,100,105,102,105,99,97,116,105,111,110,59,10,32,32, - 32,32,32,32,32,32,45,32,39,115,105,122,101,39,32,40, - 111,112,116,105,111,110,97,108,41,32,105,115,32,116,104,101, - 32,115,105,122,101,32,105,110,32,98,121,116,101,115,32,111, - 102,32,116,104,101,32,115,111,117,114,99,101,32,99,111,100, - 101,46,10,10,32,32,32,32,32,32,32,32,73,109,112,108, - 101,109,101,110,116,105,110,103,32,116,104,105,115,32,109,101, - 116,104,111,100,32,97,108,108,111,119,115,32,116,104,101,32, - 108,111,97,100,101,114,32,116,111,32,114,101,97,100,32,98, - 121,116,101,99,111,100,101,32,102,105,108,101,115,46,10,32, - 32,32,32,32,32,32,32,82,97,105,115,101,115,32,79,83, - 69,114,114,111,114,32,119,104,101,110,32,116,104,101,32,112, - 97,116,104,32,99,97,110,110,111,116,32,98,101,32,104,97, - 110,100,108,101,100,46,10,32,32,32,32,32,32,32,32,114, - 193,0,0,0,41,1,114,246,0,0,0,114,245,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,218, - 10,112,97,116,104,95,115,116,97,116,115,99,3,0,0,115, - 2,0,0,0,0,12,122,23,83,111,117,114,99,101,76,111, - 97,100,101,114,46,112,97,116,104,95,115,116,97,116,115,99, - 4,0,0,0,0,0,0,0,0,0,0,0,4,0,0,0, - 4,0,0,0,67,0,0,0,115,12,0,0,0,124,0,160, - 0,124,2,124,3,161,2,83,0,41,1,122,228,79,112,116, - 105,111,110,97,108,32,109,101,116,104,111,100,32,119,104,105, - 99,104,32,119,114,105,116,101,115,32,100,97,116,97,32,40, - 98,121,116,101,115,41,32,116,111,32,97,32,102,105,108,101, - 32,112,97,116,104,32,40,97,32,115,116,114,41,46,10,10, - 32,32,32,32,32,32,32,32,73,109,112,108,101,109,101,110, - 116,105,110,103,32,116,104,105,115,32,109,101,116,104,111,100, - 32,97,108,108,111,119,115,32,102,111,114,32,116,104,101,32, - 119,114,105,116,105,110,103,32,111,102,32,98,121,116,101,99, - 111,100,101,32,102,105,108,101,115,46,10,10,32,32,32,32, - 32,32,32,32,84,104,101,32,115,111,117,114,99,101,32,112, - 97,116,104,32,105,115,32,110,101,101,100,101,100,32,105,110, - 32,111,114,100,101,114,32,116,111,32,99,111,114,114,101,99, - 116,108,121,32,116,114,97,110,115,102,101,114,32,112,101,114, - 109,105,115,115,105,111,110,115,10,32,32,32,32,32,32,32, - 32,41,1,218,8,115,101,116,95,100,97,116,97,41,4,114, - 142,0,0,0,114,133,0,0,0,90,10,99,97,99,104,101, - 95,112,97,116,104,114,43,0,0,0,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,218,15,95,99,97,99,104, - 101,95,98,121,116,101,99,111,100,101,113,3,0,0,115,2, - 0,0,0,0,8,122,28,83,111,117,114,99,101,76,111,97, - 100,101,114,46,95,99,97,99,104,101,95,98,121,116,101,99, - 111,100,101,99,3,0,0,0,0,0,0,0,0,0,0,0, - 3,0,0,0,1,0,0,0,67,0,0,0,115,4,0,0, - 0,100,1,83,0,41,2,122,150,79,112,116,105,111,110,97, - 108,32,109,101,116,104,111,100,32,119,104,105,99,104,32,119, - 114,105,116,101,115,32,100,97,116,97,32,40,98,121,116,101, - 115,41,32,116,111,32,97,32,102,105,108,101,32,112,97,116, - 104,32,40,97,32,115,116,114,41,46,10,10,32,32,32,32, - 32,32,32,32,73,109,112,108,101,109,101,110,116,105,110,103, - 32,116,104,105,115,32,109,101,116,104,111,100,32,97,108,108, - 111,119,115,32,102,111,114,32,116,104,101,32,119,114,105,116, - 105,110,103,32,111,102,32,98,121,116,101,99,111,100,101,32, - 102,105,108,101,115,46,10,32,32,32,32,32,32,32,32,78, - 114,10,0,0,0,41,3,114,142,0,0,0,114,65,0,0, - 0,114,43,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,248,0,0,0,123,3,0,0,115,2, - 0,0,0,0,1,122,21,83,111,117,114,99,101,76,111,97, - 100,101,114,46,115,101,116,95,100,97,116,97,99,2,0,0, - 0,0,0,0,0,0,0,0,0,5,0,0,0,10,0,0, - 0,67,0,0,0,115,84,0,0,0,124,0,160,0,124,1, - 161,1,125,2,122,14,124,0,160,1,124,2,161,1,125,3, - 87,0,110,50,4,0,116,2,121,74,1,0,125,4,1,0, - 122,26,116,3,100,1,124,1,100,2,141,2,124,4,130,2, - 87,0,89,0,100,3,125,4,126,4,110,10,100,3,125,4, - 126,4,48,0,48,0,116,4,124,3,131,1,83,0,41,4, - 122,52,67,111,110,99,114,101,116,101,32,105,109,112,108,101, - 109,101,110,116,97,116,105,111,110,32,111,102,32,73,110,115, - 112,101,99,116,76,111,97,100,101,114,46,103,101,116,95,115, - 111,117,114,99,101,46,122,39,115,111,117,114,99,101,32,110, - 111,116,32,97,118,97,105,108,97,98,108,101,32,116,104,114, - 111,117,103,104,32,103,101,116,95,100,97,116,97,40,41,114, - 139,0,0,0,78,41,5,114,203,0,0,0,218,8,103,101, - 116,95,100,97,116,97,114,76,0,0,0,114,141,0,0,0, - 114,200,0,0,0,41,5,114,142,0,0,0,114,163,0,0, - 0,114,65,0,0,0,114,198,0,0,0,218,3,101,120,99, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,218, - 10,103,101,116,95,115,111,117,114,99,101,130,3,0,0,115, - 20,0,0,0,0,2,10,1,2,1,14,1,14,1,4,1, - 2,255,4,1,2,255,24,2,122,23,83,111,117,114,99,101, - 76,111,97,100,101,114,46,103,101,116,95,115,111,117,114,99, - 101,114,129,0,0,0,41,1,218,9,95,111,112,116,105,109, - 105,122,101,99,3,0,0,0,0,0,0,0,1,0,0,0, - 4,0,0,0,8,0,0,0,67,0,0,0,115,22,0,0, - 0,116,0,106,1,116,2,124,1,124,2,100,1,100,2,124, - 3,100,3,141,6,83,0,41,4,122,130,82,101,116,117,114, - 110,32,116,104,101,32,99,111,100,101,32,111,98,106,101,99, - 116,32,99,111,109,112,105,108,101,100,32,102,114,111,109,32, - 115,111,117,114,99,101,46,10,10,32,32,32,32,32,32,32, - 32,84,104,101,32,39,100,97,116,97,39,32,97,114,103,117, - 109,101,110,116,32,99,97,110,32,98,101,32,97,110,121,32, - 111,98,106,101,99,116,32,116,121,112,101,32,116,104,97,116, - 32,99,111,109,112,105,108,101,40,41,32,115,117,112,112,111, - 114,116,115,46,10,32,32,32,32,32,32,32,32,114,238,0, - 0,0,84,41,2,218,12,100,111,110,116,95,105,110,104,101, - 114,105,116,114,107,0,0,0,41,3,114,158,0,0,0,114, - 237,0,0,0,218,7,99,111,109,112,105,108,101,41,4,114, - 142,0,0,0,114,43,0,0,0,114,65,0,0,0,114,253, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,218,14,115,111,117,114,99,101,95,116,111,95,99,111, - 100,101,140,3,0,0,115,6,0,0,0,0,5,12,1,4, - 255,122,27,83,111,117,114,99,101,76,111,97,100,101,114,46, - 115,111,117,114,99,101,95,116,111,95,99,111,100,101,99,2, - 0,0,0,0,0,0,0,0,0,0,0,15,0,0,0,9, - 0,0,0,67,0,0,0,115,24,2,0,0,124,0,160,0, - 124,1,161,1,125,2,100,1,125,3,100,1,125,4,100,1, - 125,5,100,2,125,6,100,3,125,7,122,12,116,1,124,2, - 131,1,125,8,87,0,110,24,4,0,116,2,121,66,1,0, - 1,0,1,0,100,1,125,8,89,0,144,1,110,42,48,0, - 122,14,124,0,160,3,124,2,161,1,125,9,87,0,110,20, - 4,0,116,4,121,102,1,0,1,0,1,0,89,0,144,1, - 110,6,48,0,116,5,124,9,100,4,25,0,131,1,125,3, - 122,14,124,0,160,6,124,8,161,1,125,10,87,0,110,18, - 4,0,116,4,121,148,1,0,1,0,1,0,89,0,110,216, - 48,0,124,1,124,8,100,5,156,2,125,11,122,148,116,7, - 124,10,124,1,124,11,131,3,125,12,116,8,124,10,131,1, - 100,6,100,1,133,2,25,0,125,13,124,12,100,7,64,0, - 100,8,107,3,125,6,124,6,144,1,114,30,124,12,100,9, - 64,0,100,8,107,3,125,7,116,9,106,10,100,10,107,3, - 144,1,114,50,124,7,115,248,116,9,106,10,100,11,107,2, - 144,1,114,50,124,0,160,6,124,2,161,1,125,4,116,9, - 160,11,116,12,124,4,161,2,125,5,116,13,124,10,124,5, - 124,1,124,11,131,4,1,0,110,20,116,14,124,10,124,3, - 124,9,100,12,25,0,124,1,124,11,131,5,1,0,87,0, - 110,24,4,0,116,15,116,16,102,2,144,1,121,76,1,0, - 1,0,1,0,89,0,110,32,48,0,116,17,160,18,100,13, - 124,8,124,2,161,3,1,0,116,19,124,13,124,1,124,8, - 124,2,100,14,141,4,83,0,124,4,100,1,117,0,144,1, - 114,128,124,0,160,6,124,2,161,1,125,4,124,0,160,20, - 124,4,124,2,161,2,125,14,116,17,160,18,100,15,124,2, - 161,2,1,0,116,21,106,22,144,2,115,20,124,8,100,1, - 117,1,144,2,114,20,124,3,100,1,117,1,144,2,114,20, - 124,6,144,1,114,220,124,5,100,1,117,0,144,1,114,206, - 116,9,160,11,124,4,161,1,125,5,116,23,124,14,124,5, - 124,7,131,3,125,10,110,16,116,24,124,14,124,3,116,25, - 124,4,131,1,131,3,125,10,122,18,124,0,160,26,124,2, - 124,8,124,10,161,3,1,0,87,0,110,20,4,0,116,2, - 144,2,121,18,1,0,1,0,1,0,89,0,110,2,48,0, - 124,14,83,0,41,16,122,190,67,111,110,99,114,101,116,101, - 32,105,109,112,108,101,109,101,110,116,97,116,105,111,110,32, - 111,102,32,73,110,115,112,101,99,116,76,111,97,100,101,114, - 46,103,101,116,95,99,111,100,101,46,10,10,32,32,32,32, - 32,32,32,32,82,101,97,100,105,110,103,32,111,102,32,98, - 121,116,101,99,111,100,101,32,114,101,113,117,105,114,101,115, - 32,112,97,116,104,95,115,116,97,116,115,32,116,111,32,98, - 101,32,105,109,112,108,101,109,101,110,116,101,100,46,32,84, - 111,32,119,114,105,116,101,10,32,32,32,32,32,32,32,32, - 98,121,116,101,99,111,100,101,44,32,115,101,116,95,100,97, - 116,97,32,109,117,115,116,32,97,108,115,111,32,98,101,32, - 105,109,112,108,101,109,101,110,116,101,100,46,10,10,32,32, - 32,32,32,32,32,32,78,70,84,114,193,0,0,0,114,183, - 0,0,0,114,169,0,0,0,114,4,0,0,0,114,0,0, - 0,0,114,45,0,0,0,90,5,110,101,118,101,114,90,6, - 97,108,119,97,121,115,218,4,115,105,122,101,122,13,123,125, - 32,109,97,116,99,104,101,115,32,123,125,41,3,114,140,0, - 0,0,114,131,0,0,0,114,133,0,0,0,122,19,99,111, - 100,101,32,111,98,106,101,99,116,32,102,114,111,109,32,123, - 125,41,27,114,203,0,0,0,114,120,0,0,0,114,106,0, - 0,0,114,247,0,0,0,114,76,0,0,0,114,36,0,0, - 0,114,250,0,0,0,114,176,0,0,0,218,10,109,101,109, - 111,114,121,118,105,101,119,114,187,0,0,0,90,21,99,104, - 101,99,107,95,104,97,115,104,95,98,97,115,101,100,95,112, - 121,99,115,114,181,0,0,0,218,17,95,82,65,87,95,77, - 65,71,73,67,95,78,85,77,66,69,82,114,182,0,0,0, - 114,180,0,0,0,114,141,0,0,0,114,174,0,0,0,114, - 158,0,0,0,114,173,0,0,0,114,189,0,0,0,114,0, - 1,0,0,114,21,0,0,0,218,19,100,111,110,116,95,119, - 114,105,116,101,95,98,121,116,101,99,111,100,101,114,195,0, - 0,0,114,194,0,0,0,114,6,0,0,0,114,249,0,0, - 0,41,15,114,142,0,0,0,114,163,0,0,0,114,133,0, - 0,0,114,178,0,0,0,114,198,0,0,0,114,181,0,0, - 0,90,10,104,97,115,104,95,98,97,115,101,100,90,12,99, - 104,101,99,107,95,115,111,117,114,99,101,114,131,0,0,0, - 218,2,115,116,114,43,0,0,0,114,175,0,0,0,114,22, - 0,0,0,90,10,98,121,116,101,115,95,100,97,116,97,90, - 11,99,111,100,101,95,111,98,106,101,99,116,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,114,236,0,0,0, - 148,3,0,0,115,152,0,0,0,0,7,10,1,4,1,4, - 1,4,1,4,1,4,1,2,1,12,1,12,1,12,2,2, - 1,14,1,12,1,8,2,12,1,2,1,14,1,12,1,6, - 3,2,1,2,254,6,4,2,1,12,1,16,1,12,1,6, - 1,12,1,12,1,2,255,2,2,8,254,4,3,10,1,4, - 1,2,1,2,254,4,4,8,1,2,255,6,3,2,1,2, - 1,2,1,6,1,2,1,2,251,8,7,18,1,6,2,8, - 1,2,255,4,2,6,1,2,1,2,254,6,3,10,1,10, - 1,12,1,12,1,18,1,6,255,4,2,6,1,10,1,10, - 1,14,2,6,1,6,255,4,2,2,1,18,1,14,1,6, - 1,122,21,83,111,117,114,99,101,76,111,97,100,101,114,46, - 103,101,116,95,99,111,100,101,78,41,10,114,149,0,0,0, - 114,148,0,0,0,114,150,0,0,0,114,246,0,0,0,114, - 247,0,0,0,114,249,0,0,0,114,248,0,0,0,114,252, - 0,0,0,114,0,1,0,0,114,236,0,0,0,114,10,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,114,244,0,0,0,89,3,0,0,115,14,0,0,0,8, - 2,8,8,8,14,8,10,8,7,8,10,14,8,114,244,0, - 0,0,99,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,0,4,0,0,0,0,0,0,0,115,124,0,0,0, - 101,0,90,1,100,0,90,2,100,1,90,3,100,2,100,3, - 132,0,90,4,100,4,100,5,132,0,90,5,100,6,100,7, - 132,0,90,6,101,7,135,0,102,1,100,8,100,9,132,8, - 131,1,90,8,101,7,100,10,100,11,132,0,131,1,90,9, - 100,12,100,13,132,0,90,10,101,7,100,14,100,15,132,0, - 131,1,90,11,100,16,100,17,132,0,90,12,100,18,100,19, - 132,0,90,13,100,20,100,21,132,0,90,14,100,22,100,23, - 132,0,90,15,135,0,4,0,90,16,83,0,41,24,218,10, - 70,105,108,101,76,111,97,100,101,114,122,103,66,97,115,101, - 32,102,105,108,101,32,108,111,97,100,101,114,32,99,108,97, - 115,115,32,119,104,105,99,104,32,105,109,112,108,101,109,101, - 110,116,115,32,116,104,101,32,108,111,97,100,101,114,32,112, - 114,111,116,111,99,111,108,32,109,101,116,104,111,100,115,32, - 116,104,97,116,10,32,32,32,32,114,101,113,117,105,114,101, - 32,102,105,108,101,32,115,121,115,116,101,109,32,117,115,97, - 103,101,46,99,3,0,0,0,0,0,0,0,0,0,0,0, - 3,0,0,0,2,0,0,0,67,0,0,0,115,16,0,0, - 0,124,1,124,0,95,0,124,2,124,0,95,1,100,1,83, - 0,41,2,122,75,67,97,99,104,101,32,116,104,101,32,109, - 111,100,117,108,101,32,110,97,109,101,32,97,110,100,32,116, - 104,101,32,112,97,116,104,32,116,111,32,116,104,101,32,102, - 105,108,101,32,102,111,117,110,100,32,98,121,32,116,104,101, - 10,32,32,32,32,32,32,32,32,102,105,110,100,101,114,46, - 78,114,183,0,0,0,41,3,114,142,0,0,0,114,163,0, - 0,0,114,65,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,114,232,0,0,0,238,3,0,0,115, - 4,0,0,0,0,3,6,1,122,19,70,105,108,101,76,111, - 97,100,101,114,46,95,95,105,110,105,116,95,95,99,2,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,2,0, - 0,0,67,0,0,0,115,24,0,0,0,124,0,106,0,124, - 1,106,0,107,2,111,22,124,0,106,1,124,1,106,1,107, - 2,83,0,114,69,0,0,0,169,2,218,9,95,95,99,108, - 97,115,115,95,95,114,155,0,0,0,169,2,114,142,0,0, - 0,90,5,111,116,104,101,114,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,218,6,95,95,101,113,95,95,244, - 3,0,0,115,6,0,0,0,0,1,12,1,10,255,122,17, - 70,105,108,101,76,111,97,100,101,114,46,95,95,101,113,95, - 95,99,1,0,0,0,0,0,0,0,0,0,0,0,1,0, - 0,0,3,0,0,0,67,0,0,0,115,20,0,0,0,116, - 0,124,0,106,1,131,1,116,0,124,0,106,2,131,1,65, - 0,83,0,114,69,0,0,0,169,3,218,4,104,97,115,104, - 114,140,0,0,0,114,65,0,0,0,169,1,114,142,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,11,0,0,0, - 218,8,95,95,104,97,115,104,95,95,248,3,0,0,115,2, - 0,0,0,0,1,122,19,70,105,108,101,76,111,97,100,101, - 114,46,95,95,104,97,115,104,95,95,99,2,0,0,0,0, - 0,0,0,0,0,0,0,2,0,0,0,3,0,0,0,3, - 0,0,0,115,16,0,0,0,116,0,116,1,124,0,131,2, - 160,2,124,1,161,1,83,0,41,1,122,100,76,111,97,100, - 32,97,32,109,111,100,117,108,101,32,102,114,111,109,32,97, - 32,102,105,108,101,46,10,10,32,32,32,32,32,32,32,32, - 84,104,105,115,32,109,101,116,104,111,100,32,105,115,32,100, - 101,112,114,101,99,97,116,101,100,46,32,32,85,115,101,32, - 101,120,101,99,95,109,111,100,117,108,101,40,41,32,105,110, + 101,32,102,105,110,100,95,115,112,101,99,40,41,32,105,110, 115,116,101,97,100,46,10,10,32,32,32,32,32,32,32,32, - 41,3,218,5,115,117,112,101,114,114,6,1,0,0,114,243, - 0,0,0,114,242,0,0,0,169,1,114,8,1,0,0,114, - 10,0,0,0,114,11,0,0,0,114,243,0,0,0,251,3, - 0,0,115,2,0,0,0,0,10,122,22,70,105,108,101,76, - 111,97,100,101,114,46,108,111,97,100,95,109,111,100,117,108, - 101,99,2,0,0,0,0,0,0,0,0,0,0,0,2,0, - 0,0,1,0,0,0,67,0,0,0,115,6,0,0,0,124, - 0,106,0,83,0,169,1,122,58,82,101,116,117,114,110,32, - 116,104,101,32,112,97,116,104,32,116,111,32,116,104,101,32, - 115,111,117,114,99,101,32,102,105,108,101,32,97,115,32,102, - 111,117,110,100,32,98,121,32,116,104,101,32,102,105,110,100, - 101,114,46,114,71,0,0,0,114,242,0,0,0,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,114,203,0,0, - 0,7,4,0,0,115,2,0,0,0,0,3,122,23,70,105, - 108,101,76,111,97,100,101,114,46,103,101,116,95,102,105,108, - 101,110,97,109,101,99,2,0,0,0,0,0,0,0,0,0, - 0,0,3,0,0,0,8,0,0,0,67,0,0,0,115,126, - 0,0,0,116,0,124,0,116,1,116,2,102,2,131,2,114, - 70,116,3,160,4,116,5,124,1,131,1,161,1,143,24,125, - 2,124,2,160,6,161,0,87,0,2,0,100,1,4,0,4, - 0,131,3,1,0,83,0,49,0,115,58,48,0,1,0,1, - 0,1,0,89,0,1,0,110,52,116,3,160,7,124,1,100, - 2,161,2,143,24,125,2,124,2,160,6,161,0,87,0,2, - 0,100,1,4,0,4,0,131,3,1,0,83,0,49,0,115, - 112,48,0,1,0,1,0,1,0,89,0,1,0,100,1,83, - 0,41,3,122,39,82,101,116,117,114,110,32,116,104,101,32, - 100,97,116,97,32,102,114,111,109,32,112,97,116,104,32,97, - 115,32,114,97,119,32,98,121,116,101,115,46,78,218,1,114, - 41,8,114,185,0,0,0,114,244,0,0,0,218,19,69,120, - 116,101,110,115,105,111,110,70,105,108,101,76,111,97,100,101, - 114,114,90,0,0,0,90,9,111,112,101,110,95,99,111,100, - 101,114,108,0,0,0,90,4,114,101,97,100,114,91,0,0, - 0,41,3,114,142,0,0,0,114,65,0,0,0,114,93,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,114,250,0,0,0,12,4,0,0,115,10,0,0,0,0, - 2,14,1,16,1,40,2,14,1,122,19,70,105,108,101,76, - 111,97,100,101,114,46,103,101,116,95,100,97,116,97,99,2, - 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,3, - 0,0,0,67,0,0,0,115,18,0,0,0,124,0,160,0, - 124,1,161,1,114,14,124,0,83,0,100,0,83,0,114,69, - 0,0,0,41,1,114,206,0,0,0,169,2,114,142,0,0, - 0,114,239,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,19,103,101,116,95,114,101,115,111,117, - 114,99,101,95,114,101,97,100,101,114,23,4,0,0,115,6, - 0,0,0,0,2,10,1,4,1,122,30,70,105,108,101,76, - 111,97,100,101,114,46,103,101,116,95,114,101,115,111,117,114, - 99,101,95,114,101,97,100,101,114,99,2,0,0,0,0,0, - 0,0,0,0,0,0,3,0,0,0,4,0,0,0,67,0, - 0,0,115,32,0,0,0,116,0,116,1,124,0,106,2,131, - 1,100,1,25,0,124,1,131,2,125,2,116,3,160,4,124, - 2,100,2,161,2,83,0,41,3,78,114,0,0,0,0,114, - 18,1,0,0,41,5,114,67,0,0,0,114,74,0,0,0, - 114,65,0,0,0,114,90,0,0,0,114,91,0,0,0,169, - 3,114,142,0,0,0,90,8,114,101,115,111,117,114,99,101, - 114,65,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,13,111,112,101,110,95,114,101,115,111,117, - 114,99,101,29,4,0,0,115,4,0,0,0,0,1,20,1, - 122,24,70,105,108,101,76,111,97,100,101,114,46,111,112,101, - 110,95,114,101,115,111,117,114,99,101,99,2,0,0,0,0, - 0,0,0,0,0,0,0,3,0,0,0,3,0,0,0,67, - 0,0,0,115,38,0,0,0,124,0,160,0,124,1,161,1, - 115,14,116,1,130,1,116,2,116,3,124,0,106,4,131,1, - 100,1,25,0,124,1,131,2,125,2,124,2,83,0,169,2, - 78,114,0,0,0,0,41,5,218,11,105,115,95,114,101,115, - 111,117,114,99,101,218,17,70,105,108,101,78,111,116,70,111, - 117,110,100,69,114,114,111,114,114,67,0,0,0,114,74,0, - 0,0,114,65,0,0,0,114,22,1,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,218,13,114,101,115, - 111,117,114,99,101,95,112,97,116,104,33,4,0,0,115,8, - 0,0,0,0,1,10,1,4,1,20,1,122,24,70,105,108, - 101,76,111,97,100,101,114,46,114,101,115,111,117,114,99,101, - 95,112,97,116,104,99,2,0,0,0,0,0,0,0,0,0, - 0,0,3,0,0,0,3,0,0,0,67,0,0,0,115,40, - 0,0,0,116,0,124,1,118,0,114,12,100,1,83,0,116, - 1,116,2,124,0,106,3,131,1,100,2,25,0,124,1,131, - 2,125,2,116,4,124,2,131,1,83,0,41,3,78,70,114, - 0,0,0,0,41,5,114,59,0,0,0,114,67,0,0,0, - 114,74,0,0,0,114,65,0,0,0,114,80,0,0,0,169, - 3,114,142,0,0,0,114,140,0,0,0,114,65,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,114, - 25,1,0,0,39,4,0,0,115,8,0,0,0,0,1,8, - 1,4,1,20,1,122,22,70,105,108,101,76,111,97,100,101, - 114,46,105,115,95,114,101,115,111,117,114,99,101,99,1,0, - 0,0,0,0,0,0,0,0,0,0,1,0,0,0,5,0, - 0,0,67,0,0,0,115,24,0,0,0,116,0,116,1,160, - 2,116,3,124,0,106,4,131,1,100,1,25,0,161,1,131, - 1,83,0,114,24,1,0,0,41,5,218,4,105,116,101,114, - 114,24,0,0,0,218,7,108,105,115,116,100,105,114,114,74, - 0,0,0,114,65,0,0,0,114,13,1,0,0,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,218,8,99,111, - 110,116,101,110,116,115,45,4,0,0,115,2,0,0,0,0, - 1,122,19,70,105,108,101,76,111,97,100,101,114,46,99,111, - 110,116,101,110,116,115,41,17,114,149,0,0,0,114,148,0, - 0,0,114,150,0,0,0,114,151,0,0,0,114,232,0,0, - 0,114,10,1,0,0,114,14,1,0,0,114,160,0,0,0, - 114,243,0,0,0,114,203,0,0,0,114,250,0,0,0,114, - 21,1,0,0,114,23,1,0,0,114,27,1,0,0,114,25, - 1,0,0,114,31,1,0,0,90,13,95,95,99,108,97,115, - 115,99,101,108,108,95,95,114,10,0,0,0,114,10,0,0, - 0,114,16,1,0,0,114,11,0,0,0,114,6,1,0,0, - 233,3,0,0,115,30,0,0,0,8,2,4,3,8,6,8, - 4,8,3,2,1,14,11,2,1,10,4,8,11,2,1,10, - 5,8,4,8,6,8,6,114,6,1,0,0,99,0,0,0, - 0,0,0,0,0,0,0,0,0,0,0,0,0,3,0,0, - 0,64,0,0,0,115,46,0,0,0,101,0,90,1,100,0, - 90,2,100,1,90,3,100,2,100,3,132,0,90,4,100,4, - 100,5,132,0,90,5,100,6,100,7,156,1,100,8,100,9, - 132,2,90,6,100,10,83,0,41,11,218,16,83,111,117,114, - 99,101,70,105,108,101,76,111,97,100,101,114,122,62,67,111, - 110,99,114,101,116,101,32,105,109,112,108,101,109,101,110,116, - 97,116,105,111,110,32,111,102,32,83,111,117,114,99,101,76, - 111,97,100,101,114,32,117,115,105,110,103,32,116,104,101,32, - 102,105,108,101,32,115,121,115,116,101,109,46,99,2,0,0, - 0,0,0,0,0,0,0,0,0,3,0,0,0,3,0,0, - 0,67,0,0,0,115,22,0,0,0,116,0,124,1,131,1, - 125,2,124,2,106,1,124,2,106,2,100,1,156,2,83,0, - 41,2,122,33,82,101,116,117,114,110,32,116,104,101,32,109, - 101,116,97,100,97,116,97,32,102,111,114,32,116,104,101,32, - 112,97,116,104,46,41,2,114,193,0,0,0,114,1,1,0, - 0,41,3,114,75,0,0,0,218,8,115,116,95,109,116,105, - 109,101,90,7,115,116,95,115,105,122,101,41,3,114,142,0, - 0,0,114,65,0,0,0,114,5,1,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,114,247,0,0,0, - 53,4,0,0,115,4,0,0,0,0,2,8,1,122,27,83, - 111,117,114,99,101,70,105,108,101,76,111,97,100,101,114,46, - 112,97,116,104,95,115,116,97,116,115,99,4,0,0,0,0, - 0,0,0,0,0,0,0,5,0,0,0,5,0,0,0,67, - 0,0,0,115,24,0,0,0,116,0,124,1,131,1,125,4, - 124,0,106,1,124,2,124,3,124,4,100,1,141,3,83,0, - 41,2,78,169,1,218,5,95,109,111,100,101,41,2,114,138, - 0,0,0,114,248,0,0,0,41,5,114,142,0,0,0,114, - 133,0,0,0,114,131,0,0,0,114,43,0,0,0,114,78, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,114,249,0,0,0,58,4,0,0,115,4,0,0,0, - 0,2,8,1,122,32,83,111,117,114,99,101,70,105,108,101, - 76,111,97,100,101,114,46,95,99,97,99,104,101,95,98,121, - 116,101,99,111,100,101,114,86,0,0,0,114,34,1,0,0, - 99,3,0,0,0,0,0,0,0,1,0,0,0,9,0,0, - 0,11,0,0,0,67,0,0,0,115,252,0,0,0,116,0, - 124,1,131,1,92,2,125,4,125,5,103,0,125,6,124,4, - 114,52,116,1,124,4,131,1,115,52,116,0,124,4,131,1, - 92,2,125,4,125,7,124,6,160,2,124,7,161,1,1,0, - 113,16,116,3,124,6,131,1,68,0,93,104,125,7,116,4, - 124,4,124,7,131,2,125,4,122,14,116,5,160,6,124,4, - 161,1,1,0,87,0,113,60,4,0,116,7,121,110,1,0, - 1,0,1,0,89,0,113,60,89,0,113,60,4,0,116,8, - 121,162,1,0,125,8,1,0,122,30,116,9,160,10,100,1, - 124,4,124,8,161,3,1,0,87,0,89,0,100,2,125,8, - 126,8,1,0,100,2,83,0,100,2,125,8,126,8,48,0, - 48,0,113,60,122,28,116,11,124,1,124,2,124,3,131,3, - 1,0,116,9,160,10,100,3,124,1,161,2,1,0,87,0, - 110,52,4,0,116,8,144,0,121,246,1,0,125,8,1,0, - 122,26,116,9,160,10,100,1,124,1,124,8,161,3,1,0, - 87,0,89,0,100,2,125,8,126,8,110,10,100,2,125,8, - 126,8,48,0,48,0,100,2,83,0,41,4,122,27,87,114, - 105,116,101,32,98,121,116,101,115,32,100,97,116,97,32,116, - 111,32,97,32,102,105,108,101,46,122,27,99,111,117,108,100, - 32,110,111,116,32,99,114,101,97,116,101,32,123,33,114,125, - 58,32,123,33,114,125,78,122,12,99,114,101,97,116,101,100, - 32,123,33,114,125,41,12,114,74,0,0,0,114,82,0,0, - 0,114,61,0,0,0,218,8,114,101,118,101,114,115,101,100, - 114,67,0,0,0,114,24,0,0,0,90,5,109,107,100,105, - 114,218,15,70,105,108,101,69,120,105,115,116,115,69,114,114, - 111,114,114,76,0,0,0,114,158,0,0,0,114,173,0,0, - 0,114,94,0,0,0,41,9,114,142,0,0,0,114,65,0, - 0,0,114,43,0,0,0,114,35,1,0,0,218,6,112,97, - 114,101,110,116,114,119,0,0,0,114,63,0,0,0,114,68, - 0,0,0,114,251,0,0,0,114,10,0,0,0,114,10,0, - 0,0,114,11,0,0,0,114,248,0,0,0,63,4,0,0, - 115,46,0,0,0,0,2,12,1,4,2,12,1,12,1,12, - 2,12,1,10,1,2,1,14,1,12,2,8,1,14,3,6, - 1,4,255,4,2,28,1,2,1,12,1,16,1,16,2,8, - 1,2,255,122,25,83,111,117,114,99,101,70,105,108,101,76, - 111,97,100,101,114,46,115,101,116,95,100,97,116,97,78,41, - 7,114,149,0,0,0,114,148,0,0,0,114,150,0,0,0, - 114,151,0,0,0,114,247,0,0,0,114,249,0,0,0,114, - 248,0,0,0,114,10,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,114,32,1,0,0,49,4,0, - 0,115,8,0,0,0,8,2,4,2,8,5,8,5,114,32, - 1,0,0,99,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,0,0,2,0,0,0,64,0,0,0,115,32,0,0, - 0,101,0,90,1,100,0,90,2,100,1,90,3,100,2,100, - 3,132,0,90,4,100,4,100,5,132,0,90,5,100,6,83, - 0,41,7,218,20,83,111,117,114,99,101,108,101,115,115,70, - 105,108,101,76,111,97,100,101,114,122,45,76,111,97,100,101, - 114,32,119,104,105,99,104,32,104,97,110,100,108,101,115,32, - 115,111,117,114,99,101,108,101,115,115,32,102,105,108,101,32, - 105,109,112,111,114,116,115,46,99,2,0,0,0,0,0,0, - 0,0,0,0,0,5,0,0,0,5,0,0,0,67,0,0, - 0,115,68,0,0,0,124,0,160,0,124,1,161,1,125,2, - 124,0,160,1,124,2,161,1,125,3,124,1,124,2,100,1, - 156,2,125,4,116,2,124,3,124,1,124,4,131,3,1,0, - 116,3,116,4,124,3,131,1,100,2,100,0,133,2,25,0, - 124,1,124,2,100,3,141,3,83,0,41,4,78,114,183,0, - 0,0,114,169,0,0,0,41,2,114,140,0,0,0,114,131, - 0,0,0,41,5,114,203,0,0,0,114,250,0,0,0,114, - 176,0,0,0,114,189,0,0,0,114,2,1,0,0,41,5, - 114,142,0,0,0,114,163,0,0,0,114,65,0,0,0,114, - 43,0,0,0,114,175,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,114,236,0,0,0,98,4,0, - 0,115,22,0,0,0,0,1,10,1,10,4,2,1,2,254, - 6,4,12,1,2,1,14,1,2,1,2,253,122,29,83,111, - 117,114,99,101,108,101,115,115,70,105,108,101,76,111,97,100, - 101,114,46,103,101,116,95,99,111,100,101,99,2,0,0,0, - 0,0,0,0,0,0,0,0,2,0,0,0,1,0,0,0, - 67,0,0,0,115,4,0,0,0,100,1,83,0,41,2,122, - 39,82,101,116,117,114,110,32,78,111,110,101,32,97,115,32, - 116,104,101,114,101,32,105,115,32,110,111,32,115,111,117,114, - 99,101,32,99,111,100,101,46,78,114,10,0,0,0,114,242, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,114,252,0,0,0,114,4,0,0,115,2,0,0,0, - 0,2,122,31,83,111,117,114,99,101,108,101,115,115,70,105, - 108,101,76,111,97,100,101,114,46,103,101,116,95,115,111,117, - 114,99,101,78,41,6,114,149,0,0,0,114,148,0,0,0, - 114,150,0,0,0,114,151,0,0,0,114,236,0,0,0,114, - 252,0,0,0,114,10,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,114,39,1,0,0,94,4,0, - 0,115,6,0,0,0,8,2,4,2,8,16,114,39,1,0, + 122,112,87,105,110,100,111,119,115,82,101,103,105,115,116,114, + 121,70,105,110,100,101,114,46,102,105,110,100,95,109,111,100, + 117,108,101,40,41,32,105,115,32,100,101,112,114,101,99,97, + 116,101,100,32,97,110,100,32,115,108,97,116,101,100,32,102, + 111,114,32,114,101,109,111,118,97,108,32,105,110,32,80,121, + 116,104,111,110,32,51,46,49,50,59,32,117,115,101,32,102, + 105,110,100,95,115,112,101,99,40,41,32,105,110,115,116,101, + 97,100,78,169,5,114,99,0,0,0,114,100,0,0,0,114, + 101,0,0,0,114,226,0,0,0,114,164,0,0,0,169,4, + 114,221,0,0,0,114,163,0,0,0,114,65,0,0,0,114, + 210,0,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,218,11,102,105,110,100,95,109,111,100,117,108,101, + 76,3,0,0,115,14,0,0,0,6,7,2,2,4,254,12, + 3,8,1,6,1,4,2,122,33,87,105,110,100,111,119,115, + 82,101,103,105,115,116,114,121,70,105,110,100,101,114,46,102, + 105,110,100,95,109,111,100,117,108,101,169,2,78,78,114,69, + 0,0,0,41,15,114,150,0,0,0,114,149,0,0,0,114, + 151,0,0,0,114,152,0,0,0,114,219,0,0,0,114,218, + 0,0,0,218,11,95,77,83,95,87,73,78,68,79,87,83, + 218,18,69,88,84,69,78,83,73,79,78,95,83,85,70,70, + 73,88,69,83,114,217,0,0,0,218,12,115,116,97,116,105, + 99,109,101,116,104,111,100,114,216,0,0,0,218,11,99,108, + 97,115,115,109,101,116,104,111,100,114,223,0,0,0,114,226, + 0,0,0,114,229,0,0,0,114,7,0,0,0,114,7,0, + 0,0,114,7,0,0,0,114,8,0,0,0,114,214,0,0, + 0,26,3,0,0,115,30,0,0,0,8,0,4,2,2,3, + 2,255,2,4,2,255,12,3,2,2,10,1,2,6,10,1, + 2,14,12,1,2,15,16,1,114,214,0,0,0,99,0,0, + 0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,0, + 0,0,64,0,0,0,115,48,0,0,0,101,0,90,1,100, + 0,90,2,100,1,90,3,100,2,100,3,132,0,90,4,100, + 4,100,5,132,0,90,5,100,6,100,7,132,0,90,6,100, + 8,100,9,132,0,90,7,100,10,83,0,41,11,218,13,95, + 76,111,97,100,101,114,66,97,115,105,99,115,122,83,66,97, + 115,101,32,99,108,97,115,115,32,111,102,32,99,111,109,109, + 111,110,32,99,111,100,101,32,110,101,101,100,101,100,32,98, + 121,32,98,111,116,104,32,83,111,117,114,99,101,76,111,97, + 100,101,114,32,97,110,100,10,32,32,32,32,83,111,117,114, + 99,101,108,101,115,115,70,105,108,101,76,111,97,100,101,114, + 46,99,2,0,0,0,0,0,0,0,0,0,0,0,5,0, + 0,0,4,0,0,0,67,0,0,0,115,64,0,0,0,116, + 0,124,0,160,1,124,1,161,1,131,1,100,1,25,0,125, + 2,124,2,160,2,100,2,100,1,161,2,100,3,25,0,125, + 3,124,1,160,3,100,2,161,1,100,4,25,0,125,4,124, + 3,100,5,107,2,111,31,124,4,100,5,107,3,83,0,41, + 6,122,141,67,111,110,99,114,101,116,101,32,105,109,112,108, + 101,109,101,110,116,97,116,105,111,110,32,111,102,32,73,110, + 115,112,101,99,116,76,111,97,100,101,114,46,105,115,95,112, + 97,99,107,97,103,101,32,98,121,32,99,104,101,99,107,105, + 110,103,32,105,102,10,32,32,32,32,32,32,32,32,116,104, + 101,32,112,97,116,104,32,114,101,116,117,114,110,101,100,32, + 98,121,32,103,101,116,95,102,105,108,101,110,97,109,101,32, + 104,97,115,32,97,32,102,105,108,101,110,97,109,101,32,111, + 102,32,39,95,95,105,110,105,116,95,95,46,112,121,39,46, + 114,3,0,0,0,114,97,0,0,0,114,0,0,0,0,114, + 44,0,0,0,218,8,95,95,105,110,105,116,95,95,41,4, + 114,74,0,0,0,114,203,0,0,0,114,125,0,0,0,114, + 104,0,0,0,41,5,114,143,0,0,0,114,163,0,0,0, + 114,120,0,0,0,90,13,102,105,108,101,110,97,109,101,95, + 98,97,115,101,90,9,116,97,105,108,95,110,97,109,101,114, + 7,0,0,0,114,7,0,0,0,114,8,0,0,0,114,206, + 0,0,0,98,3,0,0,115,8,0,0,0,18,3,16,1, + 14,1,16,1,122,24,95,76,111,97,100,101,114,66,97,115, + 105,99,115,46,105,115,95,112,97,99,107,97,103,101,99,2, + 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,1, + 0,0,0,67,0,0,0,114,23,0,0,0,169,2,122,42, + 85,115,101,32,100,101,102,97,117,108,116,32,115,101,109,97, + 110,116,105,99,115,32,102,111,114,32,109,111,100,117,108,101, + 32,99,114,101,97,116,105,111,110,46,78,114,7,0,0,0, + 169,2,114,143,0,0,0,114,210,0,0,0,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,218,13,99,114,101, + 97,116,101,95,109,111,100,117,108,101,106,3,0,0,243,2, + 0,0,0,4,0,122,27,95,76,111,97,100,101,114,66,97, + 115,105,99,115,46,99,114,101,97,116,101,95,109,111,100,117, + 108,101,99,2,0,0,0,0,0,0,0,0,0,0,0,3, + 0,0,0,5,0,0,0,67,0,0,0,115,56,0,0,0, + 124,0,160,0,124,1,106,1,161,1,125,2,124,2,100,1, + 117,0,114,18,116,2,100,2,160,3,124,1,106,1,161,1, + 131,1,130,1,116,4,160,5,116,6,124,2,124,1,106,7, + 161,3,1,0,100,1,83,0,41,3,122,19,69,120,101,99, + 117,116,101,32,116,104,101,32,109,111,100,117,108,101,46,78, + 122,52,99,97,110,110,111,116,32,108,111,97,100,32,109,111, + 100,117,108,101,32,123,33,114,125,32,119,104,101,110,32,103, + 101,116,95,99,111,100,101,40,41,32,114,101,116,117,114,110, + 115,32,78,111,110,101,41,8,218,8,103,101,116,95,99,111, + 100,101,114,150,0,0,0,114,142,0,0,0,114,89,0,0, + 0,114,159,0,0,0,218,25,95,99,97,108,108,95,119,105, + 116,104,95,102,114,97,109,101,115,95,114,101,109,111,118,101, + 100,218,4,101,120,101,99,114,156,0,0,0,41,3,114,143, + 0,0,0,218,6,109,111,100,117,108,101,114,188,0,0,0, + 114,7,0,0,0,114,7,0,0,0,114,8,0,0,0,218, + 11,101,120,101,99,95,109,111,100,117,108,101,109,3,0,0, + 115,12,0,0,0,12,2,8,1,4,1,8,1,4,255,20, + 2,122,25,95,76,111,97,100,101,114,66,97,115,105,99,115, + 46,101,120,101,99,95,109,111,100,117,108,101,99,2,0,0, + 0,0,0,0,0,0,0,0,0,2,0,0,0,4,0,0, + 0,67,0,0,0,115,12,0,0,0,116,0,160,1,124,0, + 124,1,161,2,83,0,41,1,122,26,84,104,105,115,32,109, + 101,116,104,111,100,32,105,115,32,100,101,112,114,101,99,97, + 116,101,100,46,41,2,114,159,0,0,0,218,17,95,108,111, + 97,100,95,109,111,100,117,108,101,95,115,104,105,109,169,2, + 114,143,0,0,0,114,163,0,0,0,114,7,0,0,0,114, + 7,0,0,0,114,8,0,0,0,218,11,108,111,97,100,95, + 109,111,100,117,108,101,117,3,0,0,115,2,0,0,0,12, + 3,122,25,95,76,111,97,100,101,114,66,97,115,105,99,115, + 46,108,111,97,100,95,109,111,100,117,108,101,78,41,8,114, + 150,0,0,0,114,149,0,0,0,114,151,0,0,0,114,152, + 0,0,0,114,206,0,0,0,114,239,0,0,0,114,245,0, + 0,0,114,248,0,0,0,114,7,0,0,0,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,114,235,0,0,0, + 93,3,0,0,115,12,0,0,0,8,0,4,2,8,3,8, + 8,8,3,12,8,114,235,0,0,0,99,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0,0,3,0,0,0,64, + 0,0,0,115,74,0,0,0,101,0,90,1,100,0,90,2, + 100,1,100,2,132,0,90,3,100,3,100,4,132,0,90,4, + 100,5,100,6,132,0,90,5,100,7,100,8,132,0,90,6, + 100,9,100,10,132,0,90,7,100,11,100,12,156,1,100,13, + 100,14,132,2,90,8,100,15,100,16,132,0,90,9,100,17, + 83,0,41,18,218,12,83,111,117,114,99,101,76,111,97,100, + 101,114,99,2,0,0,0,0,0,0,0,0,0,0,0,2, + 0,0,0,1,0,0,0,67,0,0,0,115,4,0,0,0, + 116,0,130,1,41,1,122,165,79,112,116,105,111,110,97,108, + 32,109,101,116,104,111,100,32,116,104,97,116,32,114,101,116, + 117,114,110,115,32,116,104,101,32,109,111,100,105,102,105,99, + 97,116,105,111,110,32,116,105,109,101,32,40,97,110,32,105, + 110,116,41,32,102,111,114,32,116,104,101,10,32,32,32,32, + 32,32,32,32,115,112,101,99,105,102,105,101,100,32,112,97, + 116,104,32,40,97,32,115,116,114,41,46,10,10,32,32,32, + 32,32,32,32,32,82,97,105,115,101,115,32,79,83,69,114, + 114,111,114,32,119,104,101,110,32,116,104,101,32,112,97,116, + 104,32,99,97,110,110,111,116,32,98,101,32,104,97,110,100, + 108,101,100,46,10,32,32,32,32,32,32,32,32,41,1,114, + 76,0,0,0,169,2,114,143,0,0,0,114,65,0,0,0, + 114,7,0,0,0,114,7,0,0,0,114,8,0,0,0,218, + 10,112,97,116,104,95,109,116,105,109,101,125,3,0,0,115, + 2,0,0,0,4,6,122,23,83,111,117,114,99,101,76,111, + 97,100,101,114,46,112,97,116,104,95,109,116,105,109,101,99, + 2,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0, + 4,0,0,0,67,0,0,0,115,14,0,0,0,100,1,124, + 0,160,0,124,1,161,1,105,1,83,0,41,2,97,158,1, + 0,0,79,112,116,105,111,110,97,108,32,109,101,116,104,111, + 100,32,114,101,116,117,114,110,105,110,103,32,97,32,109,101, + 116,97,100,97,116,97,32,100,105,99,116,32,102,111,114,32, + 116,104,101,32,115,112,101,99,105,102,105,101,100,10,32,32, + 32,32,32,32,32,32,112,97,116,104,32,40,97,32,115,116, + 114,41,46,10,10,32,32,32,32,32,32,32,32,80,111,115, + 115,105,98,108,101,32,107,101,121,115,58,10,32,32,32,32, + 32,32,32,32,45,32,39,109,116,105,109,101,39,32,40,109, + 97,110,100,97,116,111,114,121,41,32,105,115,32,116,104,101, + 32,110,117,109,101,114,105,99,32,116,105,109,101,115,116,97, + 109,112,32,111,102,32,108,97,115,116,32,115,111,117,114,99, + 101,10,32,32,32,32,32,32,32,32,32,32,99,111,100,101, + 32,109,111,100,105,102,105,99,97,116,105,111,110,59,10,32, + 32,32,32,32,32,32,32,45,32,39,115,105,122,101,39,32, + 40,111,112,116,105,111,110,97,108,41,32,105,115,32,116,104, + 101,32,115,105,122,101,32,105,110,32,98,121,116,101,115,32, + 111,102,32,116,104,101,32,115,111,117,114,99,101,32,99,111, + 100,101,46,10,10,32,32,32,32,32,32,32,32,73,109,112, + 108,101,109,101,110,116,105,110,103,32,116,104,105,115,32,109, + 101,116,104,111,100,32,97,108,108,111,119,115,32,116,104,101, + 32,108,111,97,100,101,114,32,116,111,32,114,101,97,100,32, + 98,121,116,101,99,111,100,101,32,102,105,108,101,115,46,10, + 32,32,32,32,32,32,32,32,82,97,105,115,101,115,32,79, + 83,69,114,114,111,114,32,119,104,101,110,32,116,104,101,32, + 112,97,116,104,32,99,97,110,110,111,116,32,98,101,32,104, + 97,110,100,108,101,100,46,10,32,32,32,32,32,32,32,32, + 114,193,0,0,0,41,1,114,251,0,0,0,114,250,0,0, + 0,114,7,0,0,0,114,7,0,0,0,114,8,0,0,0, + 218,10,112,97,116,104,95,115,116,97,116,115,133,3,0,0, + 115,2,0,0,0,14,12,122,23,83,111,117,114,99,101,76, + 111,97,100,101,114,46,112,97,116,104,95,115,116,97,116,115, + 99,4,0,0,0,0,0,0,0,0,0,0,0,4,0,0, + 0,4,0,0,0,67,0,0,0,115,12,0,0,0,124,0, + 160,0,124,2,124,3,161,2,83,0,41,1,122,228,79,112, + 116,105,111,110,97,108,32,109,101,116,104,111,100,32,119,104, + 105,99,104,32,119,114,105,116,101,115,32,100,97,116,97,32, + 40,98,121,116,101,115,41,32,116,111,32,97,32,102,105,108, + 101,32,112,97,116,104,32,40,97,32,115,116,114,41,46,10, + 10,32,32,32,32,32,32,32,32,73,109,112,108,101,109,101, + 110,116,105,110,103,32,116,104,105,115,32,109,101,116,104,111, + 100,32,97,108,108,111,119,115,32,102,111,114,32,116,104,101, + 32,119,114,105,116,105,110,103,32,111,102,32,98,121,116,101, + 99,111,100,101,32,102,105,108,101,115,46,10,10,32,32,32, + 32,32,32,32,32,84,104,101,32,115,111,117,114,99,101,32, + 112,97,116,104,32,105,115,32,110,101,101,100,101,100,32,105, + 110,32,111,114,100,101,114,32,116,111,32,99,111,114,114,101, + 99,116,108,121,32,116,114,97,110,115,102,101,114,32,112,101, + 114,109,105,115,115,105,111,110,115,10,32,32,32,32,32,32, + 32,32,41,1,218,8,115,101,116,95,100,97,116,97,41,4, + 114,143,0,0,0,114,134,0,0,0,90,10,99,97,99,104, + 101,95,112,97,116,104,114,41,0,0,0,114,7,0,0,0, + 114,7,0,0,0,114,8,0,0,0,218,15,95,99,97,99, + 104,101,95,98,121,116,101,99,111,100,101,147,3,0,0,115, + 2,0,0,0,12,8,122,28,83,111,117,114,99,101,76,111, + 97,100,101,114,46,95,99,97,99,104,101,95,98,121,116,101, + 99,111,100,101,99,3,0,0,0,0,0,0,0,0,0,0, + 0,3,0,0,0,1,0,0,0,67,0,0,0,114,23,0, + 0,0,41,2,122,150,79,112,116,105,111,110,97,108,32,109, + 101,116,104,111,100,32,119,104,105,99,104,32,119,114,105,116, + 101,115,32,100,97,116,97,32,40,98,121,116,101,115,41,32, + 116,111,32,97,32,102,105,108,101,32,112,97,116,104,32,40, + 97,32,115,116,114,41,46,10,10,32,32,32,32,32,32,32, + 32,73,109,112,108,101,109,101,110,116,105,110,103,32,116,104, + 105,115,32,109,101,116,104,111,100,32,97,108,108,111,119,115, + 32,102,111,114,32,116,104,101,32,119,114,105,116,105,110,103, + 32,111,102,32,98,121,116,101,99,111,100,101,32,102,105,108, + 101,115,46,10,32,32,32,32,32,32,32,32,78,114,7,0, + 0,0,41,3,114,143,0,0,0,114,65,0,0,0,114,41, + 0,0,0,114,7,0,0,0,114,7,0,0,0,114,8,0, + 0,0,114,253,0,0,0,157,3,0,0,114,240,0,0,0, + 122,21,83,111,117,114,99,101,76,111,97,100,101,114,46,115, + 101,116,95,100,97,116,97,99,2,0,0,0,0,0,0,0, + 0,0,0,0,5,0,0,0,10,0,0,0,67,0,0,0, + 115,70,0,0,0,124,0,160,0,124,1,161,1,125,2,122, + 10,124,0,160,1,124,2,161,1,125,3,87,0,116,4,124, + 3,131,1,83,0,4,0,116,2,121,34,1,0,125,4,1, + 0,122,7,116,3,100,1,124,1,100,2,141,2,124,4,130, + 2,100,3,125,4,126,4,119,1,119,0,41,4,122,52,67, + 111,110,99,114,101,116,101,32,105,109,112,108,101,109,101,110, + 116,97,116,105,111,110,32,111,102,32,73,110,115,112,101,99, + 116,76,111,97,100,101,114,46,103,101,116,95,115,111,117,114, + 99,101,46,122,39,115,111,117,114,99,101,32,110,111,116,32, + 97,118,97,105,108,97,98,108,101,32,116,104,114,111,117,103, + 104,32,103,101,116,95,100,97,116,97,40,41,114,140,0,0, + 0,78,41,5,114,203,0,0,0,218,8,103,101,116,95,100, + 97,116,97,114,76,0,0,0,114,142,0,0,0,114,200,0, + 0,0,41,5,114,143,0,0,0,114,163,0,0,0,114,65, + 0,0,0,114,198,0,0,0,218,3,101,120,99,114,7,0, + 0,0,114,7,0,0,0,114,8,0,0,0,218,10,103,101, + 116,95,115,111,117,114,99,101,164,3,0,0,115,24,0,0, + 0,10,2,2,1,12,1,8,4,14,253,4,1,2,1,4, + 255,2,1,2,255,8,128,2,255,122,23,83,111,117,114,99, + 101,76,111,97,100,101,114,46,103,101,116,95,115,111,117,114, + 99,101,114,130,0,0,0,41,1,218,9,95,111,112,116,105, + 109,105,122,101,99,3,0,0,0,0,0,0,0,1,0,0, + 0,4,0,0,0,8,0,0,0,67,0,0,0,115,22,0, + 0,0,116,0,106,1,116,2,124,1,124,2,100,1,100,2, + 124,3,100,3,141,6,83,0,41,4,122,130,82,101,116,117, + 114,110,32,116,104,101,32,99,111,100,101,32,111,98,106,101, + 99,116,32,99,111,109,112,105,108,101,100,32,102,114,111,109, + 32,115,111,117,114,99,101,46,10,10,32,32,32,32,32,32, + 32,32,84,104,101,32,39,100,97,116,97,39,32,97,114,103, + 117,109,101,110,116,32,99,97,110,32,98,101,32,97,110,121, + 32,111,98,106,101,99,116,32,116,121,112,101,32,116,104,97, + 116,32,99,111,109,112,105,108,101,40,41,32,115,117,112,112, + 111,114,116,115,46,10,32,32,32,32,32,32,32,32,114,243, + 0,0,0,84,41,2,218,12,100,111,110,116,95,105,110,104, + 101,114,105,116,114,108,0,0,0,41,3,114,159,0,0,0, + 114,242,0,0,0,218,7,99,111,109,112,105,108,101,41,4, + 114,143,0,0,0,114,41,0,0,0,114,65,0,0,0,114, + 2,1,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,218,14,115,111,117,114,99,101,95,116,111,95,99, + 111,100,101,174,3,0,0,115,6,0,0,0,12,5,4,1, + 6,255,122,27,83,111,117,114,99,101,76,111,97,100,101,114, + 46,115,111,117,114,99,101,95,116,111,95,99,111,100,101,99, + 2,0,0,0,0,0,0,0,0,0,0,0,15,0,0,0, + 9,0,0,0,67,0,0,0,115,2,2,0,0,124,0,160, + 0,124,1,161,1,125,2,100,1,125,3,100,1,125,4,100, + 1,125,5,100,2,125,6,100,3,125,7,122,6,116,1,124, + 2,131,1,125,8,87,0,110,11,4,0,116,2,121,32,1, + 0,1,0,1,0,100,1,125,8,89,0,110,144,119,0,122, + 7,124,0,160,3,124,2,161,1,125,9,87,0,110,9,4, + 0,116,4,121,49,1,0,1,0,1,0,89,0,110,127,119, + 0,116,5,124,9,100,4,25,0,131,1,125,3,122,7,124, + 0,160,6,124,8,161,1,125,10,87,0,110,9,4,0,116, + 4,121,72,1,0,1,0,1,0,89,0,110,104,119,0,124, + 1,124,8,100,5,156,2,125,11,122,71,116,7,124,10,124, + 1,124,11,131,3,125,12,116,8,124,10,131,1,100,6,100, + 1,133,2,25,0,125,13,124,12,100,7,64,0,100,8,107, + 3,125,6,124,6,114,138,124,12,100,9,64,0,100,8,107, + 3,125,7,116,9,106,10,100,10,107,3,114,137,124,7,115, + 119,116,9,106,10,100,11,107,2,114,137,124,0,160,6,124, + 2,161,1,125,4,116,9,160,11,116,12,124,4,161,2,125, + 5,116,13,124,10,124,5,124,1,124,11,131,4,1,0,110, + 10,116,14,124,10,124,3,124,9,100,12,25,0,124,1,124, + 11,131,5,1,0,87,0,110,11,4,0,116,15,116,16,102, + 2,121,160,1,0,1,0,1,0,89,0,110,16,119,0,116, + 17,160,18,100,13,124,8,124,2,161,3,1,0,116,19,124, + 13,124,1,124,8,124,2,100,14,141,4,83,0,124,4,100, + 1,117,0,114,185,124,0,160,6,124,2,161,1,125,4,124, + 0,160,20,124,4,124,2,161,2,125,14,116,17,160,18,100, + 15,124,2,161,2,1,0,116,21,106,22,115,255,124,8,100, + 1,117,1,114,255,124,3,100,1,117,1,114,255,124,6,114, + 226,124,5,100,1,117,0,114,219,116,9,160,11,124,4,161, + 1,125,5,116,23,124,14,124,5,124,7,131,3,125,10,110, + 8,116,24,124,14,124,3,116,25,124,4,131,1,131,3,125, + 10,122,10,124,0,160,26,124,2,124,8,124,10,161,3,1, + 0,87,0,124,14,83,0,4,0,116,2,121,254,1,0,1, + 0,1,0,89,0,124,14,83,0,119,0,124,14,83,0,41, + 16,122,190,67,111,110,99,114,101,116,101,32,105,109,112,108, + 101,109,101,110,116,97,116,105,111,110,32,111,102,32,73,110, + 115,112,101,99,116,76,111,97,100,101,114,46,103,101,116,95, + 99,111,100,101,46,10,10,32,32,32,32,32,32,32,32,82, + 101,97,100,105,110,103,32,111,102,32,98,121,116,101,99,111, + 100,101,32,114,101,113,117,105,114,101,115,32,112,97,116,104, + 95,115,116,97,116,115,32,116,111,32,98,101,32,105,109,112, + 108,101,109,101,110,116,101,100,46,32,84,111,32,119,114,105, + 116,101,10,32,32,32,32,32,32,32,32,98,121,116,101,99, + 111,100,101,44,32,115,101,116,95,100,97,116,97,32,109,117, + 115,116,32,97,108,115,111,32,98,101,32,105,109,112,108,101, + 109,101,110,116,101,100,46,10,10,32,32,32,32,32,32,32, + 32,78,70,84,114,193,0,0,0,114,183,0,0,0,114,169, + 0,0,0,114,3,0,0,0,114,0,0,0,0,114,44,0, + 0,0,90,5,110,101,118,101,114,90,6,97,108,119,97,121, + 115,218,4,115,105,122,101,122,13,123,125,32,109,97,116,99, + 104,101,115,32,123,125,41,3,114,141,0,0,0,114,132,0, + 0,0,114,134,0,0,0,122,19,99,111,100,101,32,111,98, + 106,101,99,116,32,102,114,111,109,32,123,125,41,27,114,203, + 0,0,0,114,121,0,0,0,114,107,0,0,0,114,252,0, + 0,0,114,76,0,0,0,114,33,0,0,0,114,255,0,0, + 0,114,176,0,0,0,218,10,109,101,109,111,114,121,118,105, + 101,119,114,187,0,0,0,90,21,99,104,101,99,107,95,104, + 97,115,104,95,98,97,115,101,100,95,112,121,99,115,114,181, + 0,0,0,218,17,95,82,65,87,95,77,65,71,73,67,95, + 78,85,77,66,69,82,114,182,0,0,0,114,180,0,0,0, + 114,142,0,0,0,114,174,0,0,0,114,159,0,0,0,114, + 173,0,0,0,114,189,0,0,0,114,5,1,0,0,114,15, + 0,0,0,218,19,100,111,110,116,95,119,114,105,116,101,95, + 98,121,116,101,99,111,100,101,114,195,0,0,0,114,194,0, + 0,0,114,4,0,0,0,114,254,0,0,0,41,15,114,143, + 0,0,0,114,163,0,0,0,114,134,0,0,0,114,178,0, + 0,0,114,198,0,0,0,114,181,0,0,0,90,10,104,97, + 115,104,95,98,97,115,101,100,90,12,99,104,101,99,107,95, + 115,111,117,114,99,101,114,132,0,0,0,218,2,115,116,114, + 41,0,0,0,114,175,0,0,0,114,16,0,0,0,90,10, + 98,121,116,101,115,95,100,97,116,97,90,11,99,111,100,101, + 95,111,98,106,101,99,116,114,7,0,0,0,114,7,0,0, + 0,114,8,0,0,0,114,241,0,0,0,182,3,0,0,115, + 170,0,0,0,10,7,4,1,4,1,4,1,4,1,4,1, + 2,1,12,1,12,1,8,1,2,255,2,3,14,1,12,1, + 4,1,2,255,12,3,2,1,14,1,12,1,4,1,2,255, + 2,4,2,1,6,254,2,4,12,1,16,1,12,1,4,1, + 12,1,10,1,2,1,2,255,8,2,2,254,10,3,4,1, + 2,1,2,1,4,254,8,4,2,1,4,255,2,128,2,3, + 2,1,2,1,6,1,2,1,2,1,4,251,4,128,16,7, + 4,1,2,255,8,3,2,1,4,255,6,2,2,1,2,1, + 6,254,8,3,10,1,12,1,12,1,14,1,6,1,2,255, + 4,2,8,1,10,1,14,1,6,2,6,1,4,255,2,2, + 16,1,4,3,12,254,2,1,4,1,2,254,4,2,122,21, + 83,111,117,114,99,101,76,111,97,100,101,114,46,103,101,116, + 95,99,111,100,101,78,41,10,114,150,0,0,0,114,149,0, + 0,0,114,151,0,0,0,114,251,0,0,0,114,252,0,0, + 0,114,254,0,0,0,114,253,0,0,0,114,1,1,0,0, + 114,5,1,0,0,114,241,0,0,0,114,7,0,0,0,114, + 7,0,0,0,114,7,0,0,0,114,8,0,0,0,114,249, + 0,0,0,123,3,0,0,115,16,0,0,0,8,0,8,2, + 8,8,8,14,8,10,8,7,14,10,12,8,114,249,0,0, 0,99,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,3,0,0,0,64,0,0,0,115,92,0,0,0,101, + 0,0,4,0,0,0,0,0,0,0,115,92,0,0,0,101, 0,90,1,100,0,90,2,100,1,90,3,100,2,100,3,132, 0,90,4,100,4,100,5,132,0,90,5,100,6,100,7,132, - 0,90,6,100,8,100,9,132,0,90,7,100,10,100,11,132, - 0,90,8,100,12,100,13,132,0,90,9,100,14,100,15,132, - 0,90,10,100,16,100,17,132,0,90,11,101,12,100,18,100, - 19,132,0,131,1,90,13,100,20,83,0,41,21,114,19,1, - 0,0,122,93,76,111,97,100,101,114,32,102,111,114,32,101, - 120,116,101,110,115,105,111,110,32,109,111,100,117,108,101,115, - 46,10,10,32,32,32,32,84,104,101,32,99,111,110,115,116, - 114,117,99,116,111,114,32,105,115,32,100,101,115,105,103,110, - 101,100,32,116,111,32,119,111,114,107,32,119,105,116,104,32, - 70,105,108,101,70,105,110,100,101,114,46,10,10,32,32,32, - 32,99,3,0,0,0,0,0,0,0,0,0,0,0,3,0, - 0,0,8,0,0,0,67,0,0,0,115,62,0,0,0,124, - 1,124,0,95,0,116,1,124,2,131,1,115,52,122,18,116, - 2,116,3,160,4,161,0,124,2,131,2,125,2,87,0,110, - 18,4,0,116,5,121,50,1,0,1,0,1,0,89,0,110, - 2,48,0,124,2,124,0,95,6,100,0,83,0,114,69,0, - 0,0,41,7,114,140,0,0,0,114,85,0,0,0,114,67, - 0,0,0,114,24,0,0,0,114,81,0,0,0,114,76,0, - 0,0,114,65,0,0,0,114,28,1,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,114,232,0,0,0, - 131,4,0,0,115,14,0,0,0,0,1,6,1,8,1,2, - 1,18,1,12,1,6,1,122,28,69,120,116,101,110,115,105, - 111,110,70,105,108,101,76,111,97,100,101,114,46,95,95,105, - 110,105,116,95,95,99,2,0,0,0,0,0,0,0,0,0, - 0,0,2,0,0,0,2,0,0,0,67,0,0,0,115,24, - 0,0,0,124,0,106,0,124,1,106,0,107,2,111,22,124, - 0,106,1,124,1,106,1,107,2,83,0,114,69,0,0,0, - 114,7,1,0,0,114,9,1,0,0,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,114,10,1,0,0,140,4, - 0,0,115,6,0,0,0,0,1,12,1,10,255,122,26,69, + 0,90,6,101,7,135,0,102,1,100,8,100,9,132,8,131, + 1,90,8,101,7,100,10,100,11,132,0,131,1,90,9,100, + 12,100,13,132,0,90,10,101,7,100,14,100,15,132,0,131, + 1,90,11,135,0,4,0,90,12,83,0,41,16,218,10,70, + 105,108,101,76,111,97,100,101,114,122,103,66,97,115,101,32, + 102,105,108,101,32,108,111,97,100,101,114,32,99,108,97,115, + 115,32,119,104,105,99,104,32,105,109,112,108,101,109,101,110, + 116,115,32,116,104,101,32,108,111,97,100,101,114,32,112,114, + 111,116,111,99,111,108,32,109,101,116,104,111,100,115,32,116, + 104,97,116,10,32,32,32,32,114,101,113,117,105,114,101,32, + 102,105,108,101,32,115,121,115,116,101,109,32,117,115,97,103, + 101,46,99,3,0,0,0,0,0,0,0,0,0,0,0,3, + 0,0,0,2,0,0,0,67,0,0,0,115,16,0,0,0, + 124,1,124,0,95,0,124,2,124,0,95,1,100,1,83,0, + 41,2,122,75,67,97,99,104,101,32,116,104,101,32,109,111, + 100,117,108,101,32,110,97,109,101,32,97,110,100,32,116,104, + 101,32,112,97,116,104,32,116,111,32,116,104,101,32,102,105, + 108,101,32,102,111,117,110,100,32,98,121,32,116,104,101,10, + 32,32,32,32,32,32,32,32,102,105,110,100,101,114,46,78, + 114,183,0,0,0,41,3,114,143,0,0,0,114,163,0,0, + 0,114,65,0,0,0,114,7,0,0,0,114,7,0,0,0, + 114,8,0,0,0,114,236,0,0,0,16,4,0,0,115,4, + 0,0,0,6,3,10,1,122,19,70,105,108,101,76,111,97, + 100,101,114,46,95,95,105,110,105,116,95,95,99,2,0,0, + 0,0,0,0,0,0,0,0,0,2,0,0,0,2,0,0, + 0,67,0,0,0,243,24,0,0,0,124,0,106,0,124,1, + 106,0,107,2,111,11,124,0,106,1,124,1,106,1,107,2, + 83,0,114,69,0,0,0,169,2,218,9,95,95,99,108,97, + 115,115,95,95,114,156,0,0,0,169,2,114,143,0,0,0, + 90,5,111,116,104,101,114,114,7,0,0,0,114,7,0,0, + 0,114,8,0,0,0,218,6,95,95,101,113,95,95,22,4, + 0,0,243,6,0,0,0,12,1,10,1,2,255,122,17,70, + 105,108,101,76,111,97,100,101,114,46,95,95,101,113,95,95, + 99,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0, + 0,3,0,0,0,67,0,0,0,243,20,0,0,0,116,0, + 124,0,106,1,131,1,116,0,124,0,106,2,131,1,65,0, + 83,0,114,69,0,0,0,169,3,218,4,104,97,115,104,114, + 141,0,0,0,114,65,0,0,0,169,1,114,143,0,0,0, + 114,7,0,0,0,114,7,0,0,0,114,8,0,0,0,218, + 8,95,95,104,97,115,104,95,95,26,4,0,0,243,2,0, + 0,0,20,1,122,19,70,105,108,101,76,111,97,100,101,114, + 46,95,95,104,97,115,104,95,95,99,2,0,0,0,0,0, + 0,0,0,0,0,0,2,0,0,0,3,0,0,0,3,0, + 0,0,115,16,0,0,0,116,0,116,1,124,0,131,2,160, + 2,124,1,161,1,83,0,41,1,122,100,76,111,97,100,32, + 97,32,109,111,100,117,108,101,32,102,114,111,109,32,97,32, + 102,105,108,101,46,10,10,32,32,32,32,32,32,32,32,84, + 104,105,115,32,109,101,116,104,111,100,32,105,115,32,100,101, + 112,114,101,99,97,116,101,100,46,32,32,85,115,101,32,101, + 120,101,99,95,109,111,100,117,108,101,40,41,32,105,110,115, + 116,101,97,100,46,10,10,32,32,32,32,32,32,32,32,41, + 3,218,5,115,117,112,101,114,114,11,1,0,0,114,248,0, + 0,0,114,247,0,0,0,169,1,114,14,1,0,0,114,7, + 0,0,0,114,8,0,0,0,114,248,0,0,0,29,4,0, + 0,115,2,0,0,0,16,10,122,22,70,105,108,101,76,111, + 97,100,101,114,46,108,111,97,100,95,109,111,100,117,108,101, + 99,2,0,0,0,0,0,0,0,0,0,0,0,2,0,0, + 0,1,0,0,0,67,0,0,0,243,6,0,0,0,124,0, + 106,0,83,0,169,1,122,58,82,101,116,117,114,110,32,116, + 104,101,32,112,97,116,104,32,116,111,32,116,104,101,32,115, + 111,117,114,99,101,32,102,105,108,101,32,97,115,32,102,111, + 117,110,100,32,98,121,32,116,104,101,32,102,105,110,100,101, + 114,46,114,71,0,0,0,114,247,0,0,0,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,114,203,0,0,0, + 41,4,0,0,243,2,0,0,0,6,3,122,23,70,105,108, + 101,76,111,97,100,101,114,46,103,101,116,95,102,105,108,101, + 110,97,109,101,99,2,0,0,0,0,0,0,0,0,0,0, + 0,3,0,0,0,8,0,0,0,67,0,0,0,115,128,0, + 0,0,116,0,124,0,116,1,116,2,102,2,131,2,114,36, + 116,3,160,4,116,5,124,1,131,1,161,1,143,12,125,2, + 124,2,160,6,161,0,87,0,2,0,100,1,4,0,4,0, + 131,3,1,0,83,0,49,0,115,29,119,1,1,0,1,0, + 1,0,89,0,1,0,100,1,83,0,116,3,160,7,124,1, + 100,2,161,2,143,12,125,2,124,2,160,6,161,0,87,0, + 2,0,100,1,4,0,4,0,131,3,1,0,83,0,49,0, + 115,57,119,1,1,0,1,0,1,0,89,0,1,0,100,1, + 83,0,41,3,122,39,82,101,116,117,114,110,32,116,104,101, + 32,100,97,116,97,32,102,114,111,109,32,112,97,116,104,32, + 97,115,32,114,97,119,32,98,121,116,101,115,46,78,218,1, + 114,41,8,114,185,0,0,0,114,249,0,0,0,218,19,69, 120,116,101,110,115,105,111,110,70,105,108,101,76,111,97,100, - 101,114,46,95,95,101,113,95,95,99,1,0,0,0,0,0, - 0,0,0,0,0,0,1,0,0,0,3,0,0,0,67,0, - 0,0,115,20,0,0,0,116,0,124,0,106,1,131,1,116, - 0,124,0,106,2,131,1,65,0,83,0,114,69,0,0,0, - 114,11,1,0,0,114,13,1,0,0,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,114,14,1,0,0,144,4, - 0,0,115,2,0,0,0,0,1,122,28,69,120,116,101,110, - 115,105,111,110,70,105,108,101,76,111,97,100,101,114,46,95, - 95,104,97,115,104,95,95,99,2,0,0,0,0,0,0,0, - 0,0,0,0,3,0,0,0,5,0,0,0,67,0,0,0, - 115,36,0,0,0,116,0,160,1,116,2,106,3,124,1,161, - 2,125,2,116,0,160,4,100,1,124,1,106,5,124,0,106, - 6,161,3,1,0,124,2,83,0,41,2,122,38,67,114,101, - 97,116,101,32,97,110,32,117,110,105,116,105,97,108,105,122, - 101,100,32,101,120,116,101,110,115,105,111,110,32,109,111,100, - 117,108,101,122,38,101,120,116,101,110,115,105,111,110,32,109, - 111,100,117,108,101,32,123,33,114,125,32,108,111,97,100,101, - 100,32,102,114,111,109,32,123,33,114,125,41,7,114,158,0, - 0,0,114,237,0,0,0,114,187,0,0,0,90,14,99,114, - 101,97,116,101,95,100,121,110,97,109,105,99,114,173,0,0, - 0,114,140,0,0,0,114,65,0,0,0,41,3,114,142,0, - 0,0,114,210,0,0,0,114,239,0,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,114,235,0,0,0, - 147,4,0,0,115,14,0,0,0,0,2,4,1,6,255,4, - 2,6,1,8,255,4,2,122,33,69,120,116,101,110,115,105, - 111,110,70,105,108,101,76,111,97,100,101,114,46,99,114,101, - 97,116,101,95,109,111,100,117,108,101,99,2,0,0,0,0, - 0,0,0,0,0,0,0,2,0,0,0,5,0,0,0,67, - 0,0,0,115,36,0,0,0,116,0,160,1,116,2,106,3, - 124,1,161,2,1,0,116,0,160,4,100,1,124,0,106,5, - 124,0,106,6,161,3,1,0,100,2,83,0,41,3,122,30, - 73,110,105,116,105,97,108,105,122,101,32,97,110,32,101,120, - 116,101,110,115,105,111,110,32,109,111,100,117,108,101,122,40, + 101,114,114,91,0,0,0,90,9,111,112,101,110,95,99,111, + 100,101,114,109,0,0,0,90,4,114,101,97,100,114,92,0, + 0,0,41,3,114,143,0,0,0,114,65,0,0,0,114,94, + 0,0,0,114,7,0,0,0,114,7,0,0,0,114,8,0, + 0,0,114,255,0,0,0,46,4,0,0,115,14,0,0,0, + 14,2,16,1,6,1,36,255,14,3,6,1,36,255,122,19, + 70,105,108,101,76,111,97,100,101,114,46,103,101,116,95,100, + 97,116,97,99,2,0,0,0,0,0,0,0,0,0,0,0, + 3,0,0,0,2,0,0,0,67,0,0,0,115,20,0,0, + 0,100,1,100,2,108,0,109,1,125,2,1,0,124,2,124, + 0,131,1,83,0,41,3,78,114,0,0,0,0,41,1,218, + 10,70,105,108,101,82,101,97,100,101,114,41,2,218,17,105, + 109,112,111,114,116,108,105,98,46,114,101,97,100,101,114,115, + 114,31,1,0,0,41,3,114,143,0,0,0,114,244,0,0, + 0,114,31,1,0,0,114,7,0,0,0,114,7,0,0,0, + 114,8,0,0,0,218,19,103,101,116,95,114,101,115,111,117, + 114,99,101,95,114,101,97,100,101,114,55,4,0,0,115,4, + 0,0,0,12,2,8,1,122,30,70,105,108,101,76,111,97, + 100,101,114,46,103,101,116,95,114,101,115,111,117,114,99,101, + 95,114,101,97,100,101,114,41,13,114,150,0,0,0,114,149, + 0,0,0,114,151,0,0,0,114,152,0,0,0,114,236,0, + 0,0,114,16,1,0,0,114,22,1,0,0,114,160,0,0, + 0,114,248,0,0,0,114,203,0,0,0,114,255,0,0,0, + 114,33,1,0,0,90,13,95,95,99,108,97,115,115,99,101, + 108,108,95,95,114,7,0,0,0,114,7,0,0,0,114,25, + 1,0,0,114,8,0,0,0,114,11,1,0,0,11,4,0, + 0,115,24,0,0,0,8,0,4,2,8,3,8,6,8,4, + 2,3,14,1,2,11,10,1,8,4,2,9,18,1,114,11, + 1,0,0,99,0,0,0,0,0,0,0,0,0,0,0,0, + 0,0,0,0,3,0,0,0,64,0,0,0,115,46,0,0, + 0,101,0,90,1,100,0,90,2,100,1,90,3,100,2,100, + 3,132,0,90,4,100,4,100,5,132,0,90,5,100,6,100, + 7,156,1,100,8,100,9,132,2,90,6,100,10,83,0,41, + 11,218,16,83,111,117,114,99,101,70,105,108,101,76,111,97, + 100,101,114,122,62,67,111,110,99,114,101,116,101,32,105,109, + 112,108,101,109,101,110,116,97,116,105,111,110,32,111,102,32, + 83,111,117,114,99,101,76,111,97,100,101,114,32,117,115,105, + 110,103,32,116,104,101,32,102,105,108,101,32,115,121,115,116, + 101,109,46,99,2,0,0,0,0,0,0,0,0,0,0,0, + 3,0,0,0,3,0,0,0,67,0,0,0,115,22,0,0, + 0,116,0,124,1,131,1,125,2,124,2,106,1,124,2,106, + 2,100,1,156,2,83,0,41,2,122,33,82,101,116,117,114, + 110,32,116,104,101,32,109,101,116,97,100,97,116,97,32,102, + 111,114,32,116,104,101,32,112,97,116,104,46,41,2,114,193, + 0,0,0,114,6,1,0,0,41,3,114,75,0,0,0,218, + 8,115,116,95,109,116,105,109,101,90,7,115,116,95,115,105, + 122,101,41,3,114,143,0,0,0,114,65,0,0,0,114,10, + 1,0,0,114,7,0,0,0,114,7,0,0,0,114,8,0, + 0,0,114,252,0,0,0,65,4,0,0,115,4,0,0,0, + 8,2,14,1,122,27,83,111,117,114,99,101,70,105,108,101, + 76,111,97,100,101,114,46,112,97,116,104,95,115,116,97,116, + 115,99,4,0,0,0,0,0,0,0,0,0,0,0,5,0, + 0,0,5,0,0,0,67,0,0,0,115,24,0,0,0,116, + 0,124,1,131,1,125,4,124,0,106,1,124,2,124,3,124, + 4,100,1,141,3,83,0,41,2,78,169,1,218,5,95,109, + 111,100,101,41,2,114,139,0,0,0,114,253,0,0,0,41, + 5,114,143,0,0,0,114,134,0,0,0,114,132,0,0,0, + 114,41,0,0,0,114,78,0,0,0,114,7,0,0,0,114, + 7,0,0,0,114,8,0,0,0,114,254,0,0,0,70,4, + 0,0,115,4,0,0,0,8,2,16,1,122,32,83,111,117, + 114,99,101,70,105,108,101,76,111,97,100,101,114,46,95,99, + 97,99,104,101,95,98,121,116,101,99,111,100,101,114,87,0, + 0,0,114,36,1,0,0,99,3,0,0,0,0,0,0,0, + 1,0,0,0,9,0,0,0,11,0,0,0,67,0,0,0, + 115,254,0,0,0,116,0,124,1,131,1,92,2,125,4,125, + 5,103,0,125,6,124,4,114,31,116,1,124,4,131,1,115, + 31,116,0,124,4,131,1,92,2,125,4,125,7,124,6,160, + 2,124,7,161,1,1,0,124,4,114,31,116,1,124,4,131, + 1,114,14,116,3,124,6,131,1,68,0,93,49,125,7,116, + 4,124,4,124,7,131,2,125,4,122,7,116,5,160,6,124, + 4,161,1,1,0,87,0,113,35,4,0,116,7,121,58,1, + 0,1,0,1,0,89,0,113,35,4,0,116,8,121,84,1, + 0,125,8,1,0,122,15,116,9,160,10,100,1,124,4,124, + 8,161,3,1,0,87,0,89,0,100,2,125,8,126,8,1, + 0,100,2,83,0,100,2,125,8,126,8,119,1,119,0,122, + 15,116,11,124,1,124,2,124,3,131,3,1,0,116,9,160, + 10,100,3,124,1,161,2,1,0,87,0,100,2,83,0,4, + 0,116,8,121,126,1,0,125,8,1,0,122,14,116,9,160, + 10,100,1,124,1,124,8,161,3,1,0,87,0,89,0,100, + 2,125,8,126,8,100,2,83,0,100,2,125,8,126,8,119, + 1,119,0,41,4,122,27,87,114,105,116,101,32,98,121,116, + 101,115,32,100,97,116,97,32,116,111,32,97,32,102,105,108, + 101,46,122,27,99,111,117,108,100,32,110,111,116,32,99,114, + 101,97,116,101,32,123,33,114,125,58,32,123,33,114,125,78, + 122,12,99,114,101,97,116,101,100,32,123,33,114,125,41,12, + 114,74,0,0,0,114,83,0,0,0,114,61,0,0,0,218, + 8,114,101,118,101,114,115,101,100,114,67,0,0,0,114,18, + 0,0,0,90,5,109,107,100,105,114,218,15,70,105,108,101, + 69,120,105,115,116,115,69,114,114,111,114,114,76,0,0,0, + 114,159,0,0,0,114,173,0,0,0,114,95,0,0,0,41, + 9,114,143,0,0,0,114,65,0,0,0,114,41,0,0,0, + 114,37,1,0,0,218,6,112,97,114,101,110,116,114,120,0, + 0,0,114,63,0,0,0,114,68,0,0,0,114,0,1,0, + 0,114,7,0,0,0,114,7,0,0,0,114,8,0,0,0, + 114,253,0,0,0,75,4,0,0,115,56,0,0,0,12,2, + 4,1,12,2,12,1,10,1,12,254,12,4,10,1,2,1, + 14,1,12,1,4,2,14,1,6,3,4,1,4,255,16,2, + 8,128,2,251,2,6,12,1,18,1,14,1,8,2,2,1, + 18,255,8,128,2,254,122,25,83,111,117,114,99,101,70,105, + 108,101,76,111,97,100,101,114,46,115,101,116,95,100,97,116, + 97,78,41,7,114,150,0,0,0,114,149,0,0,0,114,151, + 0,0,0,114,152,0,0,0,114,252,0,0,0,114,254,0, + 0,0,114,253,0,0,0,114,7,0,0,0,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,114,34,1,0,0, + 61,4,0,0,115,10,0,0,0,8,0,4,2,8,2,8, + 5,18,5,114,34,1,0,0,99,0,0,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,2,0,0,0,64,0,0, + 0,115,32,0,0,0,101,0,90,1,100,0,90,2,100,1, + 90,3,100,2,100,3,132,0,90,4,100,4,100,5,132,0, + 90,5,100,6,83,0,41,7,218,20,83,111,117,114,99,101, + 108,101,115,115,70,105,108,101,76,111,97,100,101,114,122,45, + 76,111,97,100,101,114,32,119,104,105,99,104,32,104,97,110, + 100,108,101,115,32,115,111,117,114,99,101,108,101,115,115,32, + 102,105,108,101,32,105,109,112,111,114,116,115,46,99,2,0, + 0,0,0,0,0,0,0,0,0,0,5,0,0,0,5,0, + 0,0,67,0,0,0,115,68,0,0,0,124,0,160,0,124, + 1,161,1,125,2,124,0,160,1,124,2,161,1,125,3,124, + 1,124,2,100,1,156,2,125,4,116,2,124,3,124,1,124, + 4,131,3,1,0,116,3,116,4,124,3,131,1,100,2,100, + 0,133,2,25,0,124,1,124,2,100,3,141,3,83,0,41, + 4,78,114,183,0,0,0,114,169,0,0,0,41,2,114,141, + 0,0,0,114,132,0,0,0,41,5,114,203,0,0,0,114, + 255,0,0,0,114,176,0,0,0,114,189,0,0,0,114,7, + 1,0,0,41,5,114,143,0,0,0,114,163,0,0,0,114, + 65,0,0,0,114,41,0,0,0,114,175,0,0,0,114,7, + 0,0,0,114,7,0,0,0,114,8,0,0,0,114,241,0, + 0,0,110,4,0,0,115,22,0,0,0,10,1,10,1,2, + 4,2,1,6,254,12,4,2,1,14,1,2,1,2,1,6, + 253,122,29,83,111,117,114,99,101,108,101,115,115,70,105,108, + 101,76,111,97,100,101,114,46,103,101,116,95,99,111,100,101, + 99,2,0,0,0,0,0,0,0,0,0,0,0,2,0,0, + 0,1,0,0,0,67,0,0,0,114,23,0,0,0,41,2, + 122,39,82,101,116,117,114,110,32,78,111,110,101,32,97,115, + 32,116,104,101,114,101,32,105,115,32,110,111,32,115,111,117, + 114,99,101,32,99,111,100,101,46,78,114,7,0,0,0,114, + 247,0,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,114,1,1,0,0,126,4,0,0,114,24,0,0, + 0,122,31,83,111,117,114,99,101,108,101,115,115,70,105,108, + 101,76,111,97,100,101,114,46,103,101,116,95,115,111,117,114, + 99,101,78,41,6,114,150,0,0,0,114,149,0,0,0,114, + 151,0,0,0,114,152,0,0,0,114,241,0,0,0,114,1, + 1,0,0,114,7,0,0,0,114,7,0,0,0,114,7,0, + 0,0,114,8,0,0,0,114,41,1,0,0,106,4,0,0, + 115,8,0,0,0,8,0,4,2,8,2,12,16,114,41,1, + 0,0,99,0,0,0,0,0,0,0,0,0,0,0,0,0, + 0,0,0,3,0,0,0,64,0,0,0,115,92,0,0,0, + 101,0,90,1,100,0,90,2,100,1,90,3,100,2,100,3, + 132,0,90,4,100,4,100,5,132,0,90,5,100,6,100,7, + 132,0,90,6,100,8,100,9,132,0,90,7,100,10,100,11, + 132,0,90,8,100,12,100,13,132,0,90,9,100,14,100,15, + 132,0,90,10,100,16,100,17,132,0,90,11,101,12,100,18, + 100,19,132,0,131,1,90,13,100,20,83,0,41,21,114,30, + 1,0,0,122,93,76,111,97,100,101,114,32,102,111,114,32, 101,120,116,101,110,115,105,111,110,32,109,111,100,117,108,101, - 32,123,33,114,125,32,101,120,101,99,117,116,101,100,32,102, - 114,111,109,32,123,33,114,125,78,41,7,114,158,0,0,0, - 114,237,0,0,0,114,187,0,0,0,90,12,101,120,101,99, - 95,100,121,110,97,109,105,99,114,173,0,0,0,114,140,0, - 0,0,114,65,0,0,0,114,20,1,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,114,240,0,0,0, - 155,4,0,0,115,8,0,0,0,0,2,14,1,6,1,8, - 255,122,31,69,120,116,101,110,115,105,111,110,70,105,108,101, - 76,111,97,100,101,114,46,101,120,101,99,95,109,111,100,117, - 108,101,99,2,0,0,0,0,0,0,0,0,0,0,0,2, - 0,0,0,4,0,0,0,3,0,0,0,115,36,0,0,0, - 116,0,124,0,106,1,131,1,100,1,25,0,137,0,116,2, - 135,0,102,1,100,2,100,3,132,8,116,3,68,0,131,1, - 131,1,83,0,41,4,122,49,82,101,116,117,114,110,32,84, - 114,117,101,32,105,102,32,116,104,101,32,101,120,116,101,110, - 115,105,111,110,32,109,111,100,117,108,101,32,105,115,32,97, - 32,112,97,99,107,97,103,101,46,114,4,0,0,0,99,1, - 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,4, - 0,0,0,51,0,0,0,115,26,0,0,0,124,0,93,18, - 125,1,136,0,100,0,124,1,23,0,107,2,86,0,1,0, - 113,2,100,1,83,0,41,2,114,232,0,0,0,78,114,10, - 0,0,0,169,2,114,8,0,0,0,218,6,115,117,102,102, - 105,120,169,1,90,9,102,105,108,101,95,110,97,109,101,114, - 10,0,0,0,114,11,0,0,0,114,12,0,0,0,164,4, - 0,0,115,4,0,0,0,4,1,2,255,122,49,69,120,116, - 101,110,115,105,111,110,70,105,108,101,76,111,97,100,101,114, - 46,105,115,95,112,97,99,107,97,103,101,46,60,108,111,99, - 97,108,115,62,46,60,103,101,110,101,120,112,114,62,41,4, - 114,74,0,0,0,114,65,0,0,0,218,3,97,110,121,218, - 18,69,88,84,69,78,83,73,79,78,95,83,85,70,70,73, - 88,69,83,114,242,0,0,0,114,10,0,0,0,114,42,1, - 0,0,114,11,0,0,0,114,206,0,0,0,161,4,0,0, - 115,8,0,0,0,0,2,14,1,12,1,2,255,122,30,69, - 120,116,101,110,115,105,111,110,70,105,108,101,76,111,97,100, - 101,114,46,105,115,95,112,97,99,107,97,103,101,99,2,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,1,0, - 0,0,67,0,0,0,115,4,0,0,0,100,1,83,0,41, - 2,122,63,82,101,116,117,114,110,32,78,111,110,101,32,97, - 115,32,97,110,32,101,120,116,101,110,115,105,111,110,32,109, - 111,100,117,108,101,32,99,97,110,110,111,116,32,99,114,101, - 97,116,101,32,97,32,99,111,100,101,32,111,98,106,101,99, - 116,46,78,114,10,0,0,0,114,242,0,0,0,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,114,236,0,0, - 0,167,4,0,0,115,2,0,0,0,0,2,122,28,69,120, + 115,46,10,10,32,32,32,32,84,104,101,32,99,111,110,115, + 116,114,117,99,116,111,114,32,105,115,32,100,101,115,105,103, + 110,101,100,32,116,111,32,119,111,114,107,32,119,105,116,104, + 32,70,105,108,101,70,105,110,100,101,114,46,10,10,32,32, + 32,32,99,3,0,0,0,0,0,0,0,0,0,0,0,3, + 0,0,0,2,0,0,0,67,0,0,0,115,16,0,0,0, + 124,1,124,0,95,0,124,2,124,0,95,1,100,0,83,0, + 114,69,0,0,0,114,183,0,0,0,41,3,114,143,0,0, + 0,114,141,0,0,0,114,65,0,0,0,114,7,0,0,0, + 114,7,0,0,0,114,8,0,0,0,114,236,0,0,0,139, + 4,0,0,115,4,0,0,0,6,1,10,1,122,28,69,120, 116,101,110,115,105,111,110,70,105,108,101,76,111,97,100,101, - 114,46,103,101,116,95,99,111,100,101,99,2,0,0,0,0, - 0,0,0,0,0,0,0,2,0,0,0,1,0,0,0,67, - 0,0,0,115,4,0,0,0,100,1,83,0,41,2,122,53, - 82,101,116,117,114,110,32,78,111,110,101,32,97,115,32,101, - 120,116,101,110,115,105,111,110,32,109,111,100,117,108,101,115, - 32,104,97,118,101,32,110,111,32,115,111,117,114,99,101,32, - 99,111,100,101,46,78,114,10,0,0,0,114,242,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,114, - 252,0,0,0,171,4,0,0,115,2,0,0,0,0,2,122, - 30,69,120,116,101,110,115,105,111,110,70,105,108,101,76,111, - 97,100,101,114,46,103,101,116,95,115,111,117,114,99,101,99, - 2,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0, - 1,0,0,0,67,0,0,0,115,6,0,0,0,124,0,106, - 0,83,0,114,17,1,0,0,114,71,0,0,0,114,242,0, - 0,0,114,10,0,0,0,114,10,0,0,0,114,11,0,0, - 0,114,203,0,0,0,175,4,0,0,115,2,0,0,0,0, - 3,122,32,69,120,116,101,110,115,105,111,110,70,105,108,101, - 76,111,97,100,101,114,46,103,101,116,95,102,105,108,101,110, - 97,109,101,78,41,14,114,149,0,0,0,114,148,0,0,0, - 114,150,0,0,0,114,151,0,0,0,114,232,0,0,0,114, - 10,1,0,0,114,14,1,0,0,114,235,0,0,0,114,240, - 0,0,0,114,206,0,0,0,114,236,0,0,0,114,252,0, - 0,0,114,160,0,0,0,114,203,0,0,0,114,10,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,11,0,0,0, - 114,19,1,0,0,123,4,0,0,115,22,0,0,0,8,2, - 4,6,8,9,8,4,8,3,8,8,8,6,8,6,8,4, - 8,4,2,1,114,19,1,0,0,99,0,0,0,0,0,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,64,0, - 0,0,115,108,0,0,0,101,0,90,1,100,0,90,2,100, - 1,90,3,100,2,90,4,100,3,100,4,132,0,90,5,100, - 5,100,6,132,0,90,6,100,7,100,8,132,0,90,7,100, - 9,100,10,132,0,90,8,100,11,100,12,132,0,90,9,100, - 13,100,14,132,0,90,10,100,15,100,16,132,0,90,11,100, - 17,100,18,132,0,90,12,100,19,100,20,132,0,90,13,100, - 21,100,22,132,0,90,14,100,23,100,24,132,0,90,15,100, - 25,83,0,41,26,218,14,95,78,97,109,101,115,112,97,99, - 101,80,97,116,104,97,38,1,0,0,82,101,112,114,101,115, - 101,110,116,115,32,97,32,110,97,109,101,115,112,97,99,101, - 32,112,97,99,107,97,103,101,39,115,32,112,97,116,104,46, - 32,32,73,116,32,117,115,101,115,32,116,104,101,32,109,111, - 100,117,108,101,32,110,97,109,101,10,32,32,32,32,116,111, - 32,102,105,110,100,32,105,116,115,32,112,97,114,101,110,116, - 32,109,111,100,117,108,101,44,32,97,110,100,32,102,114,111, - 109,32,116,104,101,114,101,32,105,116,32,108,111,111,107,115, - 32,117,112,32,116,104,101,32,112,97,114,101,110,116,39,115, - 10,32,32,32,32,95,95,112,97,116,104,95,95,46,32,32, - 87,104,101,110,32,116,104,105,115,32,99,104,97,110,103,101, - 115,44,32,116,104,101,32,109,111,100,117,108,101,39,115,32, - 111,119,110,32,112,97,116,104,32,105,115,32,114,101,99,111, - 109,112,117,116,101,100,44,10,32,32,32,32,117,115,105,110, - 103,32,112,97,116,104,95,102,105,110,100,101,114,46,32,32, - 70,111,114,32,116,111,112,45,108,101,118,101,108,32,109,111, - 100,117,108,101,115,44,32,116,104,101,32,112,97,114,101,110, - 116,32,109,111,100,117,108,101,39,115,32,112,97,116,104,10, - 32,32,32,32,105,115,32,115,121,115,46,112,97,116,104,46, - 114,0,0,0,0,99,4,0,0,0,0,0,0,0,0,0, - 0,0,4,0,0,0,3,0,0,0,67,0,0,0,115,44, - 0,0,0,124,1,124,0,95,0,124,2,124,0,95,1,116, - 2,124,0,160,3,161,0,131,1,124,0,95,4,124,0,106, - 5,124,0,95,6,124,3,124,0,95,7,100,0,83,0,114, - 69,0,0,0,41,8,218,5,95,110,97,109,101,218,5,95, - 112,97,116,104,114,135,0,0,0,218,16,95,103,101,116,95, - 112,97,114,101,110,116,95,112,97,116,104,218,17,95,108,97, - 115,116,95,112,97,114,101,110,116,95,112,97,116,104,218,6, - 95,101,112,111,99,104,218,11,95,108,97,115,116,95,101,112, - 111,99,104,218,12,95,112,97,116,104,95,102,105,110,100,101, - 114,169,4,114,142,0,0,0,114,140,0,0,0,114,65,0, - 0,0,90,11,112,97,116,104,95,102,105,110,100,101,114,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,114,232, - 0,0,0,192,4,0,0,115,10,0,0,0,0,1,6,1, - 6,1,14,1,8,1,122,23,95,78,97,109,101,115,112,97, - 99,101,80,97,116,104,46,95,95,105,110,105,116,95,95,99, - 1,0,0,0,0,0,0,0,0,0,0,0,4,0,0,0, - 3,0,0,0,67,0,0,0,115,38,0,0,0,124,0,106, - 0,160,1,100,1,161,1,92,3,125,1,125,2,125,3,124, - 2,100,2,107,2,114,30,100,3,83,0,124,1,100,4,102, - 2,83,0,41,5,122,62,82,101,116,117,114,110,115,32,97, - 32,116,117,112,108,101,32,111,102,32,40,112,97,114,101,110, - 116,45,109,111,100,117,108,101,45,110,97,109,101,44,32,112, - 97,114,101,110,116,45,112,97,116,104,45,97,116,116,114,45, - 110,97,109,101,41,114,96,0,0,0,114,14,0,0,0,41, - 2,114,21,0,0,0,114,65,0,0,0,90,8,95,95,112, - 97,116,104,95,95,41,2,114,46,1,0,0,114,103,0,0, - 0,41,4,114,142,0,0,0,114,38,1,0,0,218,3,100, - 111,116,90,2,109,101,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,23,95,102,105,110,100,95,112,97,114, - 101,110,116,95,112,97,116,104,95,110,97,109,101,115,199,4, - 0,0,115,8,0,0,0,0,2,18,1,8,2,4,3,122, - 38,95,78,97,109,101,115,112,97,99,101,80,97,116,104,46, - 95,102,105,110,100,95,112,97,114,101,110,116,95,112,97,116, - 104,95,110,97,109,101,115,99,1,0,0,0,0,0,0,0, - 0,0,0,0,3,0,0,0,3,0,0,0,67,0,0,0, - 115,28,0,0,0,124,0,160,0,161,0,92,2,125,1,125, - 2,116,1,116,2,106,3,124,1,25,0,124,2,131,2,83, - 0,114,69,0,0,0,41,4,114,55,1,0,0,114,154,0, - 0,0,114,21,0,0,0,218,7,109,111,100,117,108,101,115, - 41,3,114,142,0,0,0,90,18,112,97,114,101,110,116,95, - 109,111,100,117,108,101,95,110,97,109,101,90,14,112,97,116, - 104,95,97,116,116,114,95,110,97,109,101,114,10,0,0,0, - 114,10,0,0,0,114,11,0,0,0,114,48,1,0,0,209, - 4,0,0,115,4,0,0,0,0,1,12,1,122,31,95,78, - 97,109,101,115,112,97,99,101,80,97,116,104,46,95,103,101, - 116,95,112,97,114,101,110,116,95,112,97,116,104,99,1,0, - 0,0,0,0,0,0,0,0,0,0,3,0,0,0,4,0, - 0,0,67,0,0,0,115,100,0,0,0,116,0,124,0,160, - 1,161,0,131,1,125,1,124,1,124,0,106,2,107,3,115, - 34,124,0,106,3,124,0,106,4,107,3,114,94,124,0,160, - 5,124,0,106,6,124,1,161,2,125,2,124,2,100,0,117, - 1,114,80,124,2,106,7,100,0,117,0,114,80,124,2,106, - 8,114,80,124,2,106,8,124,0,95,9,124,1,124,0,95, - 2,124,0,106,3,124,0,95,4,124,0,106,9,83,0,114, - 69,0,0,0,41,10,114,135,0,0,0,114,48,1,0,0, - 114,49,1,0,0,114,50,1,0,0,114,51,1,0,0,114, - 52,1,0,0,114,46,1,0,0,114,164,0,0,0,114,202, - 0,0,0,114,47,1,0,0,41,3,114,142,0,0,0,90, - 11,112,97,114,101,110,116,95,112,97,116,104,114,210,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,11,0,0,0, - 218,12,95,114,101,99,97,108,99,117,108,97,116,101,213,4, - 0,0,115,18,0,0,0,0,2,12,1,22,1,14,3,18, - 1,6,1,8,1,6,1,8,1,122,27,95,78,97,109,101, - 115,112,97,99,101,80,97,116,104,46,95,114,101,99,97,108, - 99,117,108,97,116,101,99,1,0,0,0,0,0,0,0,0, - 0,0,0,1,0,0,0,3,0,0,0,67,0,0,0,115, - 12,0,0,0,116,0,124,0,160,1,161,0,131,1,83,0, - 114,69,0,0,0,41,2,114,29,1,0,0,114,57,1,0, - 0,114,13,1,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,8,95,95,105,116,101,114,95,95,227, - 4,0,0,115,2,0,0,0,0,1,122,23,95,78,97,109, - 101,115,112,97,99,101,80,97,116,104,46,95,95,105,116,101, - 114,95,95,99,2,0,0,0,0,0,0,0,0,0,0,0, - 2,0,0,0,2,0,0,0,67,0,0,0,115,12,0,0, - 0,124,0,160,0,161,0,124,1,25,0,83,0,114,69,0, - 0,0,169,1,114,57,1,0,0,41,2,114,142,0,0,0, - 218,5,105,110,100,101,120,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,218,11,95,95,103,101,116,105,116,101, - 109,95,95,230,4,0,0,115,2,0,0,0,0,1,122,26, - 95,78,97,109,101,115,112,97,99,101,80,97,116,104,46,95, - 95,103,101,116,105,116,101,109,95,95,99,3,0,0,0,0, - 0,0,0,0,0,0,0,3,0,0,0,3,0,0,0,67, - 0,0,0,115,14,0,0,0,124,2,124,0,106,0,124,1, - 60,0,100,0,83,0,114,69,0,0,0,41,1,114,47,1, - 0,0,41,3,114,142,0,0,0,114,60,1,0,0,114,65, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,218,11,95,95,115,101,116,105,116,101,109,95,95,233, - 4,0,0,115,2,0,0,0,0,1,122,26,95,78,97,109, - 101,115,112,97,99,101,80,97,116,104,46,95,95,115,101,116, - 105,116,101,109,95,95,99,1,0,0,0,0,0,0,0,0, - 0,0,0,1,0,0,0,3,0,0,0,67,0,0,0,115, - 12,0,0,0,116,0,124,0,160,1,161,0,131,1,83,0, - 114,69,0,0,0,41,2,114,6,0,0,0,114,57,1,0, - 0,114,13,1,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,218,7,95,95,108,101,110,95,95,236,4, - 0,0,115,2,0,0,0,0,1,122,22,95,78,97,109,101, - 115,112,97,99,101,80,97,116,104,46,95,95,108,101,110,95, - 95,99,1,0,0,0,0,0,0,0,0,0,0,0,1,0, - 0,0,3,0,0,0,67,0,0,0,115,12,0,0,0,100, - 1,160,0,124,0,106,1,161,1,83,0,41,2,78,122,20, - 95,78,97,109,101,115,112,97,99,101,80,97,116,104,40,123, - 33,114,125,41,41,2,114,88,0,0,0,114,47,1,0,0, - 114,13,1,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,8,95,95,114,101,112,114,95,95,239,4, - 0,0,115,2,0,0,0,0,1,122,23,95,78,97,109,101, - 115,112,97,99,101,80,97,116,104,46,95,95,114,101,112,114, + 114,46,95,95,105,110,105,116,95,95,99,2,0,0,0,0, + 0,0,0,0,0,0,0,2,0,0,0,2,0,0,0,67, + 0,0,0,114,12,1,0,0,114,69,0,0,0,114,13,1, + 0,0,114,15,1,0,0,114,7,0,0,0,114,7,0,0, + 0,114,8,0,0,0,114,16,1,0,0,143,4,0,0,114, + 17,1,0,0,122,26,69,120,116,101,110,115,105,111,110,70, + 105,108,101,76,111,97,100,101,114,46,95,95,101,113,95,95, + 99,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0, + 0,3,0,0,0,67,0,0,0,114,18,1,0,0,114,69, + 0,0,0,114,19,1,0,0,114,21,1,0,0,114,7,0, + 0,0,114,7,0,0,0,114,8,0,0,0,114,22,1,0, + 0,147,4,0,0,114,23,1,0,0,122,28,69,120,116,101, + 110,115,105,111,110,70,105,108,101,76,111,97,100,101,114,46, + 95,95,104,97,115,104,95,95,99,2,0,0,0,0,0,0, + 0,0,0,0,0,3,0,0,0,5,0,0,0,67,0,0, + 0,115,36,0,0,0,116,0,160,1,116,2,106,3,124,1, + 161,2,125,2,116,0,160,4,100,1,124,1,106,5,124,0, + 106,6,161,3,1,0,124,2,83,0,41,2,122,38,67,114, + 101,97,116,101,32,97,110,32,117,110,105,116,105,97,108,105, + 122,101,100,32,101,120,116,101,110,115,105,111,110,32,109,111, + 100,117,108,101,122,38,101,120,116,101,110,115,105,111,110,32, + 109,111,100,117,108,101,32,123,33,114,125,32,108,111,97,100, + 101,100,32,102,114,111,109,32,123,33,114,125,41,7,114,159, + 0,0,0,114,242,0,0,0,114,187,0,0,0,90,14,99, + 114,101,97,116,101,95,100,121,110,97,109,105,99,114,173,0, + 0,0,114,141,0,0,0,114,65,0,0,0,41,3,114,143, + 0,0,0,114,210,0,0,0,114,244,0,0,0,114,7,0, + 0,0,114,7,0,0,0,114,8,0,0,0,114,239,0,0, + 0,150,4,0,0,115,14,0,0,0,4,2,6,1,4,255, + 6,2,8,1,4,255,4,2,122,33,69,120,116,101,110,115, + 105,111,110,70,105,108,101,76,111,97,100,101,114,46,99,114, + 101,97,116,101,95,109,111,100,117,108,101,99,2,0,0,0, + 0,0,0,0,0,0,0,0,2,0,0,0,5,0,0,0, + 67,0,0,0,115,36,0,0,0,116,0,160,1,116,2,106, + 3,124,1,161,2,1,0,116,0,160,4,100,1,124,0,106, + 5,124,0,106,6,161,3,1,0,100,2,83,0,41,3,122, + 30,73,110,105,116,105,97,108,105,122,101,32,97,110,32,101, + 120,116,101,110,115,105,111,110,32,109,111,100,117,108,101,122, + 40,101,120,116,101,110,115,105,111,110,32,109,111,100,117,108, + 101,32,123,33,114,125,32,101,120,101,99,117,116,101,100,32, + 102,114,111,109,32,123,33,114,125,78,41,7,114,159,0,0, + 0,114,242,0,0,0,114,187,0,0,0,90,12,101,120,101, + 99,95,100,121,110,97,109,105,99,114,173,0,0,0,114,141, + 0,0,0,114,65,0,0,0,169,2,114,143,0,0,0,114, + 244,0,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,114,245,0,0,0,158,4,0,0,115,8,0,0, + 0,14,2,6,1,8,1,8,255,122,31,69,120,116,101,110, + 115,105,111,110,70,105,108,101,76,111,97,100,101,114,46,101, + 120,101,99,95,109,111,100,117,108,101,99,2,0,0,0,0, + 0,0,0,0,0,0,0,2,0,0,0,4,0,0,0,3, + 0,0,0,115,36,0,0,0,116,0,124,0,106,1,131,1, + 100,1,25,0,137,0,116,2,135,0,102,1,100,2,100,3, + 132,8,116,3,68,0,131,1,131,1,83,0,41,4,122,49, + 82,101,116,117,114,110,32,84,114,117,101,32,105,102,32,116, + 104,101,32,101,120,116,101,110,115,105,111,110,32,109,111,100, + 117,108,101,32,105,115,32,97,32,112,97,99,107,97,103,101, + 46,114,3,0,0,0,99,1,0,0,0,0,0,0,0,0, + 0,0,0,2,0,0,0,4,0,0,0,51,0,0,0,115, + 28,0,0,0,129,0,124,0,93,9,125,1,136,0,100,0, + 124,1,23,0,107,2,86,0,1,0,113,2,100,1,83,0, + 41,2,114,236,0,0,0,78,114,7,0,0,0,169,2,114, + 5,0,0,0,218,6,115,117,102,102,105,120,169,1,90,9, + 102,105,108,101,95,110,97,109,101,114,7,0,0,0,114,8, + 0,0,0,114,9,0,0,0,167,4,0,0,115,8,0,0, + 0,2,128,4,0,2,1,20,255,122,49,69,120,116,101,110, + 115,105,111,110,70,105,108,101,76,111,97,100,101,114,46,105, + 115,95,112,97,99,107,97,103,101,46,60,108,111,99,97,108, + 115,62,46,60,103,101,110,101,120,112,114,62,41,4,114,74, + 0,0,0,114,65,0,0,0,218,3,97,110,121,114,232,0, + 0,0,114,247,0,0,0,114,7,0,0,0,114,45,1,0, + 0,114,8,0,0,0,114,206,0,0,0,164,4,0,0,115, + 8,0,0,0,14,2,12,1,2,1,8,255,122,30,69,120, + 116,101,110,115,105,111,110,70,105,108,101,76,111,97,100,101, + 114,46,105,115,95,112,97,99,107,97,103,101,99,2,0,0, + 0,0,0,0,0,0,0,0,0,2,0,0,0,1,0,0, + 0,67,0,0,0,114,23,0,0,0,41,2,122,63,82,101, + 116,117,114,110,32,78,111,110,101,32,97,115,32,97,110,32, + 101,120,116,101,110,115,105,111,110,32,109,111,100,117,108,101, + 32,99,97,110,110,111,116,32,99,114,101,97,116,101,32,97, + 32,99,111,100,101,32,111,98,106,101,99,116,46,78,114,7, + 0,0,0,114,247,0,0,0,114,7,0,0,0,114,7,0, + 0,0,114,8,0,0,0,114,241,0,0,0,170,4,0,0, + 114,24,0,0,0,122,28,69,120,116,101,110,115,105,111,110, + 70,105,108,101,76,111,97,100,101,114,46,103,101,116,95,99, + 111,100,101,99,2,0,0,0,0,0,0,0,0,0,0,0, + 2,0,0,0,1,0,0,0,67,0,0,0,114,23,0,0, + 0,41,2,122,53,82,101,116,117,114,110,32,78,111,110,101, + 32,97,115,32,101,120,116,101,110,115,105,111,110,32,109,111, + 100,117,108,101,115,32,104,97,118,101,32,110,111,32,115,111, + 117,114,99,101,32,99,111,100,101,46,78,114,7,0,0,0, + 114,247,0,0,0,114,7,0,0,0,114,7,0,0,0,114, + 8,0,0,0,114,1,1,0,0,174,4,0,0,114,24,0, + 0,0,122,30,69,120,116,101,110,115,105,111,110,70,105,108, + 101,76,111,97,100,101,114,46,103,101,116,95,115,111,117,114, + 99,101,99,2,0,0,0,0,0,0,0,0,0,0,0,2, + 0,0,0,1,0,0,0,67,0,0,0,114,26,1,0,0, + 114,27,1,0,0,114,71,0,0,0,114,247,0,0,0,114, + 7,0,0,0,114,7,0,0,0,114,8,0,0,0,114,203, + 0,0,0,178,4,0,0,114,28,1,0,0,122,32,69,120, + 116,101,110,115,105,111,110,70,105,108,101,76,111,97,100,101, + 114,46,103,101,116,95,102,105,108,101,110,97,109,101,78,41, + 14,114,150,0,0,0,114,149,0,0,0,114,151,0,0,0, + 114,152,0,0,0,114,236,0,0,0,114,16,1,0,0,114, + 22,1,0,0,114,239,0,0,0,114,245,0,0,0,114,206, + 0,0,0,114,241,0,0,0,114,1,1,0,0,114,160,0, + 0,0,114,203,0,0,0,114,7,0,0,0,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,114,30,1,0,0, + 131,4,0,0,115,24,0,0,0,8,0,4,2,8,6,8, + 4,8,4,8,3,8,8,8,6,8,6,8,4,2,4,14, + 1,114,30,1,0,0,99,0,0,0,0,0,0,0,0,0, + 0,0,0,0,0,0,0,2,0,0,0,64,0,0,0,115, + 108,0,0,0,101,0,90,1,100,0,90,2,100,1,90,3, + 100,2,90,4,100,3,100,4,132,0,90,5,100,5,100,6, + 132,0,90,6,100,7,100,8,132,0,90,7,100,9,100,10, + 132,0,90,8,100,11,100,12,132,0,90,9,100,13,100,14, + 132,0,90,10,100,15,100,16,132,0,90,11,100,17,100,18, + 132,0,90,12,100,19,100,20,132,0,90,13,100,21,100,22, + 132,0,90,14,100,23,100,24,132,0,90,15,100,25,83,0, + 41,26,218,14,95,78,97,109,101,115,112,97,99,101,80,97, + 116,104,97,38,1,0,0,82,101,112,114,101,115,101,110,116, + 115,32,97,32,110,97,109,101,115,112,97,99,101,32,112,97, + 99,107,97,103,101,39,115,32,112,97,116,104,46,32,32,73, + 116,32,117,115,101,115,32,116,104,101,32,109,111,100,117,108, + 101,32,110,97,109,101,10,32,32,32,32,116,111,32,102,105, + 110,100,32,105,116,115,32,112,97,114,101,110,116,32,109,111, + 100,117,108,101,44,32,97,110,100,32,102,114,111,109,32,116, + 104,101,114,101,32,105,116,32,108,111,111,107,115,32,117,112, + 32,116,104,101,32,112,97,114,101,110,116,39,115,10,32,32, + 32,32,95,95,112,97,116,104,95,95,46,32,32,87,104,101, + 110,32,116,104,105,115,32,99,104,97,110,103,101,115,44,32, + 116,104,101,32,109,111,100,117,108,101,39,115,32,111,119,110, + 32,112,97,116,104,32,105,115,32,114,101,99,111,109,112,117, + 116,101,100,44,10,32,32,32,32,117,115,105,110,103,32,112, + 97,116,104,95,102,105,110,100,101,114,46,32,32,70,111,114, + 32,116,111,112,45,108,101,118,101,108,32,109,111,100,117,108, + 101,115,44,32,116,104,101,32,112,97,114,101,110,116,32,109, + 111,100,117,108,101,39,115,32,112,97,116,104,10,32,32,32, + 32,105,115,32,115,121,115,46,112,97,116,104,46,114,0,0, + 0,0,99,4,0,0,0,0,0,0,0,0,0,0,0,4, + 0,0,0,3,0,0,0,67,0,0,0,115,44,0,0,0, + 124,1,124,0,95,0,124,2,124,0,95,1,116,2,124,0, + 160,3,161,0,131,1,124,0,95,4,124,0,106,5,124,0, + 95,6,124,3,124,0,95,7,100,0,83,0,114,69,0,0, + 0,41,8,218,5,95,110,97,109,101,218,5,95,112,97,116, + 104,114,136,0,0,0,218,16,95,103,101,116,95,112,97,114, + 101,110,116,95,112,97,116,104,218,17,95,108,97,115,116,95, + 112,97,114,101,110,116,95,112,97,116,104,218,6,95,101,112, + 111,99,104,218,11,95,108,97,115,116,95,101,112,111,99,104, + 218,12,95,112,97,116,104,95,102,105,110,100,101,114,169,4, + 114,143,0,0,0,114,141,0,0,0,114,65,0,0,0,90, + 11,112,97,116,104,95,102,105,110,100,101,114,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,114,236,0,0,0, + 195,4,0,0,115,10,0,0,0,6,1,6,1,14,1,8, + 1,10,1,122,23,95,78,97,109,101,115,112,97,99,101,80, + 97,116,104,46,95,95,105,110,105,116,95,95,99,1,0,0, + 0,0,0,0,0,0,0,0,0,4,0,0,0,3,0,0, + 0,67,0,0,0,115,38,0,0,0,124,0,106,0,160,1, + 100,1,161,1,92,3,125,1,125,2,125,3,124,2,100,2, + 107,2,114,15,100,3,83,0,124,1,100,4,102,2,83,0, + 41,5,122,62,82,101,116,117,114,110,115,32,97,32,116,117, + 112,108,101,32,111,102,32,40,112,97,114,101,110,116,45,109, + 111,100,117,108,101,45,110,97,109,101,44,32,112,97,114,101, + 110,116,45,112,97,116,104,45,97,116,116,114,45,110,97,109, + 101,41,114,97,0,0,0,114,10,0,0,0,41,2,114,15, + 0,0,0,114,65,0,0,0,90,8,95,95,112,97,116,104, + 95,95,41,2,114,48,1,0,0,114,104,0,0,0,41,4, + 114,143,0,0,0,114,40,1,0,0,218,3,100,111,116,90, + 2,109,101,114,7,0,0,0,114,7,0,0,0,114,8,0, + 0,0,218,23,95,102,105,110,100,95,112,97,114,101,110,116, + 95,112,97,116,104,95,110,97,109,101,115,202,4,0,0,115, + 8,0,0,0,18,2,8,1,4,2,8,3,122,38,95,78, + 97,109,101,115,112,97,99,101,80,97,116,104,46,95,102,105, + 110,100,95,112,97,114,101,110,116,95,112,97,116,104,95,110, + 97,109,101,115,99,1,0,0,0,0,0,0,0,0,0,0, + 0,3,0,0,0,3,0,0,0,67,0,0,0,115,28,0, + 0,0,124,0,160,0,161,0,92,2,125,1,125,2,116,1, + 116,2,106,3,124,1,25,0,124,2,131,2,83,0,114,69, + 0,0,0,41,4,114,57,1,0,0,114,155,0,0,0,114, + 15,0,0,0,218,7,109,111,100,117,108,101,115,41,3,114, + 143,0,0,0,90,18,112,97,114,101,110,116,95,109,111,100, + 117,108,101,95,110,97,109,101,90,14,112,97,116,104,95,97, + 116,116,114,95,110,97,109,101,114,7,0,0,0,114,7,0, + 0,0,114,8,0,0,0,114,50,1,0,0,212,4,0,0, + 115,4,0,0,0,12,1,16,1,122,31,95,78,97,109,101, + 115,112,97,99,101,80,97,116,104,46,95,103,101,116,95,112, + 97,114,101,110,116,95,112,97,116,104,99,1,0,0,0,0, + 0,0,0,0,0,0,0,3,0,0,0,4,0,0,0,67, + 0,0,0,115,100,0,0,0,116,0,124,0,160,1,161,0, + 131,1,125,1,124,1,124,0,106,2,107,3,115,17,124,0, + 106,3,124,0,106,4,107,3,114,47,124,0,160,5,124,0, + 106,6,124,1,161,2,125,2,124,2,100,0,117,1,114,40, + 124,2,106,7,100,0,117,0,114,40,124,2,106,8,114,40, + 124,2,106,8,124,0,95,9,124,1,124,0,95,2,124,0, + 106,3,124,0,95,4,124,0,106,9,83,0,114,69,0,0, + 0,41,10,114,136,0,0,0,114,50,1,0,0,114,51,1, + 0,0,114,52,1,0,0,114,53,1,0,0,114,54,1,0, + 0,114,48,1,0,0,114,164,0,0,0,114,202,0,0,0, + 114,49,1,0,0,41,3,114,143,0,0,0,90,11,112,97, + 114,101,110,116,95,112,97,116,104,114,210,0,0,0,114,7, + 0,0,0,114,7,0,0,0,114,8,0,0,0,218,12,95, + 114,101,99,97,108,99,117,108,97,116,101,216,4,0,0,115, + 18,0,0,0,12,2,22,1,14,1,18,3,6,1,8,1, + 6,1,8,1,6,1,122,27,95,78,97,109,101,115,112,97, + 99,101,80,97,116,104,46,95,114,101,99,97,108,99,117,108, + 97,116,101,99,1,0,0,0,0,0,0,0,0,0,0,0, + 1,0,0,0,3,0,0,0,67,0,0,0,243,12,0,0, + 0,116,0,124,0,160,1,161,0,131,1,83,0,114,69,0, + 0,0,41,2,218,4,105,116,101,114,114,59,1,0,0,114, + 21,1,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,218,8,95,95,105,116,101,114,95,95,230,4,0, + 0,243,2,0,0,0,12,1,122,23,95,78,97,109,101,115, + 112,97,99,101,80,97,116,104,46,95,95,105,116,101,114,95, + 95,99,2,0,0,0,0,0,0,0,0,0,0,0,2,0, + 0,0,2,0,0,0,67,0,0,0,115,12,0,0,0,124, + 0,160,0,161,0,124,1,25,0,83,0,114,69,0,0,0, + 169,1,114,59,1,0,0,41,2,114,143,0,0,0,218,5, + 105,110,100,101,120,114,7,0,0,0,114,7,0,0,0,114, + 8,0,0,0,218,11,95,95,103,101,116,105,116,101,109,95, + 95,233,4,0,0,114,63,1,0,0,122,26,95,78,97,109, + 101,115,112,97,99,101,80,97,116,104,46,95,95,103,101,116, + 105,116,101,109,95,95,99,3,0,0,0,0,0,0,0,0, + 0,0,0,3,0,0,0,3,0,0,0,67,0,0,0,115, + 14,0,0,0,124,2,124,0,106,0,124,1,60,0,100,0, + 83,0,114,69,0,0,0,41,1,114,49,1,0,0,41,3, + 114,143,0,0,0,114,65,1,0,0,114,65,0,0,0,114, + 7,0,0,0,114,7,0,0,0,114,8,0,0,0,218,11, + 95,95,115,101,116,105,116,101,109,95,95,236,4,0,0,115, + 2,0,0,0,14,1,122,26,95,78,97,109,101,115,112,97, + 99,101,80,97,116,104,46,95,95,115,101,116,105,116,101,109, + 95,95,99,1,0,0,0,0,0,0,0,0,0,0,0,1, + 0,0,0,3,0,0,0,67,0,0,0,114,60,1,0,0, + 114,69,0,0,0,41,2,114,4,0,0,0,114,59,1,0, + 0,114,21,1,0,0,114,7,0,0,0,114,7,0,0,0, + 114,8,0,0,0,218,7,95,95,108,101,110,95,95,239,4, + 0,0,114,63,1,0,0,122,22,95,78,97,109,101,115,112, + 97,99,101,80,97,116,104,46,95,95,108,101,110,95,95,99, + 1,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0, + 3,0,0,0,67,0,0,0,243,12,0,0,0,100,1,160, + 0,124,0,106,1,161,1,83,0,41,2,78,122,20,95,78, + 97,109,101,115,112,97,99,101,80,97,116,104,40,123,33,114, + 125,41,41,2,114,89,0,0,0,114,49,1,0,0,114,21, + 1,0,0,114,7,0,0,0,114,7,0,0,0,114,8,0, + 0,0,218,8,95,95,114,101,112,114,95,95,242,4,0,0, + 114,63,1,0,0,122,23,95,78,97,109,101,115,112,97,99, + 101,80,97,116,104,46,95,95,114,101,112,114,95,95,99,2, + 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,3, + 0,0,0,67,0,0,0,115,12,0,0,0,124,1,124,0, + 160,0,161,0,118,0,83,0,114,69,0,0,0,114,64,1, + 0,0,169,2,114,143,0,0,0,218,4,105,116,101,109,114, + 7,0,0,0,114,7,0,0,0,114,8,0,0,0,218,12, + 95,95,99,111,110,116,97,105,110,115,95,95,245,4,0,0, + 114,63,1,0,0,122,27,95,78,97,109,101,115,112,97,99, + 101,80,97,116,104,46,95,95,99,111,110,116,97,105,110,115, 95,95,99,2,0,0,0,0,0,0,0,0,0,0,0,2, - 0,0,0,3,0,0,0,67,0,0,0,115,12,0,0,0, - 124,1,124,0,160,0,161,0,118,0,83,0,114,69,0,0, - 0,114,59,1,0,0,169,2,114,142,0,0,0,218,4,105, - 116,101,109,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,218,12,95,95,99,111,110,116,97,105,110,115,95,95, - 242,4,0,0,115,2,0,0,0,0,1,122,27,95,78,97, - 109,101,115,112,97,99,101,80,97,116,104,46,95,95,99,111, - 110,116,97,105,110,115,95,95,99,2,0,0,0,0,0,0, - 0,0,0,0,0,2,0,0,0,3,0,0,0,67,0,0, - 0,115,16,0,0,0,124,0,106,0,160,1,124,1,161,1, - 1,0,100,0,83,0,114,69,0,0,0,41,2,114,47,1, - 0,0,114,61,0,0,0,114,65,1,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,114,61,0,0,0, - 245,4,0,0,115,2,0,0,0,0,1,122,21,95,78,97, - 109,101,115,112,97,99,101,80,97,116,104,46,97,112,112,101, - 110,100,78,41,16,114,149,0,0,0,114,148,0,0,0,114, - 150,0,0,0,114,151,0,0,0,114,50,1,0,0,114,232, - 0,0,0,114,55,1,0,0,114,48,1,0,0,114,57,1, - 0,0,114,58,1,0,0,114,61,1,0,0,114,62,1,0, - 0,114,63,1,0,0,114,64,1,0,0,114,67,1,0,0, - 114,61,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,114,45,1,0,0,181,4, - 0,0,115,26,0,0,0,8,1,4,8,4,2,8,7,8, - 10,8,4,8,14,8,3,8,3,8,3,8,3,8,3,8, - 3,114,45,1,0,0,99,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,0,3,0,0,0,64,0,0,0,115, - 80,0,0,0,101,0,90,1,100,0,90,2,100,1,100,2, - 132,0,90,3,101,4,100,3,100,4,132,0,131,1,90,5, - 100,5,100,6,132,0,90,6,100,7,100,8,132,0,90,7, - 100,9,100,10,132,0,90,8,100,11,100,12,132,0,90,9, - 100,13,100,14,132,0,90,10,100,15,100,16,132,0,90,11, - 100,17,83,0,41,18,218,16,95,78,97,109,101,115,112,97, - 99,101,76,111,97,100,101,114,99,4,0,0,0,0,0,0, - 0,0,0,0,0,4,0,0,0,4,0,0,0,67,0,0, - 0,115,18,0,0,0,116,0,124,1,124,2,124,3,131,3, - 124,0,95,1,100,0,83,0,114,69,0,0,0,41,2,114, - 45,1,0,0,114,47,1,0,0,114,53,1,0,0,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,114,232,0, - 0,0,251,4,0,0,115,2,0,0,0,0,1,122,25,95, - 78,97,109,101,115,112,97,99,101,76,111,97,100,101,114,46, - 95,95,105,110,105,116,95,95,99,2,0,0,0,0,0,0, - 0,0,0,0,0,2,0,0,0,3,0,0,0,67,0,0, - 0,115,12,0,0,0,100,1,160,0,124,1,106,1,161,1, - 83,0,41,2,122,115,82,101,116,117,114,110,32,114,101,112, + 0,0,0,3,0,0,0,67,0,0,0,115,16,0,0,0, + 124,0,106,0,160,1,124,1,161,1,1,0,100,0,83,0, + 114,69,0,0,0,41,2,114,49,1,0,0,114,61,0,0, + 0,114,71,1,0,0,114,7,0,0,0,114,7,0,0,0, + 114,8,0,0,0,114,61,0,0,0,248,4,0,0,243,2, + 0,0,0,16,1,122,21,95,78,97,109,101,115,112,97,99, + 101,80,97,116,104,46,97,112,112,101,110,100,78,41,16,114, + 150,0,0,0,114,149,0,0,0,114,151,0,0,0,114,152, + 0,0,0,114,52,1,0,0,114,236,0,0,0,114,57,1, + 0,0,114,50,1,0,0,114,59,1,0,0,114,62,1,0, + 0,114,66,1,0,0,114,67,1,0,0,114,68,1,0,0, + 114,70,1,0,0,114,73,1,0,0,114,61,0,0,0,114, + 7,0,0,0,114,7,0,0,0,114,7,0,0,0,114,8, + 0,0,0,114,47,1,0,0,184,4,0,0,115,28,0,0, + 0,8,0,4,1,4,8,8,2,8,7,8,10,8,4,8, + 14,8,3,8,3,8,3,8,3,8,3,12,3,114,47,1, + 0,0,99,0,0,0,0,0,0,0,0,0,0,0,0,0, + 0,0,0,3,0,0,0,64,0,0,0,115,88,0,0,0, + 101,0,90,1,100,0,90,2,100,1,100,2,132,0,90,3, + 101,4,100,3,100,4,132,0,131,1,90,5,100,5,100,6, + 132,0,90,6,100,7,100,8,132,0,90,7,100,9,100,10, + 132,0,90,8,100,11,100,12,132,0,90,9,100,13,100,14, + 132,0,90,10,100,15,100,16,132,0,90,11,100,17,100,18, + 132,0,90,12,100,19,83,0,41,20,218,16,95,78,97,109, + 101,115,112,97,99,101,76,111,97,100,101,114,99,4,0,0, + 0,0,0,0,0,0,0,0,0,4,0,0,0,4,0,0, + 0,67,0,0,0,115,18,0,0,0,116,0,124,1,124,2, + 124,3,131,3,124,0,95,1,100,0,83,0,114,69,0,0, + 0,41,2,114,47,1,0,0,114,49,1,0,0,114,55,1, + 0,0,114,7,0,0,0,114,7,0,0,0,114,8,0,0, + 0,114,236,0,0,0,254,4,0,0,115,2,0,0,0,18, + 1,122,25,95,78,97,109,101,115,112,97,99,101,76,111,97, + 100,101,114,46,95,95,105,110,105,116,95,95,99,1,0,0, + 0,0,0,0,0,0,0,0,0,1,0,0,0,4,0,0, + 0,67,0,0,0,115,24,0,0,0,116,0,160,1,100,1, + 116,2,161,2,1,0,100,2,160,3,124,0,106,4,161,1, + 83,0,41,3,122,115,82,101,116,117,114,110,32,114,101,112, 114,32,102,111,114,32,116,104,101,32,109,111,100,117,108,101, 46,10,10,32,32,32,32,32,32,32,32,84,104,101,32,109, 101,116,104,111,100,32,105,115,32,100,101,112,114,101,99,97, 116,101,100,46,32,32,84,104,101,32,105,109,112,111,114,116, 32,109,97,99,104,105,110,101,114,121,32,100,111,101,115,32, 116,104,101,32,106,111,98,32,105,116,115,101,108,102,46,10, - 10,32,32,32,32,32,32,32,32,122,25,60,109,111,100,117, - 108,101,32,123,33,114,125,32,40,110,97,109,101,115,112,97, - 99,101,41,62,41,2,114,88,0,0,0,114,149,0,0,0, - 41,2,114,216,0,0,0,114,239,0,0,0,114,10,0,0, - 0,114,10,0,0,0,114,11,0,0,0,218,11,109,111,100, - 117,108,101,95,114,101,112,114,254,4,0,0,115,2,0,0, - 0,0,7,122,28,95,78,97,109,101,115,112,97,99,101,76, - 111,97,100,101,114,46,109,111,100,117,108,101,95,114,101,112, - 114,99,2,0,0,0,0,0,0,0,0,0,0,0,2,0, - 0,0,1,0,0,0,67,0,0,0,115,4,0,0,0,100, - 1,83,0,41,2,78,84,114,10,0,0,0,114,242,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,11,0,0,0, - 114,206,0,0,0,7,5,0,0,115,2,0,0,0,0,1, + 10,32,32,32,32,32,32,32,32,122,82,95,78,97,109,101, + 115,112,97,99,101,76,111,97,100,101,114,46,109,111,100,117, + 108,101,95,114,101,112,114,40,41,32,105,115,32,100,101,112, + 114,101,99,97,116,101,100,32,97,110,100,32,115,108,97,116, + 101,100,32,102,111,114,32,114,101,109,111,118,97,108,32,105, + 110,32,80,121,116,104,111,110,32,51,46,49,50,122,25,60, + 109,111,100,117,108,101,32,123,33,114,125,32,40,110,97,109, + 101,115,112,97,99,101,41,62,41,5,114,99,0,0,0,114, + 100,0,0,0,114,101,0,0,0,114,89,0,0,0,114,150, + 0,0,0,41,1,114,244,0,0,0,114,7,0,0,0,114, + 7,0,0,0,114,8,0,0,0,218,11,109,111,100,117,108, + 101,95,114,101,112,114,1,5,0,0,115,8,0,0,0,6, + 7,2,1,4,255,12,2,122,28,95,78,97,109,101,115,112, + 97,99,101,76,111,97,100,101,114,46,109,111,100,117,108,101, + 95,114,101,112,114,99,2,0,0,0,0,0,0,0,0,0, + 0,0,2,0,0,0,1,0,0,0,67,0,0,0,114,23, + 0,0,0,41,2,78,84,114,7,0,0,0,114,247,0,0, + 0,114,7,0,0,0,114,7,0,0,0,114,8,0,0,0, + 114,206,0,0,0,12,5,0,0,243,2,0,0,0,4,1, 122,27,95,78,97,109,101,115,112,97,99,101,76,111,97,100, 101,114,46,105,115,95,112,97,99,107,97,103,101,99,2,0, 0,0,0,0,0,0,0,0,0,0,2,0,0,0,1,0, - 0,0,67,0,0,0,115,4,0,0,0,100,1,83,0,41, - 2,78,114,14,0,0,0,114,10,0,0,0,114,242,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,11,0,0,0, - 114,252,0,0,0,10,5,0,0,115,2,0,0,0,0,1, - 122,27,95,78,97,109,101,115,112,97,99,101,76,111,97,100, - 101,114,46,103,101,116,95,115,111,117,114,99,101,99,2,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,6,0, - 0,0,67,0,0,0,115,16,0,0,0,116,0,100,1,100, - 2,100,3,100,4,100,5,141,4,83,0,41,6,78,114,14, - 0,0,0,122,8,60,115,116,114,105,110,103,62,114,238,0, - 0,0,84,41,1,114,254,0,0,0,41,1,114,255,0,0, - 0,114,242,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,236,0,0,0,13,5,0,0,115,2, - 0,0,0,0,1,122,25,95,78,97,109,101,115,112,97,99, - 101,76,111,97,100,101,114,46,103,101,116,95,99,111,100,101, - 99,2,0,0,0,0,0,0,0,0,0,0,0,2,0,0, - 0,1,0,0,0,67,0,0,0,115,4,0,0,0,100,1, - 83,0,114,233,0,0,0,114,10,0,0,0,114,234,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,11,0,0,0, - 114,235,0,0,0,16,5,0,0,115,2,0,0,0,0,1, - 122,30,95,78,97,109,101,115,112,97,99,101,76,111,97,100, - 101,114,46,99,114,101,97,116,101,95,109,111,100,117,108,101, - 99,2,0,0,0,0,0,0,0,0,0,0,0,2,0,0, - 0,1,0,0,0,67,0,0,0,115,4,0,0,0,100,0, - 83,0,114,69,0,0,0,114,10,0,0,0,114,20,1,0, - 0,114,10,0,0,0,114,10,0,0,0,114,11,0,0,0, - 114,240,0,0,0,19,5,0,0,115,2,0,0,0,0,1, + 0,0,67,0,0,0,114,23,0,0,0,41,2,78,114,10, + 0,0,0,114,7,0,0,0,114,247,0,0,0,114,7,0, + 0,0,114,7,0,0,0,114,8,0,0,0,114,1,1,0, + 0,15,5,0,0,114,77,1,0,0,122,27,95,78,97,109, + 101,115,112,97,99,101,76,111,97,100,101,114,46,103,101,116, + 95,115,111,117,114,99,101,99,2,0,0,0,0,0,0,0, + 0,0,0,0,2,0,0,0,6,0,0,0,67,0,0,0, + 115,16,0,0,0,116,0,100,1,100,2,100,3,100,4,100, + 5,141,4,83,0,41,6,78,114,10,0,0,0,122,8,60, + 115,116,114,105,110,103,62,114,243,0,0,0,84,41,1,114, + 3,1,0,0,41,1,114,4,1,0,0,114,247,0,0,0, + 114,7,0,0,0,114,7,0,0,0,114,8,0,0,0,114, + 241,0,0,0,18,5,0,0,114,74,1,0,0,122,25,95, + 78,97,109,101,115,112,97,99,101,76,111,97,100,101,114,46, + 103,101,116,95,99,111,100,101,99,2,0,0,0,0,0,0, + 0,0,0,0,0,2,0,0,0,1,0,0,0,67,0,0, + 0,114,23,0,0,0,114,237,0,0,0,114,7,0,0,0, + 114,238,0,0,0,114,7,0,0,0,114,7,0,0,0,114, + 8,0,0,0,114,239,0,0,0,21,5,0,0,114,240,0, + 0,0,122,30,95,78,97,109,101,115,112,97,99,101,76,111, + 97,100,101,114,46,99,114,101,97,116,101,95,109,111,100,117, + 108,101,99,2,0,0,0,0,0,0,0,0,0,0,0,2, + 0,0,0,1,0,0,0,67,0,0,0,115,4,0,0,0, + 100,0,83,0,114,69,0,0,0,114,7,0,0,0,114,42, + 1,0,0,114,7,0,0,0,114,7,0,0,0,114,8,0, + 0,0,114,245,0,0,0,24,5,0,0,114,77,1,0,0, 122,28,95,78,97,109,101,115,112,97,99,101,76,111,97,100, 101,114,46,101,120,101,99,95,109,111,100,117,108,101,99,2, 0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,4, @@ -2125,249 +2097,282 @@ const unsigned char _Py_M__importlib_bootstrap_external[] = { 100,46,10,10,32,32,32,32,32,32,32,32,122,38,110,97, 109,101,115,112,97,99,101,32,109,111,100,117,108,101,32,108, 111,97,100,101,100,32,119,105,116,104,32,112,97,116,104,32, - 123,33,114,125,41,4,114,158,0,0,0,114,173,0,0,0, - 114,47,1,0,0,114,241,0,0,0,114,242,0,0,0,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,114,243, - 0,0,0,22,5,0,0,115,8,0,0,0,0,7,6,1, - 4,255,4,2,122,28,95,78,97,109,101,115,112,97,99,101, + 123,33,114,125,41,4,114,159,0,0,0,114,173,0,0,0, + 114,49,1,0,0,114,246,0,0,0,114,247,0,0,0,114, + 7,0,0,0,114,7,0,0,0,114,8,0,0,0,114,248, + 0,0,0,27,5,0,0,115,8,0,0,0,6,7,4,1, + 4,255,12,3,122,28,95,78,97,109,101,115,112,97,99,101, 76,111,97,100,101,114,46,108,111,97,100,95,109,111,100,117, - 108,101,78,41,12,114,149,0,0,0,114,148,0,0,0,114, - 150,0,0,0,114,232,0,0,0,114,230,0,0,0,114,69, - 1,0,0,114,206,0,0,0,114,252,0,0,0,114,236,0, - 0,0,114,235,0,0,0,114,240,0,0,0,114,243,0,0, - 0,114,10,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,68,1,0,0,250,4,0,0,115,18, - 0,0,0,8,1,8,3,2,1,10,8,8,3,8,3,8, - 3,8,3,8,3,114,68,1,0,0,99,0,0,0,0,0, - 0,0,0,0,0,0,0,0,0,0,0,4,0,0,0,64, - 0,0,0,115,118,0,0,0,101,0,90,1,100,0,90,2, - 100,1,90,3,101,4,100,2,100,3,132,0,131,1,90,5, - 101,4,100,4,100,5,132,0,131,1,90,6,101,4,100,6, - 100,7,132,0,131,1,90,7,101,4,100,8,100,9,132,0, - 131,1,90,8,101,4,100,19,100,11,100,12,132,1,131,1, - 90,9,101,4,100,20,100,13,100,14,132,1,131,1,90,10, - 101,4,100,21,100,15,100,16,132,1,131,1,90,11,101,4, - 100,17,100,18,132,0,131,1,90,12,100,10,83,0,41,22, - 218,10,80,97,116,104,70,105,110,100,101,114,122,62,77,101, - 116,97,32,112,97,116,104,32,102,105,110,100,101,114,32,102, - 111,114,32,115,121,115,46,112,97,116,104,32,97,110,100,32, - 112,97,99,107,97,103,101,32,95,95,112,97,116,104,95,95, - 32,97,116,116,114,105,98,117,116,101,115,46,99,1,0,0, - 0,0,0,0,0,0,0,0,0,3,0,0,0,4,0,0, - 0,67,0,0,0,115,78,0,0,0,116,0,116,1,106,2, - 160,3,161,0,131,1,68,0,93,44,92,2,125,1,125,2, - 124,2,100,1,117,0,114,40,116,1,106,2,124,1,61,0, - 113,14,116,4,124,2,100,2,131,2,114,14,124,2,160,5, - 161,0,1,0,113,14,116,6,4,0,106,7,100,3,55,0, - 2,0,95,7,100,1,83,0,41,4,122,125,67,97,108,108, - 32,116,104,101,32,105,110,118,97,108,105,100,97,116,101,95, - 99,97,99,104,101,115,40,41,32,109,101,116,104,111,100,32, - 111,110,32,97,108,108,32,112,97,116,104,32,101,110,116,114, - 121,32,102,105,110,100,101,114,115,10,32,32,32,32,32,32, - 32,32,115,116,111,114,101,100,32,105,110,32,115,121,115,46, + 108,101,99,2,0,0,0,0,0,0,0,0,0,0,0,3, + 0,0,0,2,0,0,0,67,0,0,0,115,22,0,0,0, + 100,1,100,2,108,0,109,1,125,2,1,0,124,2,124,0, + 106,2,131,1,83,0,41,3,78,114,0,0,0,0,41,1, + 218,15,78,97,109,101,115,112,97,99,101,82,101,97,100,101, + 114,41,3,114,32,1,0,0,114,78,1,0,0,114,49,1, + 0,0,41,3,114,143,0,0,0,114,244,0,0,0,114,78, + 1,0,0,114,7,0,0,0,114,7,0,0,0,114,8,0, + 0,0,114,33,1,0,0,39,5,0,0,115,4,0,0,0, + 12,1,10,1,122,36,95,78,97,109,101,115,112,97,99,101, + 76,111,97,100,101,114,46,103,101,116,95,114,101,115,111,117, + 114,99,101,95,114,101,97,100,101,114,78,41,13,114,150,0, + 0,0,114,149,0,0,0,114,151,0,0,0,114,236,0,0, + 0,114,233,0,0,0,114,76,1,0,0,114,206,0,0,0, + 114,1,1,0,0,114,241,0,0,0,114,239,0,0,0,114, + 245,0,0,0,114,248,0,0,0,114,33,1,0,0,114,7, + 0,0,0,114,7,0,0,0,114,7,0,0,0,114,8,0, + 0,0,114,75,1,0,0,253,4,0,0,115,22,0,0,0, + 8,0,8,1,2,3,10,1,8,10,8,3,8,3,8,3, + 8,3,8,3,12,12,114,75,1,0,0,99,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0,0,0,4,0,0,0, + 64,0,0,0,115,118,0,0,0,101,0,90,1,100,0,90, + 2,100,1,90,3,101,4,100,2,100,3,132,0,131,1,90, + 5,101,4,100,4,100,5,132,0,131,1,90,6,101,7,100, + 6,100,7,132,0,131,1,90,8,101,7,100,8,100,9,132, + 0,131,1,90,9,101,7,100,19,100,11,100,12,132,1,131, + 1,90,10,101,7,100,20,100,13,100,14,132,1,131,1,90, + 11,101,7,100,19,100,15,100,16,132,1,131,1,90,12,101, + 4,100,17,100,18,132,0,131,1,90,13,100,10,83,0,41, + 21,218,10,80,97,116,104,70,105,110,100,101,114,122,62,77, + 101,116,97,32,112,97,116,104,32,102,105,110,100,101,114,32, + 102,111,114,32,115,121,115,46,112,97,116,104,32,97,110,100, + 32,112,97,99,107,97,103,101,32,95,95,112,97,116,104,95, + 95,32,97,116,116,114,105,98,117,116,101,115,46,99,0,0, + 0,0,0,0,0,0,0,0,0,0,2,0,0,0,4,0, + 0,0,67,0,0,0,115,78,0,0,0,116,0,116,1,106, + 2,160,3,161,0,131,1,68,0,93,22,92,2,125,0,125, + 1,124,1,100,1,117,0,114,20,116,1,106,2,124,0,61, + 0,113,7,116,4,124,1,100,2,131,2,114,29,124,1,160, + 5,161,0,1,0,113,7,116,6,4,0,106,7,100,3,55, + 0,2,0,95,7,100,1,83,0,41,4,122,125,67,97,108, + 108,32,116,104,101,32,105,110,118,97,108,105,100,97,116,101, + 95,99,97,99,104,101,115,40,41,32,109,101,116,104,111,100, + 32,111,110,32,97,108,108,32,112,97,116,104,32,101,110,116, + 114,121,32,102,105,110,100,101,114,115,10,32,32,32,32,32, + 32,32,32,115,116,111,114,101,100,32,105,110,32,115,121,115, + 46,112,97,116,104,95,105,109,112,111,114,116,101,114,95,99, + 97,99,104,101,115,32,40,119,104,101,114,101,32,105,109,112, + 108,101,109,101,110,116,101,100,41,46,78,218,17,105,110,118, + 97,108,105,100,97,116,101,95,99,97,99,104,101,115,114,3, + 0,0,0,41,8,218,4,108,105,115,116,114,15,0,0,0, + 218,19,112,97,116,104,95,105,109,112,111,114,116,101,114,95, + 99,97,99,104,101,218,5,105,116,101,109,115,114,153,0,0, + 0,114,80,1,0,0,114,47,1,0,0,114,52,1,0,0, + 41,2,114,141,0,0,0,218,6,102,105,110,100,101,114,114, + 7,0,0,0,114,7,0,0,0,114,8,0,0,0,114,80, + 1,0,0,50,5,0,0,115,14,0,0,0,22,4,8,1, + 10,1,10,1,8,1,2,128,18,3,122,28,80,97,116,104, + 70,105,110,100,101,114,46,105,110,118,97,108,105,100,97,116, + 101,95,99,97,99,104,101,115,99,1,0,0,0,0,0,0, + 0,0,0,0,0,2,0,0,0,9,0,0,0,67,0,0, + 0,115,76,0,0,0,116,0,106,1,100,1,117,1,114,14, + 116,0,106,1,115,14,116,2,160,3,100,2,116,4,161,2, + 1,0,116,0,106,1,68,0,93,18,125,1,122,7,124,1, + 124,0,131,1,87,0,2,0,1,0,83,0,4,0,116,5, + 121,35,1,0,1,0,1,0,89,0,113,17,119,0,100,1, + 83,0,41,3,122,46,83,101,97,114,99,104,32,115,121,115, + 46,112,97,116,104,95,104,111,111,107,115,32,102,111,114,32, + 97,32,102,105,110,100,101,114,32,102,111,114,32,39,112,97, + 116,104,39,46,78,122,23,115,121,115,46,112,97,116,104,95, + 104,111,111,107,115,32,105,115,32,101,109,112,116,121,41,6, + 114,15,0,0,0,218,10,112,97,116,104,95,104,111,111,107, + 115,114,99,0,0,0,114,100,0,0,0,114,162,0,0,0, + 114,142,0,0,0,41,2,114,65,0,0,0,90,4,104,111, + 111,107,114,7,0,0,0,114,7,0,0,0,114,8,0,0, + 0,218,11,95,112,97,116,104,95,104,111,111,107,115,63,5, + 0,0,115,18,0,0,0,16,3,12,1,10,1,2,1,14, + 1,12,1,4,1,2,255,4,3,122,22,80,97,116,104,70, + 105,110,100,101,114,46,95,112,97,116,104,95,104,111,111,107, + 115,99,2,0,0,0,0,0,0,0,0,0,0,0,3,0, + 0,0,8,0,0,0,67,0,0,0,115,100,0,0,0,124, + 1,100,1,107,2,114,21,122,6,116,0,160,1,161,0,125, + 1,87,0,110,10,4,0,116,2,121,20,1,0,1,0,1, + 0,89,0,100,2,83,0,119,0,122,8,116,3,106,4,124, + 1,25,0,125,2,87,0,124,2,83,0,4,0,116,5,121, + 49,1,0,1,0,1,0,124,0,160,6,124,1,161,1,125, + 2,124,2,116,3,106,4,124,1,60,0,89,0,124,2,83, + 0,119,0,41,3,122,210,71,101,116,32,116,104,101,32,102, + 105,110,100,101,114,32,102,111,114,32,116,104,101,32,112,97, + 116,104,32,101,110,116,114,121,32,102,114,111,109,32,115,121, + 115,46,112,97,116,104,95,105,109,112,111,114,116,101,114,95, + 99,97,99,104,101,46,10,10,32,32,32,32,32,32,32,32, + 73,102,32,116,104,101,32,112,97,116,104,32,101,110,116,114, + 121,32,105,115,32,110,111,116,32,105,110,32,116,104,101,32, + 99,97,99,104,101,44,32,102,105,110,100,32,116,104,101,32, + 97,112,112,114,111,112,114,105,97,116,101,32,102,105,110,100, + 101,114,10,32,32,32,32,32,32,32,32,97,110,100,32,99, + 97,99,104,101,32,105,116,46,32,73,102,32,110,111,32,102, + 105,110,100,101,114,32,105,115,32,97,118,97,105,108,97,98, + 108,101,44,32,115,116,111,114,101,32,78,111,110,101,46,10, + 10,32,32,32,32,32,32,32,32,114,10,0,0,0,78,41, + 7,114,18,0,0,0,114,82,0,0,0,218,17,70,105,108, + 101,78,111,116,70,111,117,110,100,69,114,114,111,114,114,15, + 0,0,0,114,82,1,0,0,218,8,75,101,121,69,114,114, + 111,114,114,86,1,0,0,41,3,114,221,0,0,0,114,65, + 0,0,0,114,84,1,0,0,114,7,0,0,0,114,7,0, + 0,0,114,8,0,0,0,218,20,95,112,97,116,104,95,105, + 109,112,111,114,116,101,114,95,99,97,99,104,101,76,5,0, + 0,115,28,0,0,0,8,8,2,1,12,1,12,1,6,3, + 2,253,2,4,12,1,4,4,12,253,10,1,12,1,4,1, + 2,253,122,31,80,97,116,104,70,105,110,100,101,114,46,95, 112,97,116,104,95,105,109,112,111,114,116,101,114,95,99,97, - 99,104,101,115,32,40,119,104,101,114,101,32,105,109,112,108, - 101,109,101,110,116,101,100,41,46,78,218,17,105,110,118,97, - 108,105,100,97,116,101,95,99,97,99,104,101,115,114,4,0, - 0,0,41,8,218,4,108,105,115,116,114,21,0,0,0,218, - 19,112,97,116,104,95,105,109,112,111,114,116,101,114,95,99, - 97,99,104,101,218,5,105,116,101,109,115,114,152,0,0,0, - 114,71,1,0,0,114,45,1,0,0,114,50,1,0,0,41, - 3,114,216,0,0,0,114,140,0,0,0,218,6,102,105,110, - 100,101,114,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,114,71,1,0,0,40,5,0,0,115,12,0,0,0, - 0,4,22,1,8,1,10,1,10,1,10,3,122,28,80,97, - 116,104,70,105,110,100,101,114,46,105,110,118,97,108,105,100, - 97,116,101,95,99,97,99,104,101,115,99,2,0,0,0,0, - 0,0,0,0,0,0,0,3,0,0,0,9,0,0,0,67, - 0,0,0,115,82,0,0,0,116,0,106,1,100,1,117,1, - 114,28,116,0,106,1,115,28,116,2,160,3,100,2,116,4, - 161,2,1,0,116,0,106,1,68,0,93,42,125,2,122,14, - 124,2,124,1,131,1,87,0,2,0,1,0,83,0,4,0, - 116,5,121,74,1,0,1,0,1,0,89,0,113,34,89,0, - 113,34,48,0,113,34,100,1,83,0,41,3,122,46,83,101, - 97,114,99,104,32,115,121,115,46,112,97,116,104,95,104,111, - 111,107,115,32,102,111,114,32,97,32,102,105,110,100,101,114, - 32,102,111,114,32,39,112,97,116,104,39,46,78,122,23,115, - 121,115,46,112,97,116,104,95,104,111,111,107,115,32,105,115, - 32,101,109,112,116,121,41,6,114,21,0,0,0,218,10,112, - 97,116,104,95,104,111,111,107,115,114,98,0,0,0,114,99, - 0,0,0,114,162,0,0,0,114,141,0,0,0,41,3,114, - 216,0,0,0,114,65,0,0,0,90,4,104,111,111,107,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,218,11, - 95,112,97,116,104,95,104,111,111,107,115,53,5,0,0,115, - 16,0,0,0,0,3,16,1,12,1,10,1,2,1,14,1, - 12,1,12,2,122,22,80,97,116,104,70,105,110,100,101,114, - 46,95,112,97,116,104,95,104,111,111,107,115,99,2,0,0, - 0,0,0,0,0,0,0,0,0,3,0,0,0,8,0,0, - 0,67,0,0,0,115,100,0,0,0,124,1,100,1,107,2, - 114,42,122,12,116,0,160,1,161,0,125,1,87,0,110,20, - 4,0,116,2,121,40,1,0,1,0,1,0,89,0,100,2, - 83,0,48,0,122,14,116,3,106,4,124,1,25,0,125,2, - 87,0,110,38,4,0,116,5,121,94,1,0,1,0,1,0, - 124,0,160,6,124,1,161,1,125,2,124,2,116,3,106,4, - 124,1,60,0,89,0,110,2,48,0,124,2,83,0,41,3, - 122,210,71,101,116,32,116,104,101,32,102,105,110,100,101,114, - 32,102,111,114,32,116,104,101,32,112,97,116,104,32,101,110, - 116,114,121,32,102,114,111,109,32,115,121,115,46,112,97,116, - 104,95,105,109,112,111,114,116,101,114,95,99,97,99,104,101, - 46,10,10,32,32,32,32,32,32,32,32,73,102,32,116,104, - 101,32,112,97,116,104,32,101,110,116,114,121,32,105,115,32, - 110,111,116,32,105,110,32,116,104,101,32,99,97,99,104,101, - 44,32,102,105,110,100,32,116,104,101,32,97,112,112,114,111, - 112,114,105,97,116,101,32,102,105,110,100,101,114,10,32,32, - 32,32,32,32,32,32,97,110,100,32,99,97,99,104,101,32, - 105,116,46,32,73,102,32,110,111,32,102,105,110,100,101,114, - 32,105,115,32,97,118,97,105,108,97,98,108,101,44,32,115, - 116,111,114,101,32,78,111,110,101,46,10,10,32,32,32,32, - 32,32,32,32,114,14,0,0,0,78,41,7,114,24,0,0, - 0,114,81,0,0,0,114,26,1,0,0,114,21,0,0,0, - 114,73,1,0,0,218,8,75,101,121,69,114,114,111,114,114, - 77,1,0,0,41,3,114,216,0,0,0,114,65,0,0,0, - 114,75,1,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,20,95,112,97,116,104,95,105,109,112,111, - 114,116,101,114,95,99,97,99,104,101,66,5,0,0,115,22, - 0,0,0,0,8,8,1,2,1,12,1,12,3,8,1,2, - 1,14,1,12,1,10,1,16,1,122,31,80,97,116,104,70, - 105,110,100,101,114,46,95,112,97,116,104,95,105,109,112,111, - 114,116,101,114,95,99,97,99,104,101,99,3,0,0,0,0, - 0,0,0,0,0,0,0,6,0,0,0,4,0,0,0,67, - 0,0,0,115,82,0,0,0,116,0,124,2,100,1,131,2, - 114,26,124,2,160,1,124,1,161,1,92,2,125,3,125,4, - 110,14,124,2,160,2,124,1,161,1,125,3,103,0,125,4, - 124,3,100,0,117,1,114,60,116,3,160,4,124,1,124,3, - 161,2,83,0,116,3,160,5,124,1,100,0,161,2,125,5, - 124,4,124,5,95,6,124,5,83,0,41,2,78,114,161,0, - 0,0,41,7,114,152,0,0,0,114,161,0,0,0,114,229, - 0,0,0,114,158,0,0,0,114,224,0,0,0,114,207,0, - 0,0,114,202,0,0,0,41,6,114,216,0,0,0,114,163, - 0,0,0,114,75,1,0,0,114,164,0,0,0,114,165,0, - 0,0,114,210,0,0,0,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,218,16,95,108,101,103,97,99,121,95, - 103,101,116,95,115,112,101,99,88,5,0,0,115,18,0,0, - 0,0,4,10,1,16,2,10,1,4,1,8,1,12,1,12, - 1,6,1,122,27,80,97,116,104,70,105,110,100,101,114,46, - 95,108,101,103,97,99,121,95,103,101,116,95,115,112,101,99, - 78,99,4,0,0,0,0,0,0,0,0,0,0,0,9,0, - 0,0,5,0,0,0,67,0,0,0,115,166,0,0,0,103, - 0,125,4,124,2,68,0,93,134,125,5,116,0,124,5,116, - 1,116,2,102,2,131,2,115,28,113,8,124,0,160,3,124, - 5,161,1,125,6,124,6,100,1,117,1,114,8,116,4,124, - 6,100,2,131,2,114,70,124,6,160,5,124,1,124,3,161, - 2,125,7,110,12,124,0,160,6,124,1,124,6,161,2,125, - 7,124,7,100,1,117,0,114,92,113,8,124,7,106,7,100, - 1,117,1,114,110,124,7,2,0,1,0,83,0,124,7,106, - 8,125,8,124,8,100,1,117,0,114,132,116,9,100,3,131, - 1,130,1,124,4,160,10,124,8,161,1,1,0,113,8,116, - 11,160,12,124,1,100,1,161,2,125,7,124,4,124,7,95, - 8,124,7,83,0,41,4,122,63,70,105,110,100,32,116,104, - 101,32,108,111,97,100,101,114,32,111,114,32,110,97,109,101, - 115,112,97,99,101,95,112,97,116,104,32,102,111,114,32,116, - 104,105,115,32,109,111,100,117,108,101,47,112,97,99,107,97, - 103,101,32,110,97,109,101,46,78,114,226,0,0,0,122,19, - 115,112,101,99,32,109,105,115,115,105,110,103,32,108,111,97, - 100,101,114,41,13,114,185,0,0,0,114,108,0,0,0,218, - 5,98,121,116,101,115,114,79,1,0,0,114,152,0,0,0, - 114,226,0,0,0,114,80,1,0,0,114,164,0,0,0,114, - 202,0,0,0,114,141,0,0,0,114,191,0,0,0,114,158, - 0,0,0,114,207,0,0,0,41,9,114,216,0,0,0,114, - 163,0,0,0,114,65,0,0,0,114,225,0,0,0,218,14, - 110,97,109,101,115,112,97,99,101,95,112,97,116,104,90,5, - 101,110,116,114,121,114,75,1,0,0,114,210,0,0,0,114, - 165,0,0,0,114,10,0,0,0,114,10,0,0,0,114,11, - 0,0,0,218,9,95,103,101,116,95,115,112,101,99,103,5, - 0,0,115,40,0,0,0,0,5,4,1,8,1,14,1,2, - 1,10,1,8,1,10,1,14,2,12,1,8,1,2,1,10, - 1,8,1,6,1,8,1,8,5,12,2,12,1,6,1,122, - 20,80,97,116,104,70,105,110,100,101,114,46,95,103,101,116, - 95,115,112,101,99,99,4,0,0,0,0,0,0,0,0,0, - 0,0,6,0,0,0,5,0,0,0,67,0,0,0,115,100, - 0,0,0,124,2,100,1,117,0,114,14,116,0,106,1,125, - 2,124,0,160,2,124,1,124,2,124,3,161,3,125,4,124, - 4,100,1,117,0,114,40,100,1,83,0,124,4,106,3,100, - 1,117,0,114,92,124,4,106,4,125,5,124,5,114,86,100, - 1,124,4,95,5,116,6,124,1,124,5,124,0,106,2,131, - 3,124,4,95,4,124,4,83,0,100,1,83,0,110,4,124, - 4,83,0,100,1,83,0,41,2,122,141,84,114,121,32,116, - 111,32,102,105,110,100,32,97,32,115,112,101,99,32,102,111, - 114,32,39,102,117,108,108,110,97,109,101,39,32,111,110,32, - 115,121,115,46,112,97,116,104,32,111,114,32,39,112,97,116, - 104,39,46,10,10,32,32,32,32,32,32,32,32,84,104,101, - 32,115,101,97,114,99,104,32,105,115,32,98,97,115,101,100, - 32,111,110,32,115,121,115,46,112,97,116,104,95,104,111,111, - 107,115,32,97,110,100,32,115,121,115,46,112,97,116,104,95, - 105,109,112,111,114,116,101,114,95,99,97,99,104,101,46,10, - 32,32,32,32,32,32,32,32,78,41,7,114,21,0,0,0, - 114,65,0,0,0,114,83,1,0,0,114,164,0,0,0,114, - 202,0,0,0,114,205,0,0,0,114,45,1,0,0,41,6, - 114,216,0,0,0,114,163,0,0,0,114,65,0,0,0,114, - 225,0,0,0,114,210,0,0,0,114,82,1,0,0,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,114,226,0, - 0,0,135,5,0,0,115,26,0,0,0,0,6,8,1,6, - 1,14,1,8,1,4,1,10,1,6,1,4,3,6,1,16, - 1,4,2,6,2,122,20,80,97,116,104,70,105,110,100,101, - 114,46,102,105,110,100,95,115,112,101,99,99,3,0,0,0, - 0,0,0,0,0,0,0,0,4,0,0,0,4,0,0,0, - 67,0,0,0,115,30,0,0,0,124,0,160,0,124,1,124, - 2,161,2,125,3,124,3,100,1,117,0,114,24,100,1,83, - 0,124,3,106,1,83,0,41,2,122,170,102,105,110,100,32, - 116,104,101,32,109,111,100,117,108,101,32,111,110,32,115,121, - 115,46,112,97,116,104,32,111,114,32,39,112,97,116,104,39, - 32,98,97,115,101,100,32,111,110,32,115,121,115,46,112,97, - 116,104,95,104,111,111,107,115,32,97,110,100,10,32,32,32, - 32,32,32,32,32,115,121,115,46,112,97,116,104,95,105,109, - 112,111,114,116,101,114,95,99,97,99,104,101,46,10,10,32, - 32,32,32,32,32,32,32,84,104,105,115,32,109,101,116,104, - 111,100,32,105,115,32,100,101,112,114,101,99,97,116,101,100, - 46,32,32,85,115,101,32,102,105,110,100,95,115,112,101,99, - 40,41,32,105,110,115,116,101,97,100,46,10,10,32,32,32, - 32,32,32,32,32,78,114,227,0,0,0,114,228,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,114, - 229,0,0,0,159,5,0,0,115,8,0,0,0,0,8,12, - 1,8,1,4,1,122,22,80,97,116,104,70,105,110,100,101, - 114,46,102,105,110,100,95,109,111,100,117,108,101,99,1,0, - 0,0,0,0,0,0,0,0,0,0,4,0,0,0,4,0, - 0,0,79,0,0,0,115,28,0,0,0,100,1,100,2,108, - 0,109,1,125,3,1,0,124,3,106,2,124,1,105,0,124, - 2,164,1,142,1,83,0,41,3,97,32,1,0,0,10,32, - 32,32,32,32,32,32,32,70,105,110,100,32,100,105,115,116, - 114,105,98,117,116,105,111,110,115,46,10,10,32,32,32,32, - 32,32,32,32,82,101,116,117,114,110,32,97,110,32,105,116, - 101,114,97,98,108,101,32,111,102,32,97,108,108,32,68,105, - 115,116,114,105,98,117,116,105,111,110,32,105,110,115,116,97, - 110,99,101,115,32,99,97,112,97,98,108,101,32,111,102,10, - 32,32,32,32,32,32,32,32,108,111,97,100,105,110,103,32, - 116,104,101,32,109,101,116,97,100,97,116,97,32,102,111,114, - 32,112,97,99,107,97,103,101,115,32,109,97,116,99,104,105, - 110,103,32,96,96,99,111,110,116,101,120,116,46,110,97,109, - 101,96,96,10,32,32,32,32,32,32,32,32,40,111,114,32, - 97,108,108,32,110,97,109,101,115,32,105,102,32,96,96,78, - 111,110,101,96,96,32,105,110,100,105,99,97,116,101,100,41, - 32,97,108,111,110,103,32,116,104,101,32,112,97,116,104,115, - 32,105,110,32,116,104,101,32,108,105,115,116,10,32,32,32, - 32,32,32,32,32,111,102,32,100,105,114,101,99,116,111,114, - 105,101,115,32,96,96,99,111,110,116,101,120,116,46,112,97, - 116,104,96,96,46,10,32,32,32,32,32,32,32,32,114,0, - 0,0,0,41,1,218,18,77,101,116,97,100,97,116,97,80, - 97,116,104,70,105,110,100,101,114,41,3,90,18,105,109,112, - 111,114,116,108,105,98,46,109,101,116,97,100,97,116,97,114, - 84,1,0,0,218,18,102,105,110,100,95,100,105,115,116,114, - 105,98,117,116,105,111,110,115,41,4,114,216,0,0,0,114, - 143,0,0,0,114,144,0,0,0,114,84,1,0,0,114,10, - 0,0,0,114,10,0,0,0,114,11,0,0,0,114,85,1, - 0,0,172,5,0,0,115,4,0,0,0,0,10,12,1,122, - 29,80,97,116,104,70,105,110,100,101,114,46,102,105,110,100, - 95,100,105,115,116,114,105,98,117,116,105,111,110,115,41,1, - 78,41,2,78,78,41,1,78,41,13,114,149,0,0,0,114, - 148,0,0,0,114,150,0,0,0,114,151,0,0,0,114,230, - 0,0,0,114,71,1,0,0,114,77,1,0,0,114,79,1, - 0,0,114,80,1,0,0,114,83,1,0,0,114,226,0,0, - 0,114,229,0,0,0,114,85,1,0,0,114,10,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,114, - 70,1,0,0,36,5,0,0,115,34,0,0,0,8,2,4, - 2,2,1,10,12,2,1,10,12,2,1,10,21,2,1,10, - 14,2,1,12,31,2,1,12,23,2,1,12,12,2,1,114, - 70,1,0,0,99,0,0,0,0,0,0,0,0,0,0,0, + 99,104,101,99,3,0,0,0,0,0,0,0,0,0,0,0, + 7,0,0,0,4,0,0,0,67,0,0,0,115,138,0,0, + 0,116,0,124,2,100,1,131,2,114,27,116,1,160,2,124, + 2,161,1,155,0,100,2,157,2,125,3,116,3,160,4,124, + 3,116,5,161,2,1,0,124,2,160,6,124,1,161,1,92, + 2,125,4,125,5,110,21,116,1,160,2,124,2,161,1,155, + 0,100,3,157,2,125,3,116,3,160,4,124,3,116,5,161, + 2,1,0,124,2,160,7,124,1,161,1,125,4,103,0,125, + 5,124,4,100,0,117,1,114,58,116,1,160,8,124,1,124, + 4,161,2,83,0,116,1,160,9,124,1,100,0,161,2,125, + 6,124,5,124,6,95,10,124,6,83,0,41,4,78,114,161, + 0,0,0,122,53,46,102,105,110,100,95,115,112,101,99,40, + 41,32,110,111,116,32,102,111,117,110,100,59,32,102,97,108, + 108,105,110,103,32,98,97,99,107,32,116,111,32,102,105,110, + 100,95,108,111,97,100,101,114,40,41,122,53,46,102,105,110, + 100,95,115,112,101,99,40,41,32,110,111,116,32,102,111,117, + 110,100,59,32,102,97,108,108,105,110,103,32,98,97,99,107, + 32,116,111,32,102,105,110,100,95,109,111,100,117,108,101,40, + 41,41,11,114,153,0,0,0,114,159,0,0,0,90,12,95, + 111,98,106,101,99,116,95,110,97,109,101,114,99,0,0,0, + 114,100,0,0,0,114,162,0,0,0,114,161,0,0,0,114, + 229,0,0,0,114,224,0,0,0,114,207,0,0,0,114,202, + 0,0,0,41,7,114,221,0,0,0,114,163,0,0,0,114, + 84,1,0,0,114,166,0,0,0,114,164,0,0,0,114,165, + 0,0,0,114,210,0,0,0,114,7,0,0,0,114,7,0, + 0,0,114,8,0,0,0,218,16,95,108,101,103,97,99,121, + 95,103,101,116,95,115,112,101,99,98,5,0,0,115,26,0, + 0,0,10,4,16,1,12,2,16,1,16,2,12,2,10,1, + 4,1,8,1,12,1,12,1,6,1,4,1,122,27,80,97, + 116,104,70,105,110,100,101,114,46,95,108,101,103,97,99,121, + 95,103,101,116,95,115,112,101,99,78,99,4,0,0,0,0, + 0,0,0,0,0,0,0,9,0,0,0,5,0,0,0,67, + 0,0,0,115,166,0,0,0,103,0,125,4,124,2,68,0, + 93,67,125,5,116,0,124,5,116,1,116,2,102,2,131,2, + 115,14,113,4,124,0,160,3,124,5,161,1,125,6,124,6, + 100,1,117,1,114,71,116,4,124,6,100,2,131,2,114,35, + 124,6,160,5,124,1,124,3,161,2,125,7,110,6,124,0, + 160,6,124,1,124,6,161,2,125,7,124,7,100,1,117,0, + 114,46,113,4,124,7,106,7,100,1,117,1,114,55,124,7, + 2,0,1,0,83,0,124,7,106,8,125,8,124,8,100,1, + 117,0,114,66,116,9,100,3,131,1,130,1,124,4,160,10, + 124,8,161,1,1,0,113,4,116,11,160,12,124,1,100,1, + 161,2,125,7,124,4,124,7,95,8,124,7,83,0,41,4, + 122,63,70,105,110,100,32,116,104,101,32,108,111,97,100,101, + 114,32,111,114,32,110,97,109,101,115,112,97,99,101,95,112, + 97,116,104,32,102,111,114,32,116,104,105,115,32,109,111,100, + 117,108,101,47,112,97,99,107,97,103,101,32,110,97,109,101, + 46,78,114,226,0,0,0,122,19,115,112,101,99,32,109,105, + 115,115,105,110,103,32,108,111,97,100,101,114,41,13,114,185, + 0,0,0,114,109,0,0,0,218,5,98,121,116,101,115,114, + 89,1,0,0,114,153,0,0,0,114,226,0,0,0,114,90, + 1,0,0,114,164,0,0,0,114,202,0,0,0,114,142,0, + 0,0,114,191,0,0,0,114,159,0,0,0,114,207,0,0, + 0,41,9,114,221,0,0,0,114,163,0,0,0,114,65,0, + 0,0,114,225,0,0,0,218,14,110,97,109,101,115,112,97, + 99,101,95,112,97,116,104,90,5,101,110,116,114,121,114,84, + 1,0,0,114,210,0,0,0,114,165,0,0,0,114,7,0, + 0,0,114,7,0,0,0,114,8,0,0,0,218,9,95,103, + 101,116,95,115,112,101,99,119,5,0,0,115,42,0,0,0, + 4,5,8,1,14,1,2,1,10,1,8,1,10,1,14,1, + 12,2,8,1,2,1,10,1,8,1,6,1,8,1,8,1, + 10,5,2,128,12,2,6,1,4,1,122,20,80,97,116,104, + 70,105,110,100,101,114,46,95,103,101,116,95,115,112,101,99, + 99,4,0,0,0,0,0,0,0,0,0,0,0,6,0,0, + 0,5,0,0,0,67,0,0,0,115,94,0,0,0,124,2, + 100,1,117,0,114,7,116,0,106,1,125,2,124,0,160,2, + 124,1,124,2,124,3,161,3,125,4,124,4,100,1,117,0, + 114,20,100,1,83,0,124,4,106,3,100,1,117,0,114,45, + 124,4,106,4,125,5,124,5,114,43,100,1,124,4,95,5, + 116,6,124,1,124,5,124,0,106,2,131,3,124,4,95,4, + 124,4,83,0,100,1,83,0,124,4,83,0,41,2,122,141, + 84,114,121,32,116,111,32,102,105,110,100,32,97,32,115,112, + 101,99,32,102,111,114,32,39,102,117,108,108,110,97,109,101, + 39,32,111,110,32,115,121,115,46,112,97,116,104,32,111,114, + 32,39,112,97,116,104,39,46,10,10,32,32,32,32,32,32, + 32,32,84,104,101,32,115,101,97,114,99,104,32,105,115,32, + 98,97,115,101,100,32,111,110,32,115,121,115,46,112,97,116, + 104,95,104,111,111,107,115,32,97,110,100,32,115,121,115,46, + 112,97,116,104,95,105,109,112,111,114,116,101,114,95,99,97, + 99,104,101,46,10,32,32,32,32,32,32,32,32,78,41,7, + 114,15,0,0,0,114,65,0,0,0,114,93,1,0,0,114, + 164,0,0,0,114,202,0,0,0,114,205,0,0,0,114,47, + 1,0,0,41,6,114,221,0,0,0,114,163,0,0,0,114, + 65,0,0,0,114,225,0,0,0,114,210,0,0,0,114,92, + 1,0,0,114,7,0,0,0,114,7,0,0,0,114,8,0, + 0,0,114,226,0,0,0,151,5,0,0,115,26,0,0,0, + 8,6,6,1,14,1,8,1,4,1,10,1,6,1,4,1, + 6,3,16,1,4,1,4,2,4,2,122,20,80,97,116,104, + 70,105,110,100,101,114,46,102,105,110,100,95,115,112,101,99, + 99,3,0,0,0,0,0,0,0,0,0,0,0,4,0,0, + 0,4,0,0,0,67,0,0,0,115,42,0,0,0,116,0, + 160,1,100,1,116,2,161,2,1,0,124,0,160,3,124,1, + 124,2,161,2,125,3,124,3,100,2,117,0,114,18,100,2, + 83,0,124,3,106,4,83,0,41,3,122,170,102,105,110,100, + 32,116,104,101,32,109,111,100,117,108,101,32,111,110,32,115, + 121,115,46,112,97,116,104,32,111,114,32,39,112,97,116,104, + 39,32,98,97,115,101,100,32,111,110,32,115,121,115,46,112, + 97,116,104,95,104,111,111,107,115,32,97,110,100,10,32,32, + 32,32,32,32,32,32,115,121,115,46,112,97,116,104,95,105, + 109,112,111,114,116,101,114,95,99,97,99,104,101,46,10,10, + 32,32,32,32,32,32,32,32,84,104,105,115,32,109,101,116, + 104,111,100,32,105,115,32,100,101,112,114,101,99,97,116,101, + 100,46,32,32,85,115,101,32,102,105,110,100,95,115,112,101, + 99,40,41,32,105,110,115,116,101,97,100,46,10,10,32,32, + 32,32,32,32,32,32,122,101,80,97,116,104,70,105,110,100, + 101,114,46,102,105,110,100,95,109,111,100,117,108,101,40,41, + 32,105,115,32,100,101,112,114,101,99,97,116,101,100,32,97, + 110,100,32,115,108,97,116,101,100,32,102,111,114,32,114,101, + 109,111,118,97,108,32,105,110,32,80,121,116,104,111,110,32, + 51,46,49,50,59,32,117,115,101,32,102,105,110,100,95,115, + 112,101,99,40,41,32,105,110,115,116,101,97,100,78,114,227, + 0,0,0,114,228,0,0,0,114,7,0,0,0,114,7,0, + 0,0,114,8,0,0,0,114,229,0,0,0,175,5,0,0, + 115,14,0,0,0,6,8,2,2,4,254,12,3,8,1,4, + 1,6,1,122,22,80,97,116,104,70,105,110,100,101,114,46, + 102,105,110,100,95,109,111,100,117,108,101,99,0,0,0,0, + 0,0,0,0,0,0,0,0,3,0,0,0,4,0,0,0, + 79,0,0,0,115,28,0,0,0,100,1,100,2,108,0,109, + 1,125,2,1,0,124,2,106,2,124,0,105,0,124,1,164, + 1,142,1,83,0,41,3,97,32,1,0,0,10,32,32,32, + 32,32,32,32,32,70,105,110,100,32,100,105,115,116,114,105, + 98,117,116,105,111,110,115,46,10,10,32,32,32,32,32,32, + 32,32,82,101,116,117,114,110,32,97,110,32,105,116,101,114, + 97,98,108,101,32,111,102,32,97,108,108,32,68,105,115,116, + 114,105,98,117,116,105,111,110,32,105,110,115,116,97,110,99, + 101,115,32,99,97,112,97,98,108,101,32,111,102,10,32,32, + 32,32,32,32,32,32,108,111,97,100,105,110,103,32,116,104, + 101,32,109,101,116,97,100,97,116,97,32,102,111,114,32,112, + 97,99,107,97,103,101,115,32,109,97,116,99,104,105,110,103, + 32,96,96,99,111,110,116,101,120,116,46,110,97,109,101,96, + 96,10,32,32,32,32,32,32,32,32,40,111,114,32,97,108, + 108,32,110,97,109,101,115,32,105,102,32,96,96,78,111,110, + 101,96,96,32,105,110,100,105,99,97,116,101,100,41,32,97, + 108,111,110,103,32,116,104,101,32,112,97,116,104,115,32,105, + 110,32,116,104,101,32,108,105,115,116,10,32,32,32,32,32, + 32,32,32,111,102,32,100,105,114,101,99,116,111,114,105,101, + 115,32,96,96,99,111,110,116,101,120,116,46,112,97,116,104, + 96,96,46,10,32,32,32,32,32,32,32,32,114,0,0,0, + 0,41,1,218,18,77,101,116,97,100,97,116,97,80,97,116, + 104,70,105,110,100,101,114,41,3,90,18,105,109,112,111,114, + 116,108,105,98,46,109,101,116,97,100,97,116,97,114,94,1, + 0,0,218,18,102,105,110,100,95,100,105,115,116,114,105,98, + 117,116,105,111,110,115,41,3,114,144,0,0,0,114,145,0, + 0,0,114,94,1,0,0,114,7,0,0,0,114,7,0,0, + 0,114,8,0,0,0,114,95,1,0,0,191,5,0,0,115, + 4,0,0,0,12,10,16,1,122,29,80,97,116,104,70,105, + 110,100,101,114,46,102,105,110,100,95,100,105,115,116,114,105, + 98,117,116,105,111,110,115,114,69,0,0,0,114,230,0,0, + 0,41,14,114,150,0,0,0,114,149,0,0,0,114,151,0, + 0,0,114,152,0,0,0,114,233,0,0,0,114,80,1,0, + 0,114,86,1,0,0,114,234,0,0,0,114,89,1,0,0, + 114,90,1,0,0,114,93,1,0,0,114,226,0,0,0,114, + 229,0,0,0,114,95,1,0,0,114,7,0,0,0,114,7, + 0,0,0,114,7,0,0,0,114,8,0,0,0,114,79,1, + 0,0,46,5,0,0,115,36,0,0,0,8,0,4,2,2, + 2,10,1,2,12,10,1,2,12,10,1,2,21,10,1,2, + 20,12,1,2,31,12,1,2,23,12,1,2,15,14,1,114, + 79,1,0,0,99,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,3,0,0,0,64,0,0,0,115,90,0, 0,0,101,0,90,1,100,0,90,2,100,1,90,3,100,2, 100,3,132,0,90,4,100,4,100,5,132,0,90,5,101,6, @@ -2388,11 +2393,11 @@ const unsigned char _Py_M__importlib_bootstrap_external[] = { 104,97,115,32,98,101,101,110,32,109,111,100,105,102,105,101, 100,46,10,10,32,32,32,32,99,2,0,0,0,0,0,0, 0,0,0,0,0,5,0,0,0,6,0,0,0,7,0,0, - 0,115,112,0,0,0,103,0,125,3,124,2,68,0,93,32, + 0,115,112,0,0,0,103,0,125,3,124,2,68,0,93,16, 92,2,137,0,125,4,124,3,160,0,135,0,102,1,100,1, - 100,2,132,8,124,4,68,0,131,1,161,1,1,0,113,8, - 124,3,124,0,95,1,124,1,112,54,100,3,124,0,95,2, - 116,3,124,0,106,2,131,1,115,86,116,4,116,5,160,6, + 100,2,132,8,124,4,68,0,131,1,161,1,1,0,113,4, + 124,3,124,0,95,1,124,1,112,27,100,3,124,0,95,2, + 116,3,124,0,106,2,131,1,115,43,116,4,116,5,160,6, 161,0,124,0,106,2,131,2,124,0,95,2,100,4,124,0, 95,7,116,8,131,0,124,0,95,9,116,8,131,0,124,0, 95,10,100,5,83,0,41,6,122,154,73,110,105,116,105,97, @@ -2406,42 +2411,43 @@ const unsigned char _Py_M__importlib_bootstrap_external[] = { 102,105,120,101,115,32,116,104,101,32,108,111,97,100,101,114, 10,32,32,32,32,32,32,32,32,114,101,99,111,103,110,105, 122,101,115,46,99,1,0,0,0,0,0,0,0,0,0,0, - 0,2,0,0,0,3,0,0,0,51,0,0,0,115,22,0, - 0,0,124,0,93,14,125,1,124,1,136,0,102,2,86,0, - 1,0,113,2,100,0,83,0,114,69,0,0,0,114,10,0, - 0,0,114,40,1,0,0,169,1,114,164,0,0,0,114,10, - 0,0,0,114,11,0,0,0,114,12,0,0,0,201,5,0, - 0,114,13,0,0,0,122,38,70,105,108,101,70,105,110,100, - 101,114,46,95,95,105,110,105,116,95,95,46,60,108,111,99, - 97,108,115,62,46,60,103,101,110,101,120,112,114,62,114,96, - 0,0,0,114,129,0,0,0,78,41,11,114,191,0,0,0, - 218,8,95,108,111,97,100,101,114,115,114,65,0,0,0,114, - 85,0,0,0,114,67,0,0,0,114,24,0,0,0,114,81, - 0,0,0,218,11,95,112,97,116,104,95,109,116,105,109,101, - 218,3,115,101,116,218,11,95,112,97,116,104,95,99,97,99, - 104,101,218,19,95,114,101,108,97,120,101,100,95,112,97,116, - 104,95,99,97,99,104,101,41,5,114,142,0,0,0,114,65, - 0,0,0,218,14,108,111,97,100,101,114,95,100,101,116,97, - 105,108,115,90,7,108,111,97,100,101,114,115,114,212,0,0, - 0,114,10,0,0,0,114,87,1,0,0,114,11,0,0,0, - 114,232,0,0,0,195,5,0,0,115,20,0,0,0,0,4, - 4,1,12,1,26,1,6,2,10,1,10,1,18,1,6,1, - 8,1,122,19,70,105,108,101,70,105,110,100,101,114,46,95, - 95,105,110,105,116,95,95,99,1,0,0,0,0,0,0,0, - 0,0,0,0,1,0,0,0,2,0,0,0,67,0,0,0, - 115,10,0,0,0,100,1,124,0,95,0,100,2,83,0,41, - 3,122,31,73,110,118,97,108,105,100,97,116,101,32,116,104, - 101,32,100,105,114,101,99,116,111,114,121,32,109,116,105,109, - 101,46,114,129,0,0,0,78,41,1,114,89,1,0,0,114, - 13,1,0,0,114,10,0,0,0,114,10,0,0,0,114,11, - 0,0,0,114,71,1,0,0,211,5,0,0,115,2,0,0, - 0,0,2,122,28,70,105,108,101,70,105,110,100,101,114,46, - 105,110,118,97,108,105,100,97,116,101,95,99,97,99,104,101, - 115,99,2,0,0,0,0,0,0,0,0,0,0,0,3,0, - 0,0,3,0,0,0,67,0,0,0,115,42,0,0,0,124, - 0,160,0,124,1,161,1,125,2,124,2,100,1,117,0,114, - 26,100,1,103,0,102,2,83,0,124,2,106,1,124,2,106, - 2,112,38,103,0,102,2,83,0,41,2,122,197,84,114,121, + 0,2,0,0,0,3,0,0,0,51,0,0,0,115,24,0, + 0,0,129,0,124,0,93,7,125,1,124,1,136,0,102,2, + 86,0,1,0,113,2,100,0,83,0,114,69,0,0,0,114, + 7,0,0,0,114,43,1,0,0,169,1,114,164,0,0,0, + 114,7,0,0,0,114,8,0,0,0,114,9,0,0,0,220, + 5,0,0,115,4,0,0,0,2,128,22,0,122,38,70,105, + 108,101,70,105,110,100,101,114,46,95,95,105,110,105,116,95, + 95,46,60,108,111,99,97,108,115,62,46,60,103,101,110,101, + 120,112,114,62,114,97,0,0,0,114,130,0,0,0,78,41, + 11,114,191,0,0,0,218,8,95,108,111,97,100,101,114,115, + 114,65,0,0,0,114,86,0,0,0,114,67,0,0,0,114, + 18,0,0,0,114,82,0,0,0,218,11,95,112,97,116,104, + 95,109,116,105,109,101,218,3,115,101,116,218,11,95,112,97, + 116,104,95,99,97,99,104,101,218,19,95,114,101,108,97,120, + 101,100,95,112,97,116,104,95,99,97,99,104,101,41,5,114, + 143,0,0,0,114,65,0,0,0,218,14,108,111,97,100,101, + 114,95,100,101,116,97,105,108,115,90,7,108,111,97,100,101, + 114,115,114,212,0,0,0,114,7,0,0,0,114,97,1,0, + 0,114,8,0,0,0,114,236,0,0,0,214,5,0,0,115, + 20,0,0,0,4,4,12,1,26,1,6,1,10,2,10,1, + 18,1,6,1,8,1,12,1,122,19,70,105,108,101,70,105, + 110,100,101,114,46,95,95,105,110,105,116,95,95,99,1,0, + 0,0,0,0,0,0,0,0,0,0,1,0,0,0,2,0, + 0,0,67,0,0,0,115,10,0,0,0,100,1,124,0,95, + 0,100,2,83,0,41,3,122,31,73,110,118,97,108,105,100, + 97,116,101,32,116,104,101,32,100,105,114,101,99,116,111,114, + 121,32,109,116,105,109,101,46,114,130,0,0,0,78,41,1, + 114,99,1,0,0,114,21,1,0,0,114,7,0,0,0,114, + 7,0,0,0,114,8,0,0,0,114,80,1,0,0,230,5, + 0,0,114,81,0,0,0,122,28,70,105,108,101,70,105,110, + 100,101,114,46,105,110,118,97,108,105,100,97,116,101,95,99, + 97,99,104,101,115,99,2,0,0,0,0,0,0,0,0,0, + 0,0,3,0,0,0,4,0,0,0,67,0,0,0,115,54, + 0,0,0,116,0,160,1,100,1,116,2,161,2,1,0,124, + 0,160,3,124,1,161,1,125,2,124,2,100,2,117,0,114, + 19,100,2,103,0,102,2,83,0,124,2,106,4,124,2,106, + 5,112,25,103,0,102,2,83,0,41,3,122,197,84,114,121, 32,116,111,32,102,105,110,100,32,97,32,108,111,97,100,101, 114,32,102,111,114,32,116,104,101,32,115,112,101,99,105,102, 105,101,100,32,109,111,100,117,108,101,44,32,111,114,32,116, @@ -2454,379 +2460,312 @@ const unsigned char _Py_M__importlib_bootstrap_external[] = { 105,115,32,100,101,112,114,101,99,97,116,101,100,46,32,32, 85,115,101,32,102,105,110,100,95,115,112,101,99,40,41,32, 105,110,115,116,101,97,100,46,10,10,32,32,32,32,32,32, - 32,32,78,41,3,114,226,0,0,0,114,164,0,0,0,114, - 202,0,0,0,41,3,114,142,0,0,0,114,163,0,0,0, - 114,210,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,114,161,0,0,0,217,5,0,0,115,8,0, - 0,0,0,7,10,1,8,1,8,1,122,22,70,105,108,101, - 70,105,110,100,101,114,46,102,105,110,100,95,108,111,97,100, - 101,114,99,6,0,0,0,0,0,0,0,0,0,0,0,7, - 0,0,0,6,0,0,0,67,0,0,0,115,26,0,0,0, - 124,1,124,2,124,3,131,2,125,6,116,0,124,2,124,3, - 124,6,124,4,100,1,141,4,83,0,41,2,78,114,201,0, - 0,0,41,1,114,213,0,0,0,41,7,114,142,0,0,0, - 114,211,0,0,0,114,163,0,0,0,114,65,0,0,0,90, - 4,115,109,115,108,114,225,0,0,0,114,164,0,0,0,114, - 10,0,0,0,114,10,0,0,0,114,11,0,0,0,114,83, - 1,0,0,229,5,0,0,115,8,0,0,0,0,1,10,1, - 8,1,2,255,122,20,70,105,108,101,70,105,110,100,101,114, - 46,95,103,101,116,95,115,112,101,99,78,99,3,0,0,0, - 0,0,0,0,0,0,0,0,14,0,0,0,9,0,0,0, - 67,0,0,0,115,126,1,0,0,100,1,125,3,124,1,160, - 0,100,2,161,1,100,3,25,0,125,4,122,24,116,1,124, - 0,106,2,112,34,116,3,160,4,161,0,131,1,106,5,125, - 5,87,0,110,22,4,0,116,6,121,64,1,0,1,0,1, - 0,100,4,125,5,89,0,110,2,48,0,124,5,124,0,106, - 7,107,3,114,90,124,0,160,8,161,0,1,0,124,5,124, - 0,95,7,116,9,131,0,114,112,124,0,106,10,125,6,124, - 4,160,11,161,0,125,7,110,10,124,0,106,12,125,6,124, - 4,125,7,124,7,124,6,118,0,114,216,116,13,124,0,106, - 2,124,4,131,2,125,8,124,0,106,14,68,0,93,58,92, - 2,125,9,125,10,100,5,124,9,23,0,125,11,116,13,124, - 8,124,11,131,2,125,12,116,15,124,12,131,1,114,148,124, - 0,160,16,124,10,124,1,124,12,124,8,103,1,124,2,161, - 5,2,0,1,0,83,0,113,148,116,17,124,8,131,1,125, - 3,124,0,106,14,68,0,93,112,92,2,125,9,125,10,122, - 20,116,13,124,0,106,2,124,4,124,9,23,0,131,2,125, - 12,87,0,110,24,4,0,116,18,144,1,121,18,1,0,1, - 0,1,0,89,0,1,0,100,6,83,0,48,0,116,19,106, - 20,100,7,124,12,100,3,100,8,141,3,1,0,124,7,124, - 9,23,0,124,6,118,0,114,222,116,15,124,12,131,1,114, - 222,124,0,160,16,124,10,124,1,124,12,100,6,124,2,161, - 5,2,0,1,0,83,0,113,222,124,3,144,1,114,122,116, - 19,160,20,100,9,124,8,161,2,1,0,116,19,160,21,124, - 1,100,6,161,2,125,13,124,8,103,1,124,13,95,22,124, - 13,83,0,100,6,83,0,41,10,122,111,84,114,121,32,116, - 111,32,102,105,110,100,32,97,32,115,112,101,99,32,102,111, - 114,32,116,104,101,32,115,112,101,99,105,102,105,101,100,32, - 109,111,100,117,108,101,46,10,10,32,32,32,32,32,32,32, - 32,82,101,116,117,114,110,115,32,116,104,101,32,109,97,116, - 99,104,105,110,103,32,115,112,101,99,44,32,111,114,32,78, - 111,110,101,32,105,102,32,110,111,116,32,102,111,117,110,100, - 46,10,32,32,32,32,32,32,32,32,70,114,96,0,0,0, - 114,45,0,0,0,114,129,0,0,0,114,232,0,0,0,78, - 122,9,116,114,121,105,110,103,32,123,125,41,1,90,9,118, - 101,114,98,111,115,105,116,121,122,25,112,111,115,115,105,98, - 108,101,32,110,97,109,101,115,112,97,99,101,32,102,111,114, - 32,123,125,41,23,114,103,0,0,0,114,75,0,0,0,114, - 65,0,0,0,114,24,0,0,0,114,81,0,0,0,114,33, - 1,0,0,114,76,0,0,0,114,89,1,0,0,218,11,95, - 102,105,108,108,95,99,97,99,104,101,114,27,0,0,0,114, - 92,1,0,0,114,130,0,0,0,114,91,1,0,0,114,67, - 0,0,0,114,88,1,0,0,114,80,0,0,0,114,83,1, - 0,0,114,82,0,0,0,114,110,0,0,0,114,158,0,0, - 0,114,173,0,0,0,114,207,0,0,0,114,202,0,0,0, - 41,14,114,142,0,0,0,114,163,0,0,0,114,225,0,0, - 0,90,12,105,115,95,110,97,109,101,115,112,97,99,101,90, - 11,116,97,105,108,95,109,111,100,117,108,101,114,193,0,0, - 0,90,5,99,97,99,104,101,90,12,99,97,99,104,101,95, - 109,111,100,117,108,101,90,9,98,97,115,101,95,112,97,116, - 104,114,41,1,0,0,114,211,0,0,0,90,13,105,110,105, - 116,95,102,105,108,101,110,97,109,101,90,9,102,117,108,108, - 95,112,97,116,104,114,210,0,0,0,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,114,226,0,0,0,234,5, - 0,0,115,78,0,0,0,0,5,4,1,14,1,2,1,24, - 1,12,1,10,1,10,1,8,1,6,2,6,1,6,1,10, - 2,6,1,4,2,8,1,12,1,14,1,8,1,10,1,8, - 1,26,4,8,2,14,1,2,1,20,1,14,1,10,1,16, - 1,12,1,8,1,10,1,4,255,10,2,6,1,12,1,12, - 1,8,1,4,1,122,20,70,105,108,101,70,105,110,100,101, + 32,32,122,101,70,105,108,101,70,105,110,100,101,114,46,102, + 105,110,100,95,108,111,97,100,101,114,40,41,32,105,115,32, + 100,101,112,114,101,99,97,116,101,100,32,97,110,100,32,115, + 108,97,116,101,100,32,102,111,114,32,114,101,109,111,118,97, + 108,32,105,110,32,80,121,116,104,111,110,32,51,46,49,50, + 59,32,117,115,101,32,102,105,110,100,95,115,112,101,99,40, + 41,32,105,110,115,116,101,97,100,78,41,6,114,99,0,0, + 0,114,100,0,0,0,114,101,0,0,0,114,226,0,0,0, + 114,164,0,0,0,114,202,0,0,0,41,3,114,143,0,0, + 0,114,163,0,0,0,114,210,0,0,0,114,7,0,0,0, + 114,7,0,0,0,114,8,0,0,0,114,161,0,0,0,236, + 5,0,0,115,14,0,0,0,6,7,2,2,4,254,10,3, + 8,1,8,1,16,1,122,22,70,105,108,101,70,105,110,100, + 101,114,46,102,105,110,100,95,108,111,97,100,101,114,99,6, + 0,0,0,0,0,0,0,0,0,0,0,7,0,0,0,6, + 0,0,0,67,0,0,0,115,26,0,0,0,124,1,124,2, + 124,3,131,2,125,6,116,0,124,2,124,3,124,6,124,4, + 100,1,141,4,83,0,41,2,78,114,201,0,0,0,41,1, + 114,213,0,0,0,41,7,114,143,0,0,0,114,211,0,0, + 0,114,163,0,0,0,114,65,0,0,0,90,4,115,109,115, + 108,114,225,0,0,0,114,164,0,0,0,114,7,0,0,0, + 114,7,0,0,0,114,8,0,0,0,114,93,1,0,0,251, + 5,0,0,115,8,0,0,0,10,1,8,1,2,1,6,255, + 122,20,70,105,108,101,70,105,110,100,101,114,46,95,103,101, + 116,95,115,112,101,99,78,99,3,0,0,0,0,0,0,0, + 0,0,0,0,14,0,0,0,9,0,0,0,67,0,0,0, + 115,122,1,0,0,100,1,125,3,124,1,160,0,100,2,161, + 1,100,3,25,0,125,4,122,12,116,1,124,0,106,2,112, + 17,116,3,160,4,161,0,131,1,106,5,125,5,87,0,110, + 11,4,0,116,6,121,32,1,0,1,0,1,0,100,4,125, + 5,89,0,110,1,119,0,124,5,124,0,106,7,107,3,114, + 45,124,0,160,8,161,0,1,0,124,5,124,0,95,7,116, + 9,131,0,114,56,124,0,106,10,125,6,124,4,160,11,161, + 0,125,7,110,5,124,0,106,12,125,6,124,4,125,7,124, + 7,124,6,118,0,114,108,116,13,124,0,106,2,124,4,131, + 2,125,8,124,0,106,14,68,0,93,29,92,2,125,9,125, + 10,100,5,124,9,23,0,125,11,116,13,124,8,124,11,131, + 2,125,12,116,15,124,12,131,1,114,103,124,0,160,16,124, + 10,124,1,124,12,124,8,103,1,124,2,161,5,2,0,1, + 0,83,0,113,74,116,17,124,8,131,1,125,3,124,0,106, + 14,68,0,93,55,92,2,125,9,125,10,122,10,116,13,124, + 0,106,2,124,4,124,9,23,0,131,2,125,12,87,0,110, + 11,4,0,116,18,121,136,1,0,1,0,1,0,89,0,1, + 0,100,6,83,0,119,0,116,19,106,20,100,7,124,12,100, + 3,100,8,141,3,1,0,124,7,124,9,23,0,124,6,118, + 0,114,166,116,15,124,12,131,1,114,166,124,0,160,16,124, + 10,124,1,124,12,100,6,124,2,161,5,2,0,1,0,83, + 0,113,111,124,3,114,187,116,19,160,20,100,9,124,8,161, + 2,1,0,116,19,160,21,124,1,100,6,161,2,125,13,124, + 8,103,1,124,13,95,22,124,13,83,0,100,6,83,0,41, + 10,122,111,84,114,121,32,116,111,32,102,105,110,100,32,97, + 32,115,112,101,99,32,102,111,114,32,116,104,101,32,115,112, + 101,99,105,102,105,101,100,32,109,111,100,117,108,101,46,10, + 10,32,32,32,32,32,32,32,32,82,101,116,117,114,110,115, + 32,116,104,101,32,109,97,116,99,104,105,110,103,32,115,112, + 101,99,44,32,111,114,32,78,111,110,101,32,105,102,32,110, + 111,116,32,102,111,117,110,100,46,10,32,32,32,32,32,32, + 32,32,70,114,97,0,0,0,114,44,0,0,0,114,130,0, + 0,0,114,236,0,0,0,78,122,9,116,114,121,105,110,103, + 32,123,125,41,1,90,9,118,101,114,98,111,115,105,116,121, + 122,25,112,111,115,115,105,98,108,101,32,110,97,109,101,115, + 112,97,99,101,32,102,111,114,32,123,125,41,23,114,104,0, + 0,0,114,75,0,0,0,114,65,0,0,0,114,18,0,0, + 0,114,82,0,0,0,114,35,1,0,0,114,76,0,0,0, + 114,99,1,0,0,218,11,95,102,105,108,108,95,99,97,99, + 104,101,114,21,0,0,0,114,102,1,0,0,114,131,0,0, + 0,114,101,1,0,0,114,67,0,0,0,114,98,1,0,0, + 114,80,0,0,0,114,93,1,0,0,114,83,0,0,0,114, + 111,0,0,0,114,159,0,0,0,114,173,0,0,0,114,207, + 0,0,0,114,202,0,0,0,41,14,114,143,0,0,0,114, + 163,0,0,0,114,225,0,0,0,90,12,105,115,95,110,97, + 109,101,115,112,97,99,101,90,11,116,97,105,108,95,109,111, + 100,117,108,101,114,193,0,0,0,90,5,99,97,99,104,101, + 90,12,99,97,99,104,101,95,109,111,100,117,108,101,90,9, + 98,97,115,101,95,112,97,116,104,114,44,1,0,0,114,211, + 0,0,0,90,13,105,110,105,116,95,102,105,108,101,110,97, + 109,101,90,9,102,117,108,108,95,112,97,116,104,114,210,0, + 0,0,114,7,0,0,0,114,7,0,0,0,114,8,0,0, + 0,114,226,0,0,0,0,6,0,0,115,86,0,0,0,4, + 5,14,1,2,1,24,1,12,1,8,1,2,255,10,2,8, + 1,6,1,6,2,6,1,10,1,6,2,4,1,8,2,12, + 1,14,1,8,1,10,1,8,1,24,1,2,255,8,5,14, + 2,2,1,20,1,12,1,8,1,2,255,16,2,12,1,8, + 1,10,1,4,1,8,255,2,128,4,2,12,1,12,1,8, + 1,4,1,4,1,122,20,70,105,108,101,70,105,110,100,101, 114,46,102,105,110,100,95,115,112,101,99,99,1,0,0,0, 0,0,0,0,0,0,0,0,9,0,0,0,10,0,0,0, - 67,0,0,0,115,188,0,0,0,124,0,106,0,125,1,122, - 22,116,1,160,2,124,1,112,22,116,1,160,3,161,0,161, - 1,125,2,87,0,110,28,4,0,116,4,116,5,116,6,102, - 3,121,56,1,0,1,0,1,0,103,0,125,2,89,0,110, - 2,48,0,116,7,106,8,160,9,100,1,161,1,115,82,116, - 10,124,2,131,1,124,0,95,11,110,74,116,10,131,0,125, - 3,124,2,68,0,93,56,125,4,124,4,160,12,100,2,161, - 1,92,3,125,5,125,6,125,7,124,6,114,134,100,3,160, - 13,124,5,124,7,160,14,161,0,161,2,125,8,110,4,124, - 5,125,8,124,3,160,15,124,8,161,1,1,0,113,92,124, + 67,0,0,0,115,192,0,0,0,124,0,106,0,125,1,122, + 11,116,1,160,2,124,1,112,11,116,1,160,3,161,0,161, + 1,125,2,87,0,110,14,4,0,116,4,116,5,116,6,102, + 3,121,28,1,0,1,0,1,0,103,0,125,2,89,0,110, + 1,119,0,116,7,106,8,160,9,100,1,161,1,115,41,116, + 10,124,2,131,1,124,0,95,11,110,37,116,10,131,0,125, + 3,124,2,68,0,93,28,125,4,124,4,160,12,100,2,161, + 1,92,3,125,5,125,6,125,7,124,6,114,67,100,3,160, + 13,124,5,124,7,160,14,161,0,161,2,125,8,110,2,124, + 5,125,8,124,3,160,15,124,8,161,1,1,0,113,46,124, 3,124,0,95,11,116,7,106,8,160,9,116,16,161,1,114, - 184,100,4,100,5,132,0,124,2,68,0,131,1,124,0,95, - 17,100,6,83,0,41,7,122,68,70,105,108,108,32,116,104, - 101,32,99,97,99,104,101,32,111,102,32,112,111,116,101,110, - 116,105,97,108,32,109,111,100,117,108,101,115,32,97,110,100, - 32,112,97,99,107,97,103,101,115,32,102,111,114,32,116,104, - 105,115,32,100,105,114,101,99,116,111,114,121,46,114,20,0, - 0,0,114,96,0,0,0,114,87,0,0,0,99,1,0,0, - 0,0,0,0,0,0,0,0,0,2,0,0,0,4,0,0, - 0,83,0,0,0,115,20,0,0,0,104,0,124,0,93,12, - 125,1,124,1,160,0,161,0,146,2,113,4,83,0,114,10, - 0,0,0,41,1,114,130,0,0,0,41,2,114,8,0,0, - 0,90,2,102,110,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,114,19,0,0,0,58,6,0,0,114,13,0, - 0,0,122,41,70,105,108,101,70,105,110,100,101,114,46,95, - 102,105,108,108,95,99,97,99,104,101,46,60,108,111,99,97, - 108,115,62,46,60,115,101,116,99,111,109,112,62,78,41,18, - 114,65,0,0,0,114,24,0,0,0,114,30,1,0,0,114, - 81,0,0,0,114,26,1,0,0,218,15,80,101,114,109,105, - 115,115,105,111,110,69,114,114,111,114,218,18,78,111,116,65, - 68,105,114,101,99,116,111,114,121,69,114,114,111,114,114,21, - 0,0,0,114,28,0,0,0,114,29,0,0,0,114,90,1, - 0,0,114,91,1,0,0,114,125,0,0,0,114,88,0,0, - 0,114,130,0,0,0,218,3,97,100,100,114,30,0,0,0, - 114,92,1,0,0,41,9,114,142,0,0,0,114,65,0,0, - 0,114,31,1,0,0,90,21,108,111,119,101,114,95,115,117, - 102,102,105,120,95,99,111,110,116,101,110,116,115,114,66,1, - 0,0,114,140,0,0,0,114,54,1,0,0,114,41,1,0, - 0,90,8,110,101,119,95,110,97,109,101,114,10,0,0,0, - 114,10,0,0,0,114,11,0,0,0,114,94,1,0,0,29, - 6,0,0,115,34,0,0,0,0,2,6,1,2,1,22,1, - 18,3,10,3,12,1,12,7,6,1,8,1,16,1,4,1, - 18,2,4,1,12,1,6,1,12,1,122,22,70,105,108,101, - 70,105,110,100,101,114,46,95,102,105,108,108,95,99,97,99, - 104,101,99,1,0,0,0,0,0,0,0,0,0,0,0,3, - 0,0,0,3,0,0,0,7,0,0,0,115,18,0,0,0, - 135,0,135,1,102,2,100,1,100,2,132,8,125,2,124,2, - 83,0,41,3,97,20,1,0,0,65,32,99,108,97,115,115, - 32,109,101,116,104,111,100,32,119,104,105,99,104,32,114,101, - 116,117,114,110,115,32,97,32,99,108,111,115,117,114,101,32, - 116,111,32,117,115,101,32,111,110,32,115,121,115,46,112,97, - 116,104,95,104,111,111,107,10,32,32,32,32,32,32,32,32, - 119,104,105,99,104,32,119,105,108,108,32,114,101,116,117,114, - 110,32,97,110,32,105,110,115,116,97,110,99,101,32,117,115, - 105,110,103,32,116,104,101,32,115,112,101,99,105,102,105,101, - 100,32,108,111,97,100,101,114,115,32,97,110,100,32,116,104, - 101,32,112,97,116,104,10,32,32,32,32,32,32,32,32,99, - 97,108,108,101,100,32,111,110,32,116,104,101,32,99,108,111, - 115,117,114,101,46,10,10,32,32,32,32,32,32,32,32,73, - 102,32,116,104,101,32,112,97,116,104,32,99,97,108,108,101, - 100,32,111,110,32,116,104,101,32,99,108,111,115,117,114,101, - 32,105,115,32,110,111,116,32,97,32,100,105,114,101,99,116, - 111,114,121,44,32,73,109,112,111,114,116,69,114,114,111,114, - 32,105,115,10,32,32,32,32,32,32,32,32,114,97,105,115, - 101,100,46,10,10,32,32,32,32,32,32,32,32,99,1,0, - 0,0,0,0,0,0,0,0,0,0,1,0,0,0,4,0, - 0,0,19,0,0,0,115,36,0,0,0,116,0,124,0,131, - 1,115,20,116,1,100,1,124,0,100,2,141,2,130,1,136, - 0,124,0,103,1,136,1,162,1,82,0,142,0,83,0,41, - 3,122,45,80,97,116,104,32,104,111,111,107,32,102,111,114, - 32,105,109,112,111,114,116,108,105,98,46,109,97,99,104,105, - 110,101,114,121,46,70,105,108,101,70,105,110,100,101,114,46, - 122,30,111,110,108,121,32,100,105,114,101,99,116,111,114,105, - 101,115,32,97,114,101,32,115,117,112,112,111,114,116,101,100, - 114,71,0,0,0,41,2,114,82,0,0,0,114,141,0,0, - 0,114,71,0,0,0,169,2,114,216,0,0,0,114,93,1, - 0,0,114,10,0,0,0,114,11,0,0,0,218,24,112,97, - 116,104,95,104,111,111,107,95,102,111,114,95,70,105,108,101, - 70,105,110,100,101,114,70,6,0,0,115,6,0,0,0,0, - 2,8,1,12,1,122,54,70,105,108,101,70,105,110,100,101, - 114,46,112,97,116,104,95,104,111,111,107,46,60,108,111,99, - 97,108,115,62,46,112,97,116,104,95,104,111,111,107,95,102, - 111,114,95,70,105,108,101,70,105,110,100,101,114,114,10,0, - 0,0,41,3,114,216,0,0,0,114,93,1,0,0,114,99, - 1,0,0,114,10,0,0,0,114,98,1,0,0,114,11,0, - 0,0,218,9,112,97,116,104,95,104,111,111,107,60,6,0, - 0,115,4,0,0,0,0,10,14,6,122,20,70,105,108,101, - 70,105,110,100,101,114,46,112,97,116,104,95,104,111,111,107, + 94,100,4,100,5,132,0,124,2,68,0,131,1,124,0,95, + 17,100,6,83,0,100,6,83,0,41,7,122,68,70,105,108, + 108,32,116,104,101,32,99,97,99,104,101,32,111,102,32,112, + 111,116,101,110,116,105,97,108,32,109,111,100,117,108,101,115, + 32,97,110,100,32,112,97,99,107,97,103,101,115,32,102,111, + 114,32,116,104,105,115,32,100,105,114,101,99,116,111,114,121, + 46,114,14,0,0,0,114,97,0,0,0,114,88,0,0,0, + 99,1,0,0,0,0,0,0,0,0,0,0,0,2,0,0, + 0,4,0,0,0,83,0,0,0,115,20,0,0,0,104,0, + 124,0,93,6,125,1,124,1,160,0,161,0,146,2,113,2, + 83,0,114,7,0,0,0,41,1,114,131,0,0,0,41,2, + 114,5,0,0,0,90,2,102,110,114,7,0,0,0,114,7, + 0,0,0,114,8,0,0,0,114,13,0,0,0,80,6,0, + 0,115,2,0,0,0,20,0,122,41,70,105,108,101,70,105, + 110,100,101,114,46,95,102,105,108,108,95,99,97,99,104,101, + 46,60,108,111,99,97,108,115,62,46,60,115,101,116,99,111, + 109,112,62,78,41,18,114,65,0,0,0,114,18,0,0,0, + 90,7,108,105,115,116,100,105,114,114,82,0,0,0,114,87, + 1,0,0,218,15,80,101,114,109,105,115,115,105,111,110,69, + 114,114,111,114,218,18,78,111,116,65,68,105,114,101,99,116, + 111,114,121,69,114,114,111,114,114,15,0,0,0,114,25,0, + 0,0,114,26,0,0,0,114,100,1,0,0,114,101,1,0, + 0,114,126,0,0,0,114,89,0,0,0,114,131,0,0,0, + 218,3,97,100,100,114,27,0,0,0,114,102,1,0,0,41, + 9,114,143,0,0,0,114,65,0,0,0,90,8,99,111,110, + 116,101,110,116,115,90,21,108,111,119,101,114,95,115,117,102, + 102,105,120,95,99,111,110,116,101,110,116,115,114,72,1,0, + 0,114,141,0,0,0,114,56,1,0,0,114,44,1,0,0, + 90,8,110,101,119,95,110,97,109,101,114,7,0,0,0,114, + 7,0,0,0,114,8,0,0,0,114,104,1,0,0,51,6, + 0,0,115,38,0,0,0,6,2,2,1,22,1,18,1,8, + 3,2,253,12,6,12,1,6,7,8,1,16,1,4,1,18, + 1,4,2,12,1,6,1,12,1,20,1,4,255,122,22,70, + 105,108,101,70,105,110,100,101,114,46,95,102,105,108,108,95, + 99,97,99,104,101,99,1,0,0,0,0,0,0,0,0,0, + 0,0,3,0,0,0,3,0,0,0,7,0,0,0,115,18, + 0,0,0,135,0,135,1,102,2,100,1,100,2,132,8,125, + 2,124,2,83,0,41,3,97,20,1,0,0,65,32,99,108, + 97,115,115,32,109,101,116,104,111,100,32,119,104,105,99,104, + 32,114,101,116,117,114,110,115,32,97,32,99,108,111,115,117, + 114,101,32,116,111,32,117,115,101,32,111,110,32,115,121,115, + 46,112,97,116,104,95,104,111,111,107,10,32,32,32,32,32, + 32,32,32,119,104,105,99,104,32,119,105,108,108,32,114,101, + 116,117,114,110,32,97,110,32,105,110,115,116,97,110,99,101, + 32,117,115,105,110,103,32,116,104,101,32,115,112,101,99,105, + 102,105,101,100,32,108,111,97,100,101,114,115,32,97,110,100, + 32,116,104,101,32,112,97,116,104,10,32,32,32,32,32,32, + 32,32,99,97,108,108,101,100,32,111,110,32,116,104,101,32, + 99,108,111,115,117,114,101,46,10,10,32,32,32,32,32,32, + 32,32,73,102,32,116,104,101,32,112,97,116,104,32,99,97, + 108,108,101,100,32,111,110,32,116,104,101,32,99,108,111,115, + 117,114,101,32,105,115,32,110,111,116,32,97,32,100,105,114, + 101,99,116,111,114,121,44,32,73,109,112,111,114,116,69,114, + 114,111,114,32,105,115,10,32,32,32,32,32,32,32,32,114, + 97,105,115,101,100,46,10,10,32,32,32,32,32,32,32,32, 99,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0, - 0,3,0,0,0,67,0,0,0,115,12,0,0,0,100,1, - 160,0,124,0,106,1,161,1,83,0,41,2,78,122,16,70, - 105,108,101,70,105,110,100,101,114,40,123,33,114,125,41,41, - 2,114,88,0,0,0,114,65,0,0,0,114,13,1,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,114, - 64,1,0,0,78,6,0,0,115,2,0,0,0,0,1,122, - 19,70,105,108,101,70,105,110,100,101,114,46,95,95,114,101, - 112,114,95,95,41,1,78,41,15,114,149,0,0,0,114,148, - 0,0,0,114,150,0,0,0,114,151,0,0,0,114,232,0, - 0,0,114,71,1,0,0,114,167,0,0,0,114,229,0,0, - 0,114,161,0,0,0,114,83,1,0,0,114,226,0,0,0, - 114,94,1,0,0,114,230,0,0,0,114,100,1,0,0,114, - 64,1,0,0,114,10,0,0,0,114,10,0,0,0,114,10, - 0,0,0,114,11,0,0,0,114,86,1,0,0,186,5,0, - 0,115,22,0,0,0,8,2,4,7,8,16,8,4,4,2, - 8,12,8,5,10,51,8,31,2,1,10,17,114,86,1,0, - 0,99,4,0,0,0,0,0,0,0,0,0,0,0,6,0, - 0,0,8,0,0,0,67,0,0,0,115,144,0,0,0,124, - 0,160,0,100,1,161,1,125,4,124,0,160,0,100,2,161, - 1,125,5,124,4,115,66,124,5,114,36,124,5,106,1,125, - 4,110,30,124,2,124,3,107,2,114,56,116,2,124,1,124, - 2,131,2,125,4,110,10,116,3,124,1,124,2,131,2,125, - 4,124,5,115,84,116,4,124,1,124,2,124,4,100,3,141, - 3,125,5,122,36,124,5,124,0,100,2,60,0,124,4,124, - 0,100,1,60,0,124,2,124,0,100,4,60,0,124,3,124, - 0,100,5,60,0,87,0,110,18,4,0,116,5,121,138,1, - 0,1,0,1,0,89,0,110,2,48,0,100,0,83,0,41, - 6,78,218,10,95,95,108,111,97,100,101,114,95,95,218,8, - 95,95,115,112,101,99,95,95,114,87,1,0,0,90,8,95, - 95,102,105,108,101,95,95,90,10,95,95,99,97,99,104,101, - 100,95,95,41,6,218,3,103,101,116,114,164,0,0,0,114, - 39,1,0,0,114,32,1,0,0,114,213,0,0,0,218,9, - 69,120,99,101,112,116,105,111,110,41,6,90,2,110,115,114, - 140,0,0,0,90,8,112,97,116,104,110,97,109,101,90,9, - 99,112,97,116,104,110,97,109,101,114,164,0,0,0,114,210, - 0,0,0,114,10,0,0,0,114,10,0,0,0,114,11,0, - 0,0,218,14,95,102,105,120,95,117,112,95,109,111,100,117, - 108,101,84,6,0,0,115,34,0,0,0,0,2,10,1,10, - 1,4,1,4,1,8,1,8,1,12,2,10,1,4,1,14, - 1,2,1,8,1,8,1,8,1,12,1,12,2,114,105,1, - 0,0,99,0,0,0,0,0,0,0,0,0,0,0,0,3, - 0,0,0,3,0,0,0,67,0,0,0,115,38,0,0,0, - 116,0,116,1,160,2,161,0,102,2,125,0,116,3,116,4, - 102,2,125,1,116,5,116,6,102,2,125,2,124,0,124,1, - 124,2,103,3,83,0,41,1,122,95,82,101,116,117,114,110, - 115,32,97,32,108,105,115,116,32,111,102,32,102,105,108,101, - 45,98,97,115,101,100,32,109,111,100,117,108,101,32,108,111, - 97,100,101,114,115,46,10,10,32,32,32,32,69,97,99,104, - 32,105,116,101,109,32,105,115,32,97,32,116,117,112,108,101, - 32,40,108,111,97,100,101,114,44,32,115,117,102,102,105,120, - 101,115,41,46,10,32,32,32,32,41,7,114,19,1,0,0, - 114,187,0,0,0,218,18,101,120,116,101,110,115,105,111,110, - 95,115,117,102,102,105,120,101,115,114,32,1,0,0,114,126, - 0,0,0,114,39,1,0,0,114,112,0,0,0,41,3,90, - 10,101,120,116,101,110,115,105,111,110,115,90,6,115,111,117, - 114,99,101,90,8,98,121,116,101,99,111,100,101,114,10,0, - 0,0,114,10,0,0,0,114,11,0,0,0,114,208,0,0, - 0,107,6,0,0,115,8,0,0,0,0,5,12,1,8,1, - 8,1,114,208,0,0,0,99,1,0,0,0,0,0,0,0, - 0,0,0,0,10,0,0,0,9,0,0,0,67,0,0,0, - 115,132,1,0,0,124,0,97,0,116,0,106,1,97,1,116, - 0,106,2,97,2,116,1,106,3,116,4,25,0,125,1,100, - 1,100,2,103,1,102,2,100,3,100,4,100,2,103,2,102, - 2,102,2,125,2,124,2,68,0,93,108,92,2,125,3,125, - 4,116,5,100,5,100,6,132,0,124,4,68,0,131,1,131, - 1,115,82,74,0,130,1,124,4,100,7,25,0,125,5,124, - 3,116,1,106,3,118,0,114,116,116,1,106,3,124,3,25, - 0,125,6,1,0,113,170,113,52,122,20,116,0,160,6,124, - 3,161,1,125,6,87,0,1,0,113,170,87,0,113,52,4, - 0,116,7,121,158,1,0,1,0,1,0,89,0,113,52,89, - 0,113,52,48,0,113,52,116,7,100,8,131,1,130,1,116, - 8,124,1,100,9,124,6,131,3,1,0,116,8,124,1,100, - 10,124,5,131,3,1,0,116,8,124,1,100,11,100,12,160, - 9,124,4,161,1,131,3,1,0,116,8,124,1,100,13,100, - 14,100,15,132,0,124,4,68,0,131,1,131,3,1,0,103, - 0,100,16,162,1,125,7,124,3,100,3,107,2,144,1,114, - 6,124,7,160,10,100,17,161,1,1,0,124,7,68,0,93, - 52,125,8,124,8,116,1,106,3,118,1,144,1,114,38,116, - 0,160,6,124,8,161,1,125,9,110,10,116,1,106,3,124, - 8,25,0,125,9,116,8,124,1,124,8,124,9,131,3,1, - 0,144,1,113,10,116,8,124,1,100,18,116,11,131,0,131, - 3,1,0,116,12,160,13,116,2,160,14,161,0,161,1,1, - 0,124,3,100,3,107,2,144,1,114,128,116,15,160,10,100, - 19,161,1,1,0,100,20,116,12,118,0,144,1,114,128,100, - 21,116,16,95,17,100,22,83,0,41,23,122,205,83,101,116, - 117,112,32,116,104,101,32,112,97,116,104,45,98,97,115,101, - 100,32,105,109,112,111,114,116,101,114,115,32,102,111,114,32, - 105,109,112,111,114,116,108,105,98,32,98,121,32,105,109,112, - 111,114,116,105,110,103,32,110,101,101,100,101,100,10,32,32, - 32,32,98,117,105,108,116,45,105,110,32,109,111,100,117,108, - 101,115,32,97,110,100,32,105,110,106,101,99,116,105,110,103, - 32,116,104,101,109,32,105,110,116,111,32,116,104,101,32,103, - 108,111,98,97,108,32,110,97,109,101,115,112,97,99,101,46, - 10,10,32,32,32,32,79,116,104,101,114,32,99,111,109,112, - 111,110,101,110,116,115,32,97,114,101,32,101,120,116,114,97, - 99,116,101,100,32,102,114,111,109,32,116,104,101,32,99,111, - 114,101,32,98,111,111,116,115,116,114,97,112,32,109,111,100, - 117,108,101,46,10,10,32,32,32,32,218,5,112,111,115,105, - 120,114,2,0,0,0,218,2,110,116,114,1,0,0,0,99, + 0,4,0,0,0,19,0,0,0,115,36,0,0,0,116,0, + 124,0,131,1,115,10,116,1,100,1,124,0,100,2,141,2, + 130,1,136,0,124,0,103,1,136,1,162,1,82,0,142,0, + 83,0,41,3,122,45,80,97,116,104,32,104,111,111,107,32, + 102,111,114,32,105,109,112,111,114,116,108,105,98,46,109,97, + 99,104,105,110,101,114,121,46,70,105,108,101,70,105,110,100, + 101,114,46,122,30,111,110,108,121,32,100,105,114,101,99,116, + 111,114,105,101,115,32,97,114,101,32,115,117,112,112,111,114, + 116,101,100,114,71,0,0,0,41,2,114,83,0,0,0,114, + 142,0,0,0,114,71,0,0,0,169,2,114,221,0,0,0, + 114,103,1,0,0,114,7,0,0,0,114,8,0,0,0,218, + 24,112,97,116,104,95,104,111,111,107,95,102,111,114,95,70, + 105,108,101,70,105,110,100,101,114,92,6,0,0,115,6,0, + 0,0,8,2,12,1,16,1,122,54,70,105,108,101,70,105, + 110,100,101,114,46,112,97,116,104,95,104,111,111,107,46,60, + 108,111,99,97,108,115,62,46,112,97,116,104,95,104,111,111, + 107,95,102,111,114,95,70,105,108,101,70,105,110,100,101,114, + 114,7,0,0,0,41,3,114,221,0,0,0,114,103,1,0, + 0,114,109,1,0,0,114,7,0,0,0,114,108,1,0,0, + 114,8,0,0,0,218,9,112,97,116,104,95,104,111,111,107, + 82,6,0,0,115,4,0,0,0,14,10,4,6,122,20,70, + 105,108,101,70,105,110,100,101,114,46,112,97,116,104,95,104, + 111,111,107,99,1,0,0,0,0,0,0,0,0,0,0,0, + 1,0,0,0,3,0,0,0,67,0,0,0,114,69,1,0, + 0,41,2,78,122,16,70,105,108,101,70,105,110,100,101,114, + 40,123,33,114,125,41,41,2,114,89,0,0,0,114,65,0, + 0,0,114,21,1,0,0,114,7,0,0,0,114,7,0,0, + 0,114,8,0,0,0,114,70,1,0,0,100,6,0,0,114, + 63,1,0,0,122,19,70,105,108,101,70,105,110,100,101,114, + 46,95,95,114,101,112,114,95,95,114,69,0,0,0,41,15, + 114,150,0,0,0,114,149,0,0,0,114,151,0,0,0,114, + 152,0,0,0,114,236,0,0,0,114,80,1,0,0,114,167, + 0,0,0,114,229,0,0,0,114,161,0,0,0,114,93,1, + 0,0,114,226,0,0,0,114,104,1,0,0,114,234,0,0, + 0,114,110,1,0,0,114,70,1,0,0,114,7,0,0,0, + 114,7,0,0,0,114,7,0,0,0,114,8,0,0,0,114, + 96,1,0,0,205,5,0,0,115,24,0,0,0,8,0,4, + 2,8,7,8,16,4,4,8,2,8,15,10,5,8,51,2, + 31,10,1,12,17,114,96,1,0,0,99,4,0,0,0,0, + 0,0,0,0,0,0,0,6,0,0,0,8,0,0,0,67, + 0,0,0,115,144,0,0,0,124,0,160,0,100,1,161,1, + 125,4,124,0,160,0,100,2,161,1,125,5,124,4,115,33, + 124,5,114,18,124,5,106,1,125,4,110,15,124,2,124,3, + 107,2,114,28,116,2,124,1,124,2,131,2,125,4,110,5, + 116,3,124,1,124,2,131,2,125,4,124,5,115,42,116,4, + 124,1,124,2,124,4,100,3,141,3,125,5,122,19,124,5, + 124,0,100,2,60,0,124,4,124,0,100,1,60,0,124,2, + 124,0,100,4,60,0,124,3,124,0,100,5,60,0,87,0, + 100,0,83,0,4,0,116,5,121,71,1,0,1,0,1,0, + 89,0,100,0,83,0,119,0,41,6,78,218,10,95,95,108, + 111,97,100,101,114,95,95,218,8,95,95,115,112,101,99,95, + 95,114,97,1,0,0,90,8,95,95,102,105,108,101,95,95, + 90,10,95,95,99,97,99,104,101,100,95,95,41,6,218,3, + 103,101,116,114,164,0,0,0,114,41,1,0,0,114,34,1, + 0,0,114,213,0,0,0,218,9,69,120,99,101,112,116,105, + 111,110,41,6,90,2,110,115,114,141,0,0,0,90,8,112, + 97,116,104,110,97,109,101,90,9,99,112,97,116,104,110,97, + 109,101,114,164,0,0,0,114,210,0,0,0,114,7,0,0, + 0,114,7,0,0,0,114,8,0,0,0,218,14,95,102,105, + 120,95,117,112,95,109,111,100,117,108,101,106,6,0,0,115, + 36,0,0,0,10,2,10,1,4,1,4,1,8,1,8,1, + 12,1,10,2,4,1,14,1,2,1,8,1,8,1,8,1, + 14,1,12,1,6,2,2,254,114,115,1,0,0,99,0,0, + 0,0,0,0,0,0,0,0,0,0,3,0,0,0,3,0, + 0,0,67,0,0,0,115,38,0,0,0,116,0,116,1,160, + 2,161,0,102,2,125,0,116,3,116,4,102,2,125,1,116, + 5,116,6,102,2,125,2,124,0,124,1,124,2,103,3,83, + 0,41,1,122,95,82,101,116,117,114,110,115,32,97,32,108, + 105,115,116,32,111,102,32,102,105,108,101,45,98,97,115,101, + 100,32,109,111,100,117,108,101,32,108,111,97,100,101,114,115, + 46,10,10,32,32,32,32,69,97,99,104,32,105,116,101,109, + 32,105,115,32,97,32,116,117,112,108,101,32,40,108,111,97, + 100,101,114,44,32,115,117,102,102,105,120,101,115,41,46,10, + 32,32,32,32,41,7,114,30,1,0,0,114,187,0,0,0, + 218,18,101,120,116,101,110,115,105,111,110,95,115,117,102,102, + 105,120,101,115,114,34,1,0,0,114,127,0,0,0,114,41, + 1,0,0,114,113,0,0,0,41,3,90,10,101,120,116,101, + 110,115,105,111,110,115,90,6,115,111,117,114,99,101,90,8, + 98,121,116,101,99,111,100,101,114,7,0,0,0,114,7,0, + 0,0,114,8,0,0,0,114,208,0,0,0,129,6,0,0, + 115,8,0,0,0,12,5,8,1,8,1,10,1,114,208,0, + 0,0,99,1,0,0,0,0,0,0,0,0,0,0,0,1, + 0,0,0,1,0,0,0,67,0,0,0,115,8,0,0,0, + 124,0,97,0,100,0,83,0,114,69,0,0,0,41,1,114, + 159,0,0,0,41,1,218,17,95,98,111,111,116,115,116,114, + 97,112,95,109,111,100,117,108,101,114,7,0,0,0,114,7, + 0,0,0,114,8,0,0,0,218,21,95,115,101,116,95,98, + 111,111,116,115,116,114,97,112,95,109,111,100,117,108,101,140, + 6,0,0,115,2,0,0,0,8,2,114,118,1,0,0,99, 1,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0, - 3,0,0,0,115,0,0,0,115,26,0,0,0,124,0,93, - 18,125,1,116,0,124,1,131,1,100,0,107,2,86,0,1, - 0,113,2,100,1,83,0,114,3,0,0,0,114,5,0,0, - 0,114,7,0,0,0,114,10,0,0,0,114,10,0,0,0, - 114,11,0,0,0,114,12,0,0,0,136,6,0,0,114,13, - 0,0,0,122,25,95,115,101,116,117,112,46,60,108,111,99, - 97,108,115,62,46,60,103,101,110,101,120,112,114,62,114,0, - 0,0,0,122,30,105,109,112,111,114,116,108,105,98,32,114, - 101,113,117,105,114,101,115,32,112,111,115,105,120,32,111,114, - 32,110,116,114,24,0,0,0,114,59,0,0,0,114,50,0, - 0,0,114,14,0,0,0,218,20,95,112,97,116,104,115,101, - 112,115,95,119,105,116,104,95,99,111,108,111,110,99,1,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,4,0, - 0,0,83,0,0,0,115,22,0,0,0,104,0,124,0,93, - 14,125,1,100,0,124,1,155,0,157,2,146,2,113,4,83, - 0,114,15,0,0,0,114,10,0,0,0,114,17,0,0,0, - 114,10,0,0,0,114,10,0,0,0,114,11,0,0,0,114, - 19,0,0,0,153,6,0,0,114,13,0,0,0,122,25,95, - 115,101,116,117,112,46,60,108,111,99,97,108,115,62,46,60, - 115,101,116,99,111,109,112,62,41,3,114,90,0,0,0,114, - 98,0,0,0,114,184,0,0,0,114,215,0,0,0,114,27, - 0,0,0,122,4,46,112,121,119,122,6,95,100,46,112,121, - 100,84,78,41,18,114,158,0,0,0,114,21,0,0,0,114, - 187,0,0,0,114,56,1,0,0,114,149,0,0,0,218,3, - 97,108,108,90,18,95,98,117,105,108,116,105,110,95,102,114, - 111,109,95,110,97,109,101,114,141,0,0,0,114,153,0,0, - 0,114,62,0,0,0,114,61,0,0,0,114,32,0,0,0, - 114,44,1,0,0,114,191,0,0,0,114,106,1,0,0,114, - 126,0,0,0,114,214,0,0,0,114,218,0,0,0,41,10, - 218,17,95,98,111,111,116,115,116,114,97,112,95,109,111,100, - 117,108,101,90,11,115,101,108,102,95,109,111,100,117,108,101, - 90,10,111,115,95,100,101,116,97,105,108,115,90,10,98,117, - 105,108,116,105,110,95,111,115,114,50,0,0,0,114,59,0, - 0,0,90,9,111,115,95,109,111,100,117,108,101,90,13,98, - 117,105,108,116,105,110,95,110,97,109,101,115,90,12,98,117, - 105,108,116,105,110,95,110,97,109,101,90,14,98,117,105,108, - 116,105,110,95,109,111,100,117,108,101,114,10,0,0,0,114, - 10,0,0,0,114,11,0,0,0,218,6,95,115,101,116,117, - 112,118,6,0,0,115,70,0,0,0,0,8,4,1,6,1, - 6,2,10,3,22,1,12,2,22,1,8,1,10,1,10,1, - 6,2,2,1,10,1,10,1,12,1,12,2,8,2,12,1, - 12,1,18,1,22,3,8,1,10,1,10,1,8,1,12,1, - 12,2,10,1,16,3,14,1,14,1,10,1,10,1,10,1, - 114,112,1,0,0,99,1,0,0,0,0,0,0,0,0,0, - 0,0,2,0,0,0,4,0,0,0,67,0,0,0,115,50, - 0,0,0,116,0,124,0,131,1,1,0,116,1,131,0,125, - 1,116,2,106,3,160,4,116,5,106,6,124,1,142,0,103, - 1,161,1,1,0,116,2,106,7,160,8,116,9,161,1,1, - 0,100,1,83,0,41,2,122,41,73,110,115,116,97,108,108, - 32,116,104,101,32,112,97,116,104,45,98,97,115,101,100,32, - 105,109,112,111,114,116,32,99,111,109,112,111,110,101,110,116, - 115,46,78,41,10,114,112,1,0,0,114,208,0,0,0,114, - 21,0,0,0,114,76,1,0,0,114,191,0,0,0,114,86, - 1,0,0,114,100,1,0,0,218,9,109,101,116,97,95,112, - 97,116,104,114,61,0,0,0,114,70,1,0,0,41,2,114, - 111,1,0,0,90,17,115,117,112,112,111,114,116,101,100,95, - 108,111,97,100,101,114,115,114,10,0,0,0,114,10,0,0, - 0,114,11,0,0,0,218,8,95,105,110,115,116,97,108,108, - 175,6,0,0,115,8,0,0,0,0,2,8,1,6,1,20, - 1,114,114,1,0,0,41,1,114,86,0,0,0,41,1,78, - 41,3,78,78,78,41,2,114,0,0,0,0,114,0,0,0, - 0,41,1,84,41,1,78,41,1,78,41,81,114,151,0,0, - 0,114,187,0,0,0,114,90,0,0,0,114,21,0,0,0, - 114,98,0,0,0,114,184,0,0,0,114,28,0,0,0,90, - 11,95,77,83,95,87,73,78,68,79,87,83,114,108,1,0, - 0,114,24,0,0,0,114,215,0,0,0,114,107,1,0,0, - 114,50,0,0,0,114,110,1,0,0,114,59,0,0,0,114, - 135,0,0,0,114,57,0,0,0,114,62,0,0,0,114,109, - 1,0,0,114,31,0,0,0,90,37,95,67,65,83,69,95, - 73,78,83,69,78,83,73,84,73,86,69,95,80,76,65,84, - 70,79,82,77,83,95,66,89,84,69,83,95,75,69,89,114, - 30,0,0,0,114,32,0,0,0,114,39,0,0,0,114,44, - 0,0,0,114,46,0,0,0,114,67,0,0,0,114,74,0, - 0,0,114,75,0,0,0,114,79,0,0,0,114,80,0,0, - 0,114,82,0,0,0,114,85,0,0,0,114,94,0,0,0, - 218,4,116,121,112,101,218,8,95,95,99,111,100,101,95,95, - 114,186,0,0,0,114,37,0,0,0,114,172,0,0,0,114, - 36,0,0,0,114,41,0,0,0,114,3,1,0,0,114,115, - 0,0,0,114,111,0,0,0,114,126,0,0,0,114,112,0, - 0,0,90,23,68,69,66,85,71,95,66,89,84,69,67,79, - 68,69,95,83,85,70,70,73,88,69,83,90,27,79,80,84, - 73,77,73,90,69,68,95,66,89,84,69,67,79,68,69,95, - 83,85,70,70,73,88,69,83,114,120,0,0,0,114,127,0, - 0,0,114,134,0,0,0,114,136,0,0,0,114,138,0,0, - 0,114,160,0,0,0,114,167,0,0,0,114,176,0,0,0, - 114,180,0,0,0,114,182,0,0,0,114,189,0,0,0,114, - 194,0,0,0,114,195,0,0,0,114,200,0,0,0,218,6, - 111,98,106,101,99,116,114,209,0,0,0,114,213,0,0,0, - 114,214,0,0,0,114,231,0,0,0,114,244,0,0,0,114, - 6,1,0,0,114,32,1,0,0,114,39,1,0,0,114,44, - 1,0,0,114,19,1,0,0,114,45,1,0,0,114,68,1, - 0,0,114,70,1,0,0,114,86,1,0,0,114,105,1,0, - 0,114,208,0,0,0,114,112,1,0,0,114,114,1,0,0, - 114,10,0,0,0,114,10,0,0,0,114,10,0,0,0,114, - 11,0,0,0,218,8,60,109,111,100,117,108,101,62,1,0, - 0,0,115,170,0,0,0,4,22,8,1,8,1,8,1,8, - 1,8,3,10,1,4,1,8,1,10,2,8,3,4,1,10, - 2,6,2,22,1,8,1,8,1,10,1,14,4,4,1,4, - 1,2,1,2,255,4,4,8,17,8,5,8,5,8,6,4, - 1,10,30,8,6,8,8,8,10,8,9,8,5,8,7,6, - 1,10,8,8,5,10,22,10,127,0,20,16,1,12,2,4, - 1,4,2,6,2,6,2,8,2,16,71,8,40,8,19,8, - 12,8,12,8,28,8,17,8,33,8,28,8,24,10,13,10, - 10,10,11,8,14,6,3,4,1,2,255,12,68,14,64,14, - 29,16,127,0,17,14,72,18,45,18,26,4,3,18,58,14, - 69,14,42,14,127,0,23,14,127,0,27,10,23,8,11,8, - 57, + 4,0,0,0,67,0,0,0,115,50,0,0,0,116,0,124, + 0,131,1,1,0,116,1,131,0,125,1,116,2,106,3,160, + 4,116,5,106,6,124,1,142,0,103,1,161,1,1,0,116, + 2,106,7,160,8,116,9,161,1,1,0,100,1,83,0,41, + 2,122,41,73,110,115,116,97,108,108,32,116,104,101,32,112, + 97,116,104,45,98,97,115,101,100,32,105,109,112,111,114,116, + 32,99,111,109,112,111,110,101,110,116,115,46,78,41,10,114, + 118,1,0,0,114,208,0,0,0,114,15,0,0,0,114,85, + 1,0,0,114,191,0,0,0,114,96,1,0,0,114,110,1, + 0,0,218,9,109,101,116,97,95,112,97,116,104,114,61,0, + 0,0,114,79,1,0,0,41,2,114,117,1,0,0,90,17, + 115,117,112,112,111,114,116,101,100,95,108,111,97,100,101,114, + 115,114,7,0,0,0,114,7,0,0,0,114,8,0,0,0, + 218,8,95,105,110,115,116,97,108,108,145,6,0,0,115,8, + 0,0,0,8,2,6,1,20,1,16,1,114,120,1,0,0, + 41,1,114,87,0,0,0,114,69,0,0,0,41,3,78,78, + 78,41,2,114,0,0,0,0,114,0,0,0,0,41,1,84, + 41,85,114,152,0,0,0,114,159,0,0,0,114,187,0,0, + 0,114,91,0,0,0,114,15,0,0,0,114,99,0,0,0, + 114,184,0,0,0,114,25,0,0,0,114,231,0,0,0,90, + 2,110,116,114,18,0,0,0,114,215,0,0,0,90,5,112, + 111,115,105,120,114,50,0,0,0,218,3,97,108,108,114,59, + 0,0,0,114,136,0,0,0,114,57,0,0,0,114,62,0, + 0,0,90,20,95,112,97,116,104,115,101,112,115,95,119,105, + 116,104,95,99,111,108,111,110,114,28,0,0,0,90,37,95, + 67,65,83,69,95,73,78,83,69,78,83,73,84,73,86,69, + 95,80,76,65,84,70,79,82,77,83,95,66,89,84,69,83, + 95,75,69,89,114,27,0,0,0,114,29,0,0,0,114,21, + 0,0,0,114,36,0,0,0,114,42,0,0,0,114,45,0, + 0,0,114,67,0,0,0,114,74,0,0,0,114,75,0,0, + 0,114,79,0,0,0,114,80,0,0,0,114,83,0,0,0, + 114,86,0,0,0,114,95,0,0,0,218,4,116,121,112,101, + 218,8,95,95,99,111,100,101,95,95,114,186,0,0,0,114, + 34,0,0,0,114,172,0,0,0,114,33,0,0,0,114,39, + 0,0,0,114,8,1,0,0,114,116,0,0,0,114,112,0, + 0,0,114,127,0,0,0,114,61,0,0,0,114,116,1,0, + 0,114,232,0,0,0,114,113,0,0,0,90,23,68,69,66, + 85,71,95,66,89,84,69,67,79,68,69,95,83,85,70,70, + 73,88,69,83,90,27,79,80,84,73,77,73,90,69,68,95, + 66,89,84,69,67,79,68,69,95,83,85,70,70,73,88,69, + 83,114,121,0,0,0,114,128,0,0,0,114,135,0,0,0, + 114,137,0,0,0,114,139,0,0,0,114,160,0,0,0,114, + 167,0,0,0,114,176,0,0,0,114,180,0,0,0,114,182, + 0,0,0,114,189,0,0,0,114,194,0,0,0,114,195,0, + 0,0,114,200,0,0,0,218,6,111,98,106,101,99,116,114, + 209,0,0,0,114,213,0,0,0,114,214,0,0,0,114,235, + 0,0,0,114,249,0,0,0,114,11,1,0,0,114,34,1, + 0,0,114,41,1,0,0,114,30,1,0,0,114,47,1,0, + 0,114,75,1,0,0,114,79,1,0,0,114,96,1,0,0, + 114,115,1,0,0,114,208,0,0,0,114,118,1,0,0,114, + 120,1,0,0,114,7,0,0,0,114,7,0,0,0,114,7, + 0,0,0,114,8,0,0,0,218,8,60,109,111,100,117,108, + 101,62,1,0,0,0,115,180,0,0,0,4,0,4,22,8, + 3,8,1,8,1,8,1,8,1,10,3,4,1,8,1,10, + 1,8,2,4,3,10,1,6,2,22,2,8,1,8,1,10, + 1,14,1,4,4,4,1,2,1,2,1,4,255,8,4,6, + 16,8,3,8,5,8,5,4,6,10,1,8,30,8,6,8, + 8,8,10,8,9,8,5,4,7,10,1,8,8,10,5,10, + 22,0,127,16,30,12,1,4,2,4,1,6,2,4,1,10, + 1,8,2,6,2,8,2,16,2,8,71,8,40,8,19,8, + 12,8,12,8,31,8,20,8,33,8,28,10,24,10,13,10, + 10,8,11,6,14,4,3,2,1,12,255,14,73,14,67,16, + 30,0,127,14,17,18,50,18,45,18,25,14,53,14,69,14, + 49,0,127,14,32,0,127,10,30,8,23,8,11,12,5, }; diff --git a/contrib/tools/python3/src/Python/importlib_zipimport.h b/contrib/tools/python3/src/Python/importlib_zipimport.h index 373b1366bde..3c476841a8c 100644 --- a/contrib/tools/python3/src/Python/importlib_zipimport.h +++ b/contrib/tools/python3/src/Python/importlib_zipimport.h @@ -1,257 +1,318 @@ /* Auto-generated by Programs/_freeze_importlib.c */ const unsigned char _Py_M__zipimport[] = { 99,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,4,0,0,0,64,0,0,0,115,82,1,0,0,100,0, + 0,4,0,0,0,64,0,0,0,115,80,1,0,0,100,0, 90,0,100,1,100,2,108,1,90,2,100,1,100,3,108,1, 109,3,90,3,109,4,90,4,1,0,100,1,100,2,108,5, 90,6,100,1,100,2,108,7,90,7,100,1,100,2,108,8, 90,8,100,1,100,2,108,9,90,9,100,1,100,2,108,10, - 90,10,100,1,100,2,108,11,90,11,100,4,100,5,103,2, - 90,12,101,2,106,13,90,13,101,2,106,14,100,6,100,2, - 133,2,25,0,90,15,71,0,100,7,100,4,132,0,100,4, - 101,16,131,3,90,17,105,0,90,18,101,19,101,10,131,1, - 90,20,100,8,90,21,100,9,90,22,100,10,90,23,71,0, - 100,11,100,5,132,0,100,5,131,2,90,24,101,13,100,12, - 23,0,100,13,100,13,102,3,101,13,100,14,23,0,100,15, - 100,13,102,3,100,16,100,17,102,4,90,25,100,18,100,19, - 132,0,90,26,100,20,100,21,132,0,90,27,100,22,100,23, - 132,0,90,28,100,24,100,25,132,0,90,29,100,26,90,30, - 100,15,97,31,100,27,100,28,132,0,90,32,100,29,100,30, - 132,0,90,33,100,31,100,32,132,0,90,34,100,33,100,34, - 132,0,90,35,101,19,101,35,106,36,131,1,90,37,100,35, - 100,36,132,0,90,38,100,37,100,38,132,0,90,39,100,39, - 100,40,132,0,90,40,100,41,100,42,132,0,90,41,100,43, - 100,44,132,0,90,42,100,45,100,46,132,0,90,43,71,0, - 100,47,100,48,132,0,100,48,131,2,90,44,100,2,83,0, - 41,49,97,80,2,0,0,122,105,112,105,109,112,111,114,116, - 32,112,114,111,118,105,100,101,115,32,115,117,112,112,111,114, - 116,32,102,111,114,32,105,109,112,111,114,116,105,110,103,32, - 80,121,116,104,111,110,32,109,111,100,117,108,101,115,32,102, - 114,111,109,32,90,105,112,32,97,114,99,104,105,118,101,115, - 46,10,10,84,104,105,115,32,109,111,100,117,108,101,32,101, - 120,112,111,114,116,115,32,116,104,114,101,101,32,111,98,106, - 101,99,116,115,58,10,45,32,122,105,112,105,109,112,111,114, - 116,101,114,58,32,97,32,99,108,97,115,115,59,32,105,116, - 115,32,99,111,110,115,116,114,117,99,116,111,114,32,116,97, - 107,101,115,32,97,32,112,97,116,104,32,116,111,32,97,32, - 90,105,112,32,97,114,99,104,105,118,101,46,10,45,32,90, - 105,112,73,109,112,111,114,116,69,114,114,111,114,58,32,101, - 120,99,101,112,116,105,111,110,32,114,97,105,115,101,100,32, - 98,121,32,122,105,112,105,109,112,111,114,116,101,114,32,111, - 98,106,101,99,116,115,46,32,73,116,39,115,32,97,10,32, - 32,115,117,98,99,108,97,115,115,32,111,102,32,73,109,112, - 111,114,116,69,114,114,111,114,44,32,115,111,32,105,116,32, - 99,97,110,32,98,101,32,99,97,117,103,104,116,32,97,115, - 32,73,109,112,111,114,116,69,114,114,111,114,44,32,116,111, - 111,46,10,45,32,95,122,105,112,95,100,105,114,101,99,116, - 111,114,121,95,99,97,99,104,101,58,32,97,32,100,105,99, - 116,44,32,109,97,112,112,105,110,103,32,97,114,99,104,105, - 118,101,32,112,97,116,104,115,32,116,111,32,122,105,112,32, - 100,105,114,101,99,116,111,114,121,10,32,32,105,110,102,111, - 32,100,105,99,116,115,44,32,97,115,32,117,115,101,100,32, - 105,110,32,122,105,112,105,109,112,111,114,116,101,114,46,95, - 102,105,108,101,115,46,10,10,73,116,32,105,115,32,117,115, - 117,97,108,108,121,32,110,111,116,32,110,101,101,100,101,100, - 32,116,111,32,117,115,101,32,116,104,101,32,122,105,112,105, - 109,112,111,114,116,32,109,111,100,117,108,101,32,101,120,112, - 108,105,99,105,116,108,121,59,32,105,116,32,105,115,10,117, - 115,101,100,32,98,121,32,116,104,101,32,98,117,105,108,116, - 105,110,32,105,109,112,111,114,116,32,109,101,99,104,97,110, - 105,115,109,32,102,111,114,32,115,121,115,46,112,97,116,104, - 32,105,116,101,109,115,32,116,104,97,116,32,97,114,101,32, - 112,97,116,104,115,10,116,111,32,90,105,112,32,97,114,99, - 104,105,118,101,115,46,10,233,0,0,0,0,78,41,2,218, - 14,95,117,110,112,97,99,107,95,117,105,110,116,49,54,218, - 14,95,117,110,112,97,99,107,95,117,105,110,116,51,50,218, - 14,90,105,112,73,109,112,111,114,116,69,114,114,111,114,218, - 11,122,105,112,105,109,112,111,114,116,101,114,233,1,0,0, - 0,99,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,1,0,0,0,64,0,0,0,115,12,0,0,0,101, - 0,90,1,100,0,90,2,100,1,83,0,41,2,114,3,0, - 0,0,78,41,3,218,8,95,95,110,97,109,101,95,95,218, - 10,95,95,109,111,100,117,108,101,95,95,218,12,95,95,113, - 117,97,108,110,97,109,101,95,95,169,0,114,9,0,0,0, - 114,9,0,0,0,250,18,60,102,114,111,122,101,110,32,122, - 105,112,105,109,112,111,114,116,62,114,3,0,0,0,33,0, - 0,0,115,2,0,0,0,8,1,233,22,0,0,0,115,4, + 90,10,100,1,100,2,108,11,90,11,100,1,100,2,108,12, + 90,12,100,4,100,5,103,2,90,13,101,2,106,14,90,14, + 101,2,106,15,100,6,100,2,133,2,25,0,90,16,71,0, + 100,7,100,4,132,0,100,4,101,17,131,3,90,18,105,0, + 90,19,101,20,101,10,131,1,90,21,100,8,90,22,100,9, + 90,23,100,10,90,24,71,0,100,11,100,5,132,0,100,5, + 101,2,106,25,131,3,90,26,101,14,100,12,23,0,100,13, + 100,13,102,3,101,14,100,14,23,0,100,15,100,13,102,3, + 100,16,100,17,102,4,90,27,100,18,100,19,132,0,90,28, + 100,20,100,21,132,0,90,29,100,22,100,23,132,0,90,30, + 100,24,100,25,132,0,90,31,100,26,90,32,100,15,97,33, + 100,27,100,28,132,0,90,34,100,29,100,30,132,0,90,35, + 100,31,100,32,132,0,90,36,100,33,100,34,132,0,90,37, + 101,20,101,37,106,38,131,1,90,39,100,35,100,36,132,0, + 90,40,100,37,100,38,132,0,90,41,100,39,100,40,132,0, + 90,42,100,41,100,42,132,0,90,43,100,43,100,44,132,0, + 90,44,100,45,100,46,132,0,90,45,100,2,83,0,41,47, + 97,80,2,0,0,122,105,112,105,109,112,111,114,116,32,112, + 114,111,118,105,100,101,115,32,115,117,112,112,111,114,116,32, + 102,111,114,32,105,109,112,111,114,116,105,110,103,32,80,121, + 116,104,111,110,32,109,111,100,117,108,101,115,32,102,114,111, + 109,32,90,105,112,32,97,114,99,104,105,118,101,115,46,10, + 10,84,104,105,115,32,109,111,100,117,108,101,32,101,120,112, + 111,114,116,115,32,116,104,114,101,101,32,111,98,106,101,99, + 116,115,58,10,45,32,122,105,112,105,109,112,111,114,116,101, + 114,58,32,97,32,99,108,97,115,115,59,32,105,116,115,32, + 99,111,110,115,116,114,117,99,116,111,114,32,116,97,107,101, + 115,32,97,32,112,97,116,104,32,116,111,32,97,32,90,105, + 112,32,97,114,99,104,105,118,101,46,10,45,32,90,105,112, + 73,109,112,111,114,116,69,114,114,111,114,58,32,101,120,99, + 101,112,116,105,111,110,32,114,97,105,115,101,100,32,98,121, + 32,122,105,112,105,109,112,111,114,116,101,114,32,111,98,106, + 101,99,116,115,46,32,73,116,39,115,32,97,10,32,32,115, + 117,98,99,108,97,115,115,32,111,102,32,73,109,112,111,114, + 116,69,114,114,111,114,44,32,115,111,32,105,116,32,99,97, + 110,32,98,101,32,99,97,117,103,104,116,32,97,115,32,73, + 109,112,111,114,116,69,114,114,111,114,44,32,116,111,111,46, + 10,45,32,95,122,105,112,95,100,105,114,101,99,116,111,114, + 121,95,99,97,99,104,101,58,32,97,32,100,105,99,116,44, + 32,109,97,112,112,105,110,103,32,97,114,99,104,105,118,101, + 32,112,97,116,104,115,32,116,111,32,122,105,112,32,100,105, + 114,101,99,116,111,114,121,10,32,32,105,110,102,111,32,100, + 105,99,116,115,44,32,97,115,32,117,115,101,100,32,105,110, + 32,122,105,112,105,109,112,111,114,116,101,114,46,95,102,105, + 108,101,115,46,10,10,73,116,32,105,115,32,117,115,117,97, + 108,108,121,32,110,111,116,32,110,101,101,100,101,100,32,116, + 111,32,117,115,101,32,116,104,101,32,122,105,112,105,109,112, + 111,114,116,32,109,111,100,117,108,101,32,101,120,112,108,105, + 99,105,116,108,121,59,32,105,116,32,105,115,10,117,115,101, + 100,32,98,121,32,116,104,101,32,98,117,105,108,116,105,110, + 32,105,109,112,111,114,116,32,109,101,99,104,97,110,105,115, + 109,32,102,111,114,32,115,121,115,46,112,97,116,104,32,105, + 116,101,109,115,32,116,104,97,116,32,97,114,101,32,112,97, + 116,104,115,10,116,111,32,90,105,112,32,97,114,99,104,105, + 118,101,115,46,10,233,0,0,0,0,78,41,2,218,14,95, + 117,110,112,97,99,107,95,117,105,110,116,49,54,218,14,95, + 117,110,112,97,99,107,95,117,105,110,116,51,50,218,14,90, + 105,112,73,109,112,111,114,116,69,114,114,111,114,218,11,122, + 105,112,105,109,112,111,114,116,101,114,233,1,0,0,0,99, + 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, + 1,0,0,0,64,0,0,0,115,12,0,0,0,101,0,90, + 1,100,0,90,2,100,1,83,0,41,2,114,3,0,0,0, + 78,41,3,218,8,95,95,110,97,109,101,95,95,218,10,95, + 95,109,111,100,117,108,101,95,95,218,12,95,95,113,117,97, + 108,110,97,109,101,95,95,169,0,114,9,0,0,0,114,9, + 0,0,0,250,18,60,102,114,111,122,101,110,32,122,105,112, + 105,109,112,111,114,116,62,114,3,0,0,0,34,0,0,0, + 115,4,0,0,0,8,0,4,1,233,22,0,0,0,115,4, 0,0,0,80,75,5,6,105,255,255,0,0,99,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,3,0,0, - 0,64,0,0,0,115,108,0,0,0,101,0,90,1,100,0, - 90,2,100,1,90,3,100,2,100,3,132,0,90,4,100,25, - 100,5,100,6,132,1,90,5,100,26,100,7,100,8,132,1, - 90,6,100,9,100,10,132,0,90,7,100,11,100,12,132,0, - 90,8,100,13,100,14,132,0,90,9,100,15,100,16,132,0, - 90,10,100,17,100,18,132,0,90,11,100,19,100,20,132,0, - 90,12,100,21,100,22,132,0,90,13,100,23,100,24,132,0, - 90,14,100,4,83,0,41,27,114,4,0,0,0,97,255,1, - 0,0,122,105,112,105,109,112,111,114,116,101,114,40,97,114, - 99,104,105,118,101,112,97,116,104,41,32,45,62,32,122,105, - 112,105,109,112,111,114,116,101,114,32,111,98,106,101,99,116, - 10,10,32,32,32,32,67,114,101,97,116,101,32,97,32,110, - 101,119,32,122,105,112,105,109,112,111,114,116,101,114,32,105, - 110,115,116,97,110,99,101,46,32,39,97,114,99,104,105,118, - 101,112,97,116,104,39,32,109,117,115,116,32,98,101,32,97, - 32,112,97,116,104,32,116,111,10,32,32,32,32,97,32,122, - 105,112,102,105,108,101,44,32,111,114,32,116,111,32,97,32, - 115,112,101,99,105,102,105,99,32,112,97,116,104,32,105,110, - 115,105,100,101,32,97,32,122,105,112,102,105,108,101,46,32, - 70,111,114,32,101,120,97,109,112,108,101,44,32,105,116,32, - 99,97,110,32,98,101,10,32,32,32,32,39,47,116,109,112, - 47,109,121,105,109,112,111,114,116,46,122,105,112,39,44,32, - 111,114,32,39,47,116,109,112,47,109,121,105,109,112,111,114, - 116,46,122,105,112,47,109,121,100,105,114,101,99,116,111,114, - 121,39,44,32,105,102,32,109,121,100,105,114,101,99,116,111, - 114,121,32,105,115,32,97,10,32,32,32,32,118,97,108,105, - 100,32,100,105,114,101,99,116,111,114,121,32,105,110,115,105, - 100,101,32,116,104,101,32,97,114,99,104,105,118,101,46,10, - 10,32,32,32,32,39,90,105,112,73,109,112,111,114,116,69, - 114,114,111,114,32,105,115,32,114,97,105,115,101,100,32,105, - 102,32,39,97,114,99,104,105,118,101,112,97,116,104,39,32, - 100,111,101,115,110,39,116,32,112,111,105,110,116,32,116,111, - 32,97,32,118,97,108,105,100,32,90,105,112,10,32,32,32, - 32,97,114,99,104,105,118,101,46,10,10,32,32,32,32,84, - 104,101,32,39,97,114,99,104,105,118,101,39,32,97,116,116, - 114,105,98,117,116,101,32,111,102,32,122,105,112,105,109,112, - 111,114,116,101,114,32,111,98,106,101,99,116,115,32,99,111, - 110,116,97,105,110,115,32,116,104,101,32,110,97,109,101,32, - 111,102,32,116,104,101,10,32,32,32,32,122,105,112,102,105, - 108,101,32,116,97,114,103,101,116,101,100,46,10,32,32,32, - 32,99,2,0,0,0,0,0,0,0,0,0,0,0,8,0, - 0,0,9,0,0,0,67,0,0,0,115,32,1,0,0,116, - 0,124,1,116,1,131,2,115,28,100,1,100,0,108,2,125, - 2,124,2,160,3,124,1,161,1,125,1,124,1,115,44,116, - 4,100,2,124,1,100,3,141,2,130,1,116,5,114,60,124, - 1,160,6,116,5,116,7,161,2,125,1,103,0,125,3,122, - 14,116,8,160,9,124,1,161,1,125,4,87,0,110,70,4, - 0,116,10,116,11,102,2,121,148,1,0,1,0,1,0,116, - 8,160,12,124,1,161,1,92,2,125,5,125,6,124,5,124, - 1,107,2,114,130,116,4,100,4,124,1,100,3,141,2,130, - 1,124,5,125,1,124,3,160,13,124,6,161,1,1,0,89, - 0,113,64,48,0,124,4,106,14,100,5,64,0,100,6,107, - 3,114,180,116,4,100,4,124,1,100,3,141,2,130,1,113, - 180,113,64,122,12,116,15,124,1,25,0,125,7,87,0,110, - 34,4,0,116,16,121,226,1,0,1,0,1,0,116,17,124, - 1,131,1,125,7,124,7,116,15,124,1,60,0,89,0,110, - 2,48,0,124,7,124,0,95,18,124,1,124,0,95,19,116, - 8,106,20,124,3,100,0,100,0,100,7,133,3,25,0,142, - 0,124,0,95,21,124,0,106,21,144,1,114,28,124,0,4, - 0,106,21,116,7,55,0,2,0,95,21,100,0,83,0,41, - 8,78,114,0,0,0,0,122,21,97,114,99,104,105,118,101, - 32,112,97,116,104,32,105,115,32,101,109,112,116,121,169,1, - 218,4,112,97,116,104,122,14,110,111,116,32,97,32,90,105, - 112,32,102,105,108,101,105,0,240,0,0,105,0,128,0,0, - 233,255,255,255,255,41,22,218,10,105,115,105,110,115,116,97, - 110,99,101,218,3,115,116,114,218,2,111,115,90,8,102,115, - 100,101,99,111,100,101,114,3,0,0,0,218,12,97,108,116, - 95,112,97,116,104,95,115,101,112,218,7,114,101,112,108,97, - 99,101,218,8,112,97,116,104,95,115,101,112,218,19,95,98, - 111,111,116,115,116,114,97,112,95,101,120,116,101,114,110,97, - 108,90,10,95,112,97,116,104,95,115,116,97,116,218,7,79, - 83,69,114,114,111,114,218,10,86,97,108,117,101,69,114,114, - 111,114,90,11,95,112,97,116,104,95,115,112,108,105,116,218, - 6,97,112,112,101,110,100,90,7,115,116,95,109,111,100,101, - 218,20,95,122,105,112,95,100,105,114,101,99,116,111,114,121, - 95,99,97,99,104,101,218,8,75,101,121,69,114,114,111,114, - 218,15,95,114,101,97,100,95,100,105,114,101,99,116,111,114, - 121,218,6,95,102,105,108,101,115,218,7,97,114,99,104,105, - 118,101,218,10,95,112,97,116,104,95,106,111,105,110,218,6, - 112,114,101,102,105,120,41,8,218,4,115,101,108,102,114,13, - 0,0,0,114,17,0,0,0,114,31,0,0,0,90,2,115, - 116,90,7,100,105,114,110,97,109,101,90,8,98,97,115,101, - 110,97,109,101,218,5,102,105,108,101,115,114,9,0,0,0, - 114,9,0,0,0,114,10,0,0,0,218,8,95,95,105,110, - 105,116,95,95,63,0,0,0,115,58,0,0,0,0,1,10, - 1,8,1,10,1,4,1,12,1,4,1,12,2,4,2,2, - 1,14,1,16,3,14,1,8,1,12,1,4,1,16,3,14, - 2,12,1,4,2,2,1,12,1,12,1,8,1,14,1,6, - 1,6,2,22,1,8,1,122,20,122,105,112,105,109,112,111, - 114,116,101,114,46,95,95,105,110,105,116,95,95,78,99,3, - 0,0,0,0,0,0,0,0,0,0,0,5,0,0,0,4, - 0,0,0,67,0,0,0,115,78,0,0,0,116,0,124,0, - 124,1,131,2,125,3,124,3,100,1,117,1,114,26,124,0, - 103,0,102,2,83,0,116,1,124,0,124,1,131,2,125,4, - 116,2,124,0,124,4,131,2,114,70,100,1,124,0,106,3, - 155,0,116,4,155,0,124,4,155,0,157,3,103,1,102,2, - 83,0,100,1,103,0,102,2,83,0,41,2,97,239,1,0, - 0,102,105,110,100,95,108,111,97,100,101,114,40,102,117,108, - 108,110,97,109,101,44,32,112,97,116,104,61,78,111,110,101, - 41,32,45,62,32,115,101,108,102,44,32,115,116,114,32,111, - 114,32,78,111,110,101,46,10,10,32,32,32,32,32,32,32, - 32,83,101,97,114,99,104,32,102,111,114,32,97,32,109,111, - 100,117,108,101,32,115,112,101,99,105,102,105,101,100,32,98, - 121,32,39,102,117,108,108,110,97,109,101,39,46,32,39,102, - 117,108,108,110,97,109,101,39,32,109,117,115,116,32,98,101, - 32,116,104,101,10,32,32,32,32,32,32,32,32,102,117,108, - 108,121,32,113,117,97,108,105,102,105,101,100,32,40,100,111, - 116,116,101,100,41,32,109,111,100,117,108,101,32,110,97,109, - 101,46,32,73,116,32,114,101,116,117,114,110,115,32,116,104, - 101,32,122,105,112,105,109,112,111,114,116,101,114,10,32,32, - 32,32,32,32,32,32,105,110,115,116,97,110,99,101,32,105, - 116,115,101,108,102,32,105,102,32,116,104,101,32,109,111,100, - 117,108,101,32,119,97,115,32,102,111,117,110,100,44,32,97, - 32,115,116,114,105,110,103,32,99,111,110,116,97,105,110,105, - 110,103,32,116,104,101,10,32,32,32,32,32,32,32,32,102, - 117,108,108,32,112,97,116,104,32,110,97,109,101,32,105,102, - 32,105,116,39,115,32,112,111,115,115,105,98,108,121,32,97, - 32,112,111,114,116,105,111,110,32,111,102,32,97,32,110,97, - 109,101,115,112,97,99,101,32,112,97,99,107,97,103,101,44, - 10,32,32,32,32,32,32,32,32,111,114,32,78,111,110,101, - 32,111,116,104,101,114,119,105,115,101,46,32,84,104,101,32, - 111,112,116,105,111,110,97,108,32,39,112,97,116,104,39,32, - 97,114,103,117,109,101,110,116,32,105,115,32,105,103,110,111, - 114,101,100,32,45,45,32,105,116,39,115,10,32,32,32,32, - 32,32,32,32,116,104,101,114,101,32,102,111,114,32,99,111, - 109,112,97,116,105,98,105,108,105,116,121,32,119,105,116,104, - 32,116,104,101,32,105,109,112,111,114,116,101,114,32,112,114, - 111,116,111,99,111,108,46,10,32,32,32,32,32,32,32,32, - 78,41,5,218,16,95,103,101,116,95,109,111,100,117,108,101, - 95,105,110,102,111,218,16,95,103,101,116,95,109,111,100,117, - 108,101,95,112,97,116,104,218,7,95,105,115,95,100,105,114, - 114,29,0,0,0,114,20,0,0,0,41,5,114,32,0,0, - 0,218,8,102,117,108,108,110,97,109,101,114,13,0,0,0, - 218,2,109,105,218,7,109,111,100,112,97,116,104,114,9,0, - 0,0,114,9,0,0,0,114,10,0,0,0,218,11,102,105, - 110,100,95,108,111,97,100,101,114,109,0,0,0,115,14,0, - 0,0,0,10,10,1,8,2,8,7,10,1,10,4,24,2, + 0,64,0,0,0,115,126,0,0,0,101,0,90,1,100,0, + 90,2,100,1,90,3,100,2,100,3,132,0,90,4,100,29, + 100,5,100,6,132,1,90,5,100,29,100,7,100,8,132,1, + 90,6,100,29,100,9,100,10,132,1,90,7,100,11,100,12, + 132,0,90,8,100,13,100,14,132,0,90,9,100,15,100,16, + 132,0,90,10,100,17,100,18,132,0,90,11,100,19,100,20, + 132,0,90,12,100,21,100,22,132,0,90,13,100,23,100,24, + 132,0,90,14,100,25,100,26,132,0,90,15,100,27,100,28, + 132,0,90,16,100,4,83,0,41,30,114,4,0,0,0,97, + 255,1,0,0,122,105,112,105,109,112,111,114,116,101,114,40, + 97,114,99,104,105,118,101,112,97,116,104,41,32,45,62,32, + 122,105,112,105,109,112,111,114,116,101,114,32,111,98,106,101, + 99,116,10,10,32,32,32,32,67,114,101,97,116,101,32,97, + 32,110,101,119,32,122,105,112,105,109,112,111,114,116,101,114, + 32,105,110,115,116,97,110,99,101,46,32,39,97,114,99,104, + 105,118,101,112,97,116,104,39,32,109,117,115,116,32,98,101, + 32,97,32,112,97,116,104,32,116,111,10,32,32,32,32,97, + 32,122,105,112,102,105,108,101,44,32,111,114,32,116,111,32, + 97,32,115,112,101,99,105,102,105,99,32,112,97,116,104,32, + 105,110,115,105,100,101,32,97,32,122,105,112,102,105,108,101, + 46,32,70,111,114,32,101,120,97,109,112,108,101,44,32,105, + 116,32,99,97,110,32,98,101,10,32,32,32,32,39,47,116, + 109,112,47,109,121,105,109,112,111,114,116,46,122,105,112,39, + 44,32,111,114,32,39,47,116,109,112,47,109,121,105,109,112, + 111,114,116,46,122,105,112,47,109,121,100,105,114,101,99,116, + 111,114,121,39,44,32,105,102,32,109,121,100,105,114,101,99, + 116,111,114,121,32,105,115,32,97,10,32,32,32,32,118,97, + 108,105,100,32,100,105,114,101,99,116,111,114,121,32,105,110, + 115,105,100,101,32,116,104,101,32,97,114,99,104,105,118,101, + 46,10,10,32,32,32,32,39,90,105,112,73,109,112,111,114, + 116,69,114,114,111,114,32,105,115,32,114,97,105,115,101,100, + 32,105,102,32,39,97,114,99,104,105,118,101,112,97,116,104, + 39,32,100,111,101,115,110,39,116,32,112,111,105,110,116,32, + 116,111,32,97,32,118,97,108,105,100,32,90,105,112,10,32, + 32,32,32,97,114,99,104,105,118,101,46,10,10,32,32,32, + 32,84,104,101,32,39,97,114,99,104,105,118,101,39,32,97, + 116,116,114,105,98,117,116,101,32,111,102,32,122,105,112,105, + 109,112,111,114,116,101,114,32,111,98,106,101,99,116,115,32, + 99,111,110,116,97,105,110,115,32,116,104,101,32,110,97,109, + 101,32,111,102,32,116,104,101,10,32,32,32,32,122,105,112, + 102,105,108,101,32,116,97,114,103,101,116,101,100,46,10,32, + 32,32,32,99,2,0,0,0,0,0,0,0,0,0,0,0, + 8,0,0,0,9,0,0,0,67,0,0,0,115,36,1,0, + 0,116,0,124,1,116,1,131,2,115,14,100,1,100,0,108, + 2,125,2,124,2,160,3,124,1,161,1,125,1,124,1,115, + 22,116,4,100,2,124,1,100,3,141,2,130,1,116,5,114, + 30,124,1,160,6,116,5,116,7,161,2,125,1,103,0,125, + 3,9,0,122,7,116,8,160,9,124,1,161,1,125,4,87, + 0,110,35,4,0,116,10,116,11,102,2,121,75,1,0,1, + 0,1,0,116,8,160,12,124,1,161,1,92,2,125,5,125, + 6,124,5,124,1,107,2,114,66,116,4,100,5,124,1,100, + 3,141,2,130,1,124,5,125,1,124,3,160,13,124,6,161, + 1,1,0,89,0,110,15,119,0,124,4,106,14,100,6,64, + 0,100,7,107,3,114,89,116,4,100,5,124,1,100,3,141, + 2,130,1,110,1,113,33,122,6,116,15,124,1,25,0,125, + 7,87,0,110,17,4,0,116,16,121,114,1,0,1,0,1, + 0,116,17,124,1,131,1,125,7,124,7,116,15,124,1,60, + 0,89,0,110,1,119,0,124,7,124,0,95,18,124,1,124, + 0,95,19,116,8,106,20,124,3,100,0,100,0,100,8,133, + 3,25,0,142,0,124,0,95,21,124,0,106,21,114,144,124, + 0,4,0,106,21,116,7,55,0,2,0,95,21,100,0,83, + 0,100,0,83,0,41,9,78,114,0,0,0,0,122,21,97, + 114,99,104,105,118,101,32,112,97,116,104,32,105,115,32,101, + 109,112,116,121,169,1,218,4,112,97,116,104,84,122,14,110, + 111,116,32,97,32,90,105,112,32,102,105,108,101,105,0,240, + 0,0,105,0,128,0,0,233,255,255,255,255,41,22,218,10, + 105,115,105,110,115,116,97,110,99,101,218,3,115,116,114,218, + 2,111,115,90,8,102,115,100,101,99,111,100,101,114,3,0, + 0,0,218,12,97,108,116,95,112,97,116,104,95,115,101,112, + 218,7,114,101,112,108,97,99,101,218,8,112,97,116,104,95, + 115,101,112,218,19,95,98,111,111,116,115,116,114,97,112,95, + 101,120,116,101,114,110,97,108,90,10,95,112,97,116,104,95, + 115,116,97,116,218,7,79,83,69,114,114,111,114,218,10,86, + 97,108,117,101,69,114,114,111,114,90,11,95,112,97,116,104, + 95,115,112,108,105,116,218,6,97,112,112,101,110,100,90,7, + 115,116,95,109,111,100,101,218,20,95,122,105,112,95,100,105, + 114,101,99,116,111,114,121,95,99,97,99,104,101,218,8,75, + 101,121,69,114,114,111,114,218,15,95,114,101,97,100,95,100, + 105,114,101,99,116,111,114,121,218,6,95,102,105,108,101,115, + 218,7,97,114,99,104,105,118,101,218,10,95,112,97,116,104, + 95,106,111,105,110,218,6,112,114,101,102,105,120,41,8,218, + 4,115,101,108,102,114,13,0,0,0,114,17,0,0,0,114, + 31,0,0,0,90,2,115,116,90,7,100,105,114,110,97,109, + 101,90,8,98,97,115,101,110,97,109,101,218,5,102,105,108, + 101,115,114,9,0,0,0,114,9,0,0,0,114,10,0,0, + 0,218,8,95,95,105,110,105,116,95,95,64,0,0,0,115, + 68,0,0,0,10,1,8,1,10,1,4,1,12,1,4,1, + 12,1,4,2,2,1,2,1,14,1,16,1,14,3,8,1, + 12,1,4,1,14,1,2,249,14,10,12,2,2,1,2,240, + 2,18,12,1,12,1,8,1,12,1,2,254,6,3,6,1, + 22,2,6,1,18,1,4,255,122,20,122,105,112,105,109,112, + 111,114,116,101,114,46,95,95,105,110,105,116,95,95,78,99, + 3,0,0,0,0,0,0,0,0,0,0,0,5,0,0,0, + 4,0,0,0,67,0,0,0,115,90,0,0,0,116,0,160, + 1,100,1,116,2,161,2,1,0,116,3,124,0,124,1,131, + 2,125,3,124,3,100,2,117,1,114,19,124,0,103,0,102, + 2,83,0,116,4,124,0,124,1,131,2,125,4,116,5,124, + 0,124,4,131,2,114,41,100,2,124,0,106,6,155,0,116, + 7,155,0,124,4,155,0,157,3,103,1,102,2,83,0,100, + 2,103,0,102,2,83,0,41,3,97,47,2,0,0,102,105, + 110,100,95,108,111,97,100,101,114,40,102,117,108,108,110,97, + 109,101,44,32,112,97,116,104,61,78,111,110,101,41,32,45, + 62,32,115,101,108,102,44,32,115,116,114,32,111,114,32,78, + 111,110,101,46,10,10,32,32,32,32,32,32,32,32,83,101, + 97,114,99,104,32,102,111,114,32,97,32,109,111,100,117,108, + 101,32,115,112,101,99,105,102,105,101,100,32,98,121,32,39, + 102,117,108,108,110,97,109,101,39,46,32,39,102,117,108,108, + 110,97,109,101,39,32,109,117,115,116,32,98,101,32,116,104, + 101,10,32,32,32,32,32,32,32,32,102,117,108,108,121,32, + 113,117,97,108,105,102,105,101,100,32,40,100,111,116,116,101, + 100,41,32,109,111,100,117,108,101,32,110,97,109,101,46,32, + 73,116,32,114,101,116,117,114,110,115,32,116,104,101,32,122, + 105,112,105,109,112,111,114,116,101,114,10,32,32,32,32,32, + 32,32,32,105,110,115,116,97,110,99,101,32,105,116,115,101, + 108,102,32,105,102,32,116,104,101,32,109,111,100,117,108,101, + 32,119,97,115,32,102,111,117,110,100,44,32,97,32,115,116, + 114,105,110,103,32,99,111,110,116,97,105,110,105,110,103,32, + 116,104,101,10,32,32,32,32,32,32,32,32,102,117,108,108, + 32,112,97,116,104,32,110,97,109,101,32,105,102,32,105,116, + 39,115,32,112,111,115,115,105,98,108,121,32,97,32,112,111, + 114,116,105,111,110,32,111,102,32,97,32,110,97,109,101,115, + 112,97,99,101,32,112,97,99,107,97,103,101,44,10,32,32, + 32,32,32,32,32,32,111,114,32,78,111,110,101,32,111,116, + 104,101,114,119,105,115,101,46,32,84,104,101,32,111,112,116, + 105,111,110,97,108,32,39,112,97,116,104,39,32,97,114,103, + 117,109,101,110,116,32,105,115,32,105,103,110,111,114,101,100, + 32,45,45,32,105,116,39,115,10,32,32,32,32,32,32,32, + 32,116,104,101,114,101,32,102,111,114,32,99,111,109,112,97, + 116,105,98,105,108,105,116,121,32,119,105,116,104,32,116,104, + 101,32,105,109,112,111,114,116,101,114,32,112,114,111,116,111, + 99,111,108,46,10,10,32,32,32,32,32,32,32,32,68,101, + 112,114,101,99,97,116,101,100,32,115,105,110,99,101,32,80, + 121,116,104,111,110,32,51,46,49,48,46,32,85,115,101,32, + 102,105,110,100,95,115,112,101,99,40,41,32,105,110,115,116, + 101,97,100,46,10,32,32,32,32,32,32,32,32,122,102,122, + 105,112,105,109,112,111,114,116,101,114,46,102,105,110,100,95, + 108,111,97,100,101,114,40,41,32,105,115,32,100,101,112,114, + 101,99,97,116,101,100,32,97,110,100,32,115,108,97,116,101, + 100,32,102,111,114,32,114,101,109,111,118,97,108,32,105,110, + 32,80,121,116,104,111,110,32,51,46,49,50,59,32,117,115, + 101,32,102,105,110,100,95,115,112,101,99,40,41,32,105,110, + 115,116,101,97,100,78,41,8,218,9,95,119,97,114,110,105, + 110,103,115,218,4,119,97,114,110,218,18,68,101,112,114,101, + 99,97,116,105,111,110,87,97,114,110,105,110,103,218,16,95, + 103,101,116,95,109,111,100,117,108,101,95,105,110,102,111,218, + 16,95,103,101,116,95,109,111,100,117,108,101,95,112,97,116, + 104,218,7,95,105,115,95,100,105,114,114,29,0,0,0,114, + 20,0,0,0,41,5,114,32,0,0,0,218,8,102,117,108, + 108,110,97,109,101,114,13,0,0,0,218,2,109,105,218,7, + 109,111,100,112,97,116,104,114,9,0,0,0,114,9,0,0, + 0,114,10,0,0,0,218,11,102,105,110,100,95,108,111,97, + 100,101,114,110,0,0,0,115,20,0,0,0,6,12,2,2, + 4,254,10,3,8,1,8,2,10,7,10,1,24,4,8,2, 122,23,122,105,112,105,109,112,111,114,116,101,114,46,102,105, 110,100,95,108,111,97,100,101,114,99,3,0,0,0,0,0, 0,0,0,0,0,0,3,0,0,0,4,0,0,0,67,0, - 0,0,115,16,0,0,0,124,0,160,0,124,1,124,2,161, - 2,100,1,25,0,83,0,41,2,97,139,1,0,0,102,105, - 110,100,95,109,111,100,117,108,101,40,102,117,108,108,110,97, - 109,101,44,32,112,97,116,104,61,78,111,110,101,41,32,45, - 62,32,115,101,108,102,32,111,114,32,78,111,110,101,46,10, - 10,32,32,32,32,32,32,32,32,83,101,97,114,99,104,32, - 102,111,114,32,97,32,109,111,100,117,108,101,32,115,112,101, - 99,105,102,105,101,100,32,98,121,32,39,102,117,108,108,110, - 97,109,101,39,46,32,39,102,117,108,108,110,97,109,101,39, - 32,109,117,115,116,32,98,101,32,116,104,101,10,32,32,32, - 32,32,32,32,32,102,117,108,108,121,32,113,117,97,108,105, - 102,105,101,100,32,40,100,111,116,116,101,100,41,32,109,111, - 100,117,108,101,32,110,97,109,101,46,32,73,116,32,114,101, - 116,117,114,110,115,32,116,104,101,32,122,105,112,105,109,112, - 111,114,116,101,114,10,32,32,32,32,32,32,32,32,105,110, - 115,116,97,110,99,101,32,105,116,115,101,108,102,32,105,102, - 32,116,104,101,32,109,111,100,117,108,101,32,119,97,115,32, - 102,111,117,110,100,44,32,111,114,32,78,111,110,101,32,105, - 102,32,105,116,32,119,97,115,110,39,116,46,10,32,32,32, - 32,32,32,32,32,84,104,101,32,111,112,116,105,111,110,97, - 108,32,39,112,97,116,104,39,32,97,114,103,117,109,101,110, - 116,32,105,115,32,105,103,110,111,114,101,100,32,45,45,32, - 105,116,39,115,32,116,104,101,114,101,32,102,111,114,32,99, - 111,109,112,97,116,105,98,105,108,105,116,121,10,32,32,32, - 32,32,32,32,32,119,105,116,104,32,116,104,101,32,105,109, - 112,111,114,116,101,114,32,112,114,111,116,111,99,111,108,46, - 10,32,32,32,32,32,32,32,32,114,0,0,0,0,41,1, - 114,41,0,0,0,41,3,114,32,0,0,0,114,38,0,0, - 0,114,13,0,0,0,114,9,0,0,0,114,9,0,0,0, - 114,10,0,0,0,218,11,102,105,110,100,95,109,111,100,117, - 108,101,141,0,0,0,115,2,0,0,0,0,9,122,23,122, - 105,112,105,109,112,111,114,116,101,114,46,102,105,110,100,95, - 109,111,100,117,108,101,99,2,0,0,0,0,0,0,0,0, + 0,0,115,28,0,0,0,116,0,160,1,100,1,116,2,161, + 2,1,0,124,0,160,3,124,1,124,2,161,2,100,2,25, + 0,83,0,41,3,97,203,1,0,0,102,105,110,100,95,109, + 111,100,117,108,101,40,102,117,108,108,110,97,109,101,44,32, + 112,97,116,104,61,78,111,110,101,41,32,45,62,32,115,101, + 108,102,32,111,114,32,78,111,110,101,46,10,10,32,32,32, + 32,32,32,32,32,83,101,97,114,99,104,32,102,111,114,32, + 97,32,109,111,100,117,108,101,32,115,112,101,99,105,102,105, + 101,100,32,98,121,32,39,102,117,108,108,110,97,109,101,39, + 46,32,39,102,117,108,108,110,97,109,101,39,32,109,117,115, + 116,32,98,101,32,116,104,101,10,32,32,32,32,32,32,32, + 32,102,117,108,108,121,32,113,117,97,108,105,102,105,101,100, + 32,40,100,111,116,116,101,100,41,32,109,111,100,117,108,101, + 32,110,97,109,101,46,32,73,116,32,114,101,116,117,114,110, + 115,32,116,104,101,32,122,105,112,105,109,112,111,114,116,101, + 114,10,32,32,32,32,32,32,32,32,105,110,115,116,97,110, + 99,101,32,105,116,115,101,108,102,32,105,102,32,116,104,101, + 32,109,111,100,117,108,101,32,119,97,115,32,102,111,117,110, + 100,44,32,111,114,32,78,111,110,101,32,105,102,32,105,116, + 32,119,97,115,110,39,116,46,10,32,32,32,32,32,32,32, + 32,84,104,101,32,111,112,116,105,111,110,97,108,32,39,112, + 97,116,104,39,32,97,114,103,117,109,101,110,116,32,105,115, + 32,105,103,110,111,114,101,100,32,45,45,32,105,116,39,115, + 32,116,104,101,114,101,32,102,111,114,32,99,111,109,112,97, + 116,105,98,105,108,105,116,121,10,32,32,32,32,32,32,32, + 32,119,105,116,104,32,116,104,101,32,105,109,112,111,114,116, + 101,114,32,112,114,111,116,111,99,111,108,46,10,10,32,32, + 32,32,32,32,32,32,68,101,112,114,101,99,97,116,101,100, + 32,115,105,110,99,101,32,80,121,116,104,111,110,32,51,46, + 49,48,46,32,85,115,101,32,102,105,110,100,95,115,112,101, + 99,40,41,32,105,110,115,116,101,97,100,46,10,32,32,32, + 32,32,32,32,32,122,102,122,105,112,105,109,112,111,114,116, + 101,114,46,102,105,110,100,95,109,111,100,117,108,101,40,41, + 32,105,115,32,100,101,112,114,101,99,97,116,101,100,32,97, + 110,100,32,115,108,97,116,101,100,32,102,111,114,32,114,101, + 109,111,118,97,108,32,105,110,32,80,121,116,104,111,110,32, + 51,46,49,50,59,32,117,115,101,32,102,105,110,100,95,115, + 112,101,99,40,41,32,105,110,115,116,101,97,100,114,0,0, + 0,0,41,4,114,35,0,0,0,114,36,0,0,0,114,37, + 0,0,0,114,44,0,0,0,41,3,114,32,0,0,0,114, + 41,0,0,0,114,13,0,0,0,114,9,0,0,0,114,9, + 0,0,0,114,10,0,0,0,218,11,102,105,110,100,95,109, + 111,100,117,108,101,147,0,0,0,115,8,0,0,0,6,11, + 2,2,4,254,16,3,122,23,122,105,112,105,109,112,111,114, + 116,101,114,46,102,105,110,100,95,109,111,100,117,108,101,99, + 3,0,0,0,0,0,0,0,0,0,0,0,7,0,0,0, + 5,0,0,0,67,0,0,0,115,108,0,0,0,116,0,124, + 0,124,1,131,2,125,3,124,3,100,1,117,1,114,17,116, + 1,106,2,124,1,124,0,124,3,100,2,141,3,83,0,116, + 3,124,0,124,1,131,2,125,4,116,4,124,0,124,4,131, + 2,114,52,124,0,106,5,155,0,116,6,155,0,124,4,155, + 0,157,3,125,5,116,1,106,7,124,1,100,1,100,3,100, + 4,141,3,125,6,124,6,106,8,160,9,124,5,161,1,1, + 0,124,6,83,0,100,1,83,0,41,5,122,107,67,114,101, + 97,116,101,32,97,32,77,111,100,117,108,101,83,112,101,99, + 32,102,111,114,32,116,104,101,32,115,112,101,99,105,102,105, + 101,100,32,109,111,100,117,108,101,46,10,10,32,32,32,32, + 32,32,32,32,82,101,116,117,114,110,115,32,78,111,110,101, + 32,105,102,32,116,104,101,32,109,111,100,117,108,101,32,99, + 97,110,110,111,116,32,98,101,32,102,111,117,110,100,46,10, + 32,32,32,32,32,32,32,32,78,41,1,218,10,105,115,95, + 112,97,99,107,97,103,101,84,41,3,218,4,110,97,109,101, + 90,6,108,111,97,100,101,114,114,46,0,0,0,41,10,114, + 38,0,0,0,218,10,95,98,111,111,116,115,116,114,97,112, + 90,16,115,112,101,99,95,102,114,111,109,95,108,111,97,100, + 101,114,114,39,0,0,0,114,40,0,0,0,114,29,0,0, + 0,114,20,0,0,0,90,10,77,111,100,117,108,101,83,112, + 101,99,90,26,115,117,98,109,111,100,117,108,101,95,115,101, + 97,114,99,104,95,108,111,99,97,116,105,111,110,115,114,24, + 0,0,0,41,7,114,32,0,0,0,114,41,0,0,0,90, + 6,116,97,114,103,101,116,90,11,109,111,100,117,108,101,95, + 105,110,102,111,114,43,0,0,0,114,13,0,0,0,90,4, + 115,112,101,99,114,9,0,0,0,114,9,0,0,0,114,10, + 0,0,0,218,9,102,105,110,100,95,115,112,101,99,163,0, + 0,0,115,24,0,0,0,10,5,8,1,16,1,10,7,10, + 1,18,4,8,1,2,1,6,255,12,2,4,1,4,2,122, + 21,122,105,112,105,109,112,111,114,116,101,114,46,102,105,110, + 100,95,115,112,101,99,99,2,0,0,0,0,0,0,0,0, 0,0,0,5,0,0,0,3,0,0,0,67,0,0,0,115, 20,0,0,0,116,0,124,0,124,1,131,2,92,3,125,2, - 125,3,125,4,124,2,83,0,41,1,122,163,103,101,116,95, + 125,3,125,4,124,2,83,0,41,1,122,166,103,101,116,95, 99,111,100,101,40,102,117,108,108,110,97,109,101,41,32,45, 62,32,99,111,100,101,32,111,98,106,101,99,116,46,10,10, 32,32,32,32,32,32,32,32,82,101,116,117,114,110,32,116, @@ -261,559 +322,584 @@ const unsigned char _Py_M__zipimport[] = { 105,112,73,109,112,111,114,116,69,114,114,111,114,10,32,32, 32,32,32,32,32,32,105,102,32,116,104,101,32,109,111,100, 117,108,101,32,99,111,117,108,100,110,39,116,32,98,101,32, - 102,111,117,110,100,46,10,32,32,32,32,32,32,32,32,169, - 1,218,16,95,103,101,116,95,109,111,100,117,108,101,95,99, - 111,100,101,169,5,114,32,0,0,0,114,38,0,0,0,218, - 4,99,111,100,101,218,9,105,115,112,97,99,107,97,103,101, - 114,40,0,0,0,114,9,0,0,0,114,9,0,0,0,114, - 10,0,0,0,218,8,103,101,116,95,99,111,100,101,153,0, - 0,0,115,4,0,0,0,0,6,16,1,122,20,122,105,112, - 105,109,112,111,114,116,101,114,46,103,101,116,95,99,111,100, - 101,99,2,0,0,0,0,0,0,0,0,0,0,0,4,0, - 0,0,8,0,0,0,67,0,0,0,115,116,0,0,0,116, - 0,114,16,124,1,160,1,116,0,116,2,161,2,125,1,124, - 1,125,2,124,1,160,3,124,0,106,4,116,2,23,0,161, - 1,114,58,124,1,116,5,124,0,106,4,116,2,23,0,131, - 1,100,1,133,2,25,0,125,2,122,14,124,0,106,6,124, - 2,25,0,125,3,87,0,110,30,4,0,116,7,121,102,1, - 0,1,0,1,0,116,8,100,2,100,3,124,2,131,3,130, - 1,89,0,110,2,48,0,116,9,124,0,106,4,124,3,131, - 2,83,0,41,4,122,154,103,101,116,95,100,97,116,97,40, - 112,97,116,104,110,97,109,101,41,32,45,62,32,115,116,114, - 105,110,103,32,119,105,116,104,32,102,105,108,101,32,100,97, - 116,97,46,10,10,32,32,32,32,32,32,32,32,82,101,116, - 117,114,110,32,116,104,101,32,100,97,116,97,32,97,115,115, - 111,99,105,97,116,101,100,32,119,105,116,104,32,39,112,97, - 116,104,110,97,109,101,39,46,32,82,97,105,115,101,32,79, - 83,69,114,114,111,114,32,105,102,10,32,32,32,32,32,32, - 32,32,116,104,101,32,102,105,108,101,32,119,97,115,110,39, - 116,32,102,111,117,110,100,46,10,32,32,32,32,32,32,32, - 32,78,114,0,0,0,0,218,0,41,10,114,18,0,0,0, - 114,19,0,0,0,114,20,0,0,0,218,10,115,116,97,114, - 116,115,119,105,116,104,114,29,0,0,0,218,3,108,101,110, - 114,28,0,0,0,114,26,0,0,0,114,22,0,0,0,218, - 9,95,103,101,116,95,100,97,116,97,41,4,114,32,0,0, - 0,218,8,112,97,116,104,110,97,109,101,90,3,107,101,121, - 218,9,116,111,99,95,101,110,116,114,121,114,9,0,0,0, - 114,9,0,0,0,114,10,0,0,0,218,8,103,101,116,95, - 100,97,116,97,163,0,0,0,115,20,0,0,0,0,6,4, - 1,12,2,4,1,16,1,22,2,2,1,14,1,12,1,18, - 1,122,20,122,105,112,105,109,112,111,114,116,101,114,46,103, - 101,116,95,100,97,116,97,99,2,0,0,0,0,0,0,0, - 0,0,0,0,5,0,0,0,3,0,0,0,67,0,0,0, - 115,20,0,0,0,116,0,124,0,124,1,131,2,92,3,125, - 2,125,3,125,4,124,4,83,0,41,1,122,106,103,101,116, - 95,102,105,108,101,110,97,109,101,40,102,117,108,108,110,97, - 109,101,41,32,45,62,32,102,105,108,101,110,97,109,101,32, - 115,116,114,105,110,103,46,10,10,32,32,32,32,32,32,32, - 32,82,101,116,117,114,110,32,116,104,101,32,102,105,108,101, - 110,97,109,101,32,102,111,114,32,116,104,101,32,115,112,101, - 99,105,102,105,101,100,32,109,111,100,117,108,101,46,10,32, - 32,32,32,32,32,32,32,114,43,0,0,0,114,45,0,0, - 0,114,9,0,0,0,114,9,0,0,0,114,10,0,0,0, - 218,12,103,101,116,95,102,105,108,101,110,97,109,101,184,0, - 0,0,115,4,0,0,0,0,7,16,1,122,24,122,105,112, - 105,109,112,111,114,116,101,114,46,103,101,116,95,102,105,108, - 101,110,97,109,101,99,2,0,0,0,0,0,0,0,0,0, - 0,0,6,0,0,0,8,0,0,0,67,0,0,0,115,126, - 0,0,0,116,0,124,0,124,1,131,2,125,2,124,2,100, - 1,117,0,114,36,116,1,100,2,124,1,155,2,157,2,124, - 1,100,3,141,2,130,1,116,2,124,0,124,1,131,2,125, - 3,124,2,114,64,116,3,160,4,124,3,100,4,161,2,125, - 4,110,10,124,3,155,0,100,5,157,2,125,4,122,14,124, - 0,106,5,124,4,25,0,125,5,87,0,110,20,4,0,116, - 6,121,108,1,0,1,0,1,0,89,0,100,1,83,0,48, - 0,116,7,124,0,106,8,124,5,131,2,160,9,161,0,83, - 0,41,6,122,253,103,101,116,95,115,111,117,114,99,101,40, - 102,117,108,108,110,97,109,101,41,32,45,62,32,115,111,117, - 114,99,101,32,115,116,114,105,110,103,46,10,10,32,32,32, - 32,32,32,32,32,82,101,116,117,114,110,32,116,104,101,32, - 115,111,117,114,99,101,32,99,111,100,101,32,102,111,114,32, - 116,104,101,32,115,112,101,99,105,102,105,101,100,32,109,111, - 100,117,108,101,46,32,82,97,105,115,101,32,90,105,112,73, - 109,112,111,114,116,69,114,114,111,114,10,32,32,32,32,32, - 32,32,32,105,102,32,116,104,101,32,109,111,100,117,108,101, - 32,99,111,117,108,100,110,39,116,32,98,101,32,102,111,117, - 110,100,44,32,114,101,116,117,114,110,32,78,111,110,101,32, - 105,102,32,116,104,101,32,97,114,99,104,105,118,101,32,100, - 111,101,115,10,32,32,32,32,32,32,32,32,99,111,110,116, - 97,105,110,32,116,104,101,32,109,111,100,117,108,101,44,32, - 98,117,116,32,104,97,115,32,110,111,32,115,111,117,114,99, - 101,32,102,111,114,32,105,116,46,10,32,32,32,32,32,32, - 32,32,78,250,18,99,97,110,39,116,32,102,105,110,100,32, - 109,111,100,117,108,101,32,169,1,218,4,110,97,109,101,250, - 11,95,95,105,110,105,116,95,95,46,112,121,250,3,46,112, - 121,41,10,114,35,0,0,0,114,3,0,0,0,114,36,0, - 0,0,114,21,0,0,0,114,30,0,0,0,114,28,0,0, - 0,114,26,0,0,0,114,52,0,0,0,114,29,0,0,0, - 218,6,100,101,99,111,100,101,41,6,114,32,0,0,0,114, - 38,0,0,0,114,39,0,0,0,114,13,0,0,0,218,8, - 102,117,108,108,112,97,116,104,114,54,0,0,0,114,9,0, - 0,0,114,9,0,0,0,114,10,0,0,0,218,10,103,101, - 116,95,115,111,117,114,99,101,195,0,0,0,115,24,0,0, - 0,0,7,10,1,8,1,18,2,10,1,4,1,14,2,10, - 2,2,1,14,1,12,2,8,1,122,22,122,105,112,105,109, - 112,111,114,116,101,114,46,103,101,116,95,115,111,117,114,99, - 101,99,2,0,0,0,0,0,0,0,0,0,0,0,3,0, - 0,0,4,0,0,0,67,0,0,0,115,40,0,0,0,116, + 105,109,112,111,114,116,101,100,46,10,32,32,32,32,32,32, + 32,32,169,1,218,16,95,103,101,116,95,109,111,100,117,108, + 101,95,99,111,100,101,169,5,114,32,0,0,0,114,41,0, + 0,0,218,4,99,111,100,101,218,9,105,115,112,97,99,107, + 97,103,101,114,43,0,0,0,114,9,0,0,0,114,9,0, + 0,0,114,10,0,0,0,218,8,103,101,116,95,99,111,100, + 101,190,0,0,0,115,4,0,0,0,16,6,4,1,122,20, + 122,105,112,105,109,112,111,114,116,101,114,46,103,101,116,95, + 99,111,100,101,99,2,0,0,0,0,0,0,0,0,0,0, + 0,4,0,0,0,8,0,0,0,67,0,0,0,115,112,0, + 0,0,116,0,114,8,124,1,160,1,116,0,116,2,161,2, + 125,1,124,1,125,2,124,1,160,3,124,0,106,4,116,2, + 23,0,161,1,114,29,124,1,116,5,124,0,106,4,116,2, + 23,0,131,1,100,1,133,2,25,0,125,2,122,7,124,0, + 106,6,124,2,25,0,125,3,87,0,110,13,4,0,116,7, + 121,49,1,0,1,0,1,0,116,8,100,2,100,3,124,2, + 131,3,130,1,119,0,116,9,124,0,106,4,124,3,131,2, + 83,0,41,4,122,154,103,101,116,95,100,97,116,97,40,112, + 97,116,104,110,97,109,101,41,32,45,62,32,115,116,114,105, + 110,103,32,119,105,116,104,32,102,105,108,101,32,100,97,116, + 97,46,10,10,32,32,32,32,32,32,32,32,82,101,116,117, + 114,110,32,116,104,101,32,100,97,116,97,32,97,115,115,111, + 99,105,97,116,101,100,32,119,105,116,104,32,39,112,97,116, + 104,110,97,109,101,39,46,32,82,97,105,115,101,32,79,83, + 69,114,114,111,114,32,105,102,10,32,32,32,32,32,32,32, + 32,116,104,101,32,102,105,108,101,32,119,97,115,110,39,116, + 32,102,111,117,110,100,46,10,32,32,32,32,32,32,32,32, + 78,114,0,0,0,0,218,0,41,10,114,18,0,0,0,114, + 19,0,0,0,114,20,0,0,0,218,10,115,116,97,114,116, + 115,119,105,116,104,114,29,0,0,0,218,3,108,101,110,114, + 28,0,0,0,114,26,0,0,0,114,22,0,0,0,218,9, + 95,103,101,116,95,100,97,116,97,41,4,114,32,0,0,0, + 218,8,112,97,116,104,110,97,109,101,90,3,107,101,121,218, + 9,116,111,99,95,101,110,116,114,121,114,9,0,0,0,114, + 9,0,0,0,114,10,0,0,0,218,8,103,101,116,95,100, + 97,116,97,200,0,0,0,115,22,0,0,0,4,6,12,1, + 4,2,16,1,22,1,2,2,14,1,12,1,12,1,2,255, + 12,2,122,20,122,105,112,105,109,112,111,114,116,101,114,46, + 103,101,116,95,100,97,116,97,99,2,0,0,0,0,0,0, + 0,0,0,0,0,5,0,0,0,3,0,0,0,67,0,0, + 0,115,20,0,0,0,116,0,124,0,124,1,131,2,92,3, + 125,2,125,3,125,4,124,4,83,0,41,1,122,165,103,101, + 116,95,102,105,108,101,110,97,109,101,40,102,117,108,108,110, + 97,109,101,41,32,45,62,32,102,105,108,101,110,97,109,101, + 32,115,116,114,105,110,103,46,10,10,32,32,32,32,32,32, + 32,32,82,101,116,117,114,110,32,116,104,101,32,102,105,108, + 101,110,97,109,101,32,102,111,114,32,116,104,101,32,115,112, + 101,99,105,102,105,101,100,32,109,111,100,117,108,101,32,111, + 114,32,114,97,105,115,101,32,90,105,112,73,109,112,111,114, + 116,69,114,114,111,114,10,32,32,32,32,32,32,32,32,105, + 102,32,105,116,32,99,111,117,108,100,110,39,116,32,98,101, + 32,105,109,112,111,114,116,101,100,46,10,32,32,32,32,32, + 32,32,32,114,50,0,0,0,114,52,0,0,0,114,9,0, + 0,0,114,9,0,0,0,114,10,0,0,0,218,12,103,101, + 116,95,102,105,108,101,110,97,109,101,221,0,0,0,115,4, + 0,0,0,16,8,4,1,122,24,122,105,112,105,109,112,111, + 114,116,101,114,46,103,101,116,95,102,105,108,101,110,97,109, + 101,99,2,0,0,0,0,0,0,0,0,0,0,0,6,0, + 0,0,8,0,0,0,67,0,0,0,115,126,0,0,0,116, 0,124,0,124,1,131,2,125,2,124,2,100,1,117,0,114, - 36,116,1,100,2,124,1,155,2,157,2,124,1,100,3,141, - 2,130,1,124,2,83,0,41,4,122,171,105,115,95,112,97, - 99,107,97,103,101,40,102,117,108,108,110,97,109,101,41,32, - 45,62,32,98,111,111,108,46,10,10,32,32,32,32,32,32, - 32,32,82,101,116,117,114,110,32,84,114,117,101,32,105,102, - 32,116,104,101,32,109,111,100,117,108,101,32,115,112,101,99, - 105,102,105,101,100,32,98,121,32,102,117,108,108,110,97,109, - 101,32,105,115,32,97,32,112,97,99,107,97,103,101,46,10, - 32,32,32,32,32,32,32,32,82,97,105,115,101,32,90,105, - 112,73,109,112,111,114,116,69,114,114,111,114,32,105,102,32, - 116,104,101,32,109,111,100,117,108,101,32,99,111,117,108,100, - 110,39,116,32,98,101,32,102,111,117,110,100,46,10,32,32, - 32,32,32,32,32,32,78,114,57,0,0,0,114,58,0,0, - 0,41,2,114,35,0,0,0,114,3,0,0,0,41,3,114, - 32,0,0,0,114,38,0,0,0,114,39,0,0,0,114,9, - 0,0,0,114,9,0,0,0,114,10,0,0,0,218,10,105, - 115,95,112,97,99,107,97,103,101,221,0,0,0,115,8,0, - 0,0,0,6,10,1,8,1,18,1,122,22,122,105,112,105, - 109,112,111,114,116,101,114,46,105,115,95,112,97,99,107,97, - 103,101,99,2,0,0,0,0,0,0,0,0,0,0,0,8, - 0,0,0,8,0,0,0,67,0,0,0,115,246,0,0,0, - 116,0,124,0,124,1,131,2,92,3,125,2,125,3,125,4, - 116,1,106,2,160,3,124,1,161,1,125,5,124,5,100,1, - 117,0,115,46,116,4,124,5,116,5,131,2,115,64,116,5, - 124,1,131,1,125,5,124,5,116,1,106,2,124,1,60,0, - 124,0,124,5,95,6,122,84,124,3,114,108,116,7,124,0, - 124,1,131,2,125,6,116,8,160,9,124,0,106,10,124,6, - 161,2,125,7,124,7,103,1,124,5,95,11,116,12,124,5, - 100,2,131,2,115,124,116,13,124,5,95,13,116,8,160,14, - 124,5,106,15,124,1,124,4,161,3,1,0,116,16,124,2, - 124,5,106,15,131,2,1,0,87,0,110,22,1,0,1,0, - 1,0,116,1,106,2,124,1,61,0,130,0,89,0,110,2, - 48,0,122,14,116,1,106,2,124,1,25,0,125,5,87,0, - 110,34,4,0,116,17,121,226,1,0,1,0,1,0,116,18, - 100,3,124,1,155,2,100,4,157,3,131,1,130,1,89,0, - 110,2,48,0,116,19,160,20,100,5,124,1,124,4,161,3, - 1,0,124,5,83,0,41,6,122,245,108,111,97,100,95,109, - 111,100,117,108,101,40,102,117,108,108,110,97,109,101,41,32, - 45,62,32,109,111,100,117,108,101,46,10,10,32,32,32,32, - 32,32,32,32,76,111,97,100,32,116,104,101,32,109,111,100, - 117,108,101,32,115,112,101,99,105,102,105,101,100,32,98,121, - 32,39,102,117,108,108,110,97,109,101,39,46,32,39,102,117, - 108,108,110,97,109,101,39,32,109,117,115,116,32,98,101,32, - 116,104,101,10,32,32,32,32,32,32,32,32,102,117,108,108, - 121,32,113,117,97,108,105,102,105,101,100,32,40,100,111,116, - 116,101,100,41,32,109,111,100,117,108,101,32,110,97,109,101, - 46,32,73,116,32,114,101,116,117,114,110,115,32,116,104,101, - 32,105,109,112,111,114,116,101,100,10,32,32,32,32,32,32, - 32,32,109,111,100,117,108,101,44,32,111,114,32,114,97,105, - 115,101,115,32,90,105,112,73,109,112,111,114,116,69,114,114, - 111,114,32,105,102,32,105,116,32,119,97,115,110,39,116,32, - 102,111,117,110,100,46,10,32,32,32,32,32,32,32,32,78, - 218,12,95,95,98,117,105,108,116,105,110,115,95,95,122,14, - 76,111,97,100,101,100,32,109,111,100,117,108,101,32,122,25, - 32,110,111,116,32,102,111,117,110,100,32,105,110,32,115,121, - 115,46,109,111,100,117,108,101,115,122,30,105,109,112,111,114, - 116,32,123,125,32,35,32,108,111,97,100,101,100,32,102,114, - 111,109,32,90,105,112,32,123,125,41,21,114,44,0,0,0, - 218,3,115,121,115,218,7,109,111,100,117,108,101,115,218,3, - 103,101,116,114,15,0,0,0,218,12,95,109,111,100,117,108, - 101,95,116,121,112,101,218,10,95,95,108,111,97,100,101,114, - 95,95,114,36,0,0,0,114,21,0,0,0,114,30,0,0, - 0,114,29,0,0,0,90,8,95,95,112,97,116,104,95,95, - 218,7,104,97,115,97,116,116,114,114,66,0,0,0,90,14, - 95,102,105,120,95,117,112,95,109,111,100,117,108,101,218,8, - 95,95,100,105,99,116,95,95,218,4,101,120,101,99,114,26, - 0,0,0,218,11,73,109,112,111,114,116,69,114,114,111,114, - 218,10,95,98,111,111,116,115,116,114,97,112,218,16,95,118, - 101,114,98,111,115,101,95,109,101,115,115,97,103,101,41,8, - 114,32,0,0,0,114,38,0,0,0,114,46,0,0,0,114, - 47,0,0,0,114,40,0,0,0,90,3,109,111,100,114,13, - 0,0,0,114,63,0,0,0,114,9,0,0,0,114,9,0, - 0,0,114,10,0,0,0,218,11,108,111,97,100,95,109,111, - 100,117,108,101,234,0,0,0,115,48,0,0,0,0,7,16, - 1,12,1,18,1,8,1,10,1,6,2,2,1,4,3,10, - 1,14,1,8,2,10,1,6,1,16,1,16,1,6,1,8, - 1,8,2,2,1,14,1,12,1,22,1,14,1,122,23,122, - 105,112,105,109,112,111,114,116,101,114,46,108,111,97,100,95, - 109,111,100,117,108,101,99,2,0,0,0,0,0,0,0,0, - 0,0,0,3,0,0,0,8,0,0,0,67,0,0,0,115, - 86,0,0,0,122,20,124,0,160,0,124,1,161,1,115,18, - 87,0,100,1,83,0,87,0,110,20,4,0,116,1,121,40, - 1,0,1,0,1,0,89,0,100,1,83,0,48,0,116,2, - 106,3,115,76,100,2,100,3,108,4,109,5,125,2,1,0, - 124,2,160,6,116,2,161,1,1,0,100,4,116,2,95,3, - 116,2,124,0,124,1,131,2,83,0,41,5,122,204,82,101, - 116,117,114,110,32,116,104,101,32,82,101,115,111,117,114,99, - 101,82,101,97,100,101,114,32,102,111,114,32,97,32,112,97, - 99,107,97,103,101,32,105,110,32,97,32,122,105,112,32,102, - 105,108,101,46,10,10,32,32,32,32,32,32,32,32,73,102, - 32,39,102,117,108,108,110,97,109,101,39,32,105,115,32,97, - 32,112,97,99,107,97,103,101,32,119,105,116,104,105,110,32, - 116,104,101,32,122,105,112,32,102,105,108,101,44,32,114,101, - 116,117,114,110,32,116,104,101,10,32,32,32,32,32,32,32, - 32,39,82,101,115,111,117,114,99,101,82,101,97,100,101,114, - 39,32,111,98,106,101,99,116,32,102,111,114,32,116,104,101, - 32,112,97,99,107,97,103,101,46,32,32,79,116,104,101,114, - 119,105,115,101,32,114,101,116,117,114,110,32,78,111,110,101, - 46,10,32,32,32,32,32,32,32,32,78,114,0,0,0,0, - 41,1,218,14,82,101,115,111,117,114,99,101,82,101,97,100, - 101,114,84,41,7,114,65,0,0,0,114,3,0,0,0,218, - 24,95,90,105,112,73,109,112,111,114,116,82,101,115,111,117, - 114,99,101,82,101,97,100,101,114,218,11,95,114,101,103,105, - 115,116,101,114,101,100,90,13,105,109,112,111,114,116,108,105, - 98,46,97,98,99,114,79,0,0,0,90,8,114,101,103,105, - 115,116,101,114,41,3,114,32,0,0,0,114,38,0,0,0, - 114,79,0,0,0,114,9,0,0,0,114,9,0,0,0,114, - 10,0,0,0,218,19,103,101,116,95,114,101,115,111,117,114, - 99,101,95,114,101,97,100,101,114,16,1,0,0,115,20,0, - 0,0,0,6,2,1,10,1,10,1,12,1,8,1,6,1, - 12,1,10,1,6,1,122,31,122,105,112,105,109,112,111,114, - 116,101,114,46,103,101,116,95,114,101,115,111,117,114,99,101, - 95,114,101,97,100,101,114,99,1,0,0,0,0,0,0,0, - 0,0,0,0,1,0,0,0,5,0,0,0,67,0,0,0, - 115,24,0,0,0,100,1,124,0,106,0,155,0,116,1,155, - 0,124,0,106,2,155,0,100,2,157,5,83,0,41,3,78, - 122,21,60,122,105,112,105,109,112,111,114,116,101,114,32,111, - 98,106,101,99,116,32,34,122,2,34,62,41,3,114,29,0, - 0,0,114,20,0,0,0,114,31,0,0,0,41,1,114,32, + 18,116,1,100,2,124,1,155,2,157,2,124,1,100,3,141, + 2,130,1,116,2,124,0,124,1,131,2,125,3,124,2,114, + 32,116,3,160,4,124,3,100,4,161,2,125,4,110,5,124, + 3,155,0,100,5,157,2,125,4,122,7,124,0,106,5,124, + 4,25,0,125,5,87,0,110,10,4,0,116,6,121,54,1, + 0,1,0,1,0,89,0,100,1,83,0,119,0,116,7,124, + 0,106,8,124,5,131,2,160,9,161,0,83,0,41,6,122, + 253,103,101,116,95,115,111,117,114,99,101,40,102,117,108,108, + 110,97,109,101,41,32,45,62,32,115,111,117,114,99,101,32, + 115,116,114,105,110,103,46,10,10,32,32,32,32,32,32,32, + 32,82,101,116,117,114,110,32,116,104,101,32,115,111,117,114, + 99,101,32,99,111,100,101,32,102,111,114,32,116,104,101,32, + 115,112,101,99,105,102,105,101,100,32,109,111,100,117,108,101, + 46,32,82,97,105,115,101,32,90,105,112,73,109,112,111,114, + 116,69,114,114,111,114,10,32,32,32,32,32,32,32,32,105, + 102,32,116,104,101,32,109,111,100,117,108,101,32,99,111,117, + 108,100,110,39,116,32,98,101,32,102,111,117,110,100,44,32, + 114,101,116,117,114,110,32,78,111,110,101,32,105,102,32,116, + 104,101,32,97,114,99,104,105,118,101,32,100,111,101,115,10, + 32,32,32,32,32,32,32,32,99,111,110,116,97,105,110,32, + 116,104,101,32,109,111,100,117,108,101,44,32,98,117,116,32, + 104,97,115,32,110,111,32,115,111,117,114,99,101,32,102,111, + 114,32,105,116,46,10,32,32,32,32,32,32,32,32,78,250, + 18,99,97,110,39,116,32,102,105,110,100,32,109,111,100,117, + 108,101,32,169,1,114,47,0,0,0,250,11,95,95,105,110, + 105,116,95,95,46,112,121,250,3,46,112,121,41,10,114,38, + 0,0,0,114,3,0,0,0,114,39,0,0,0,114,21,0, + 0,0,114,30,0,0,0,114,28,0,0,0,114,26,0,0, + 0,114,59,0,0,0,114,29,0,0,0,218,6,100,101,99, + 111,100,101,41,6,114,32,0,0,0,114,41,0,0,0,114, + 42,0,0,0,114,13,0,0,0,218,8,102,117,108,108,112, + 97,116,104,114,61,0,0,0,114,9,0,0,0,114,9,0, + 0,0,114,10,0,0,0,218,10,103,101,116,95,115,111,117, + 114,99,101,233,0,0,0,115,26,0,0,0,10,7,8,1, + 18,1,10,2,4,1,14,1,10,2,2,2,14,1,12,1, + 6,2,2,254,16,3,122,22,122,105,112,105,109,112,111,114, + 116,101,114,46,103,101,116,95,115,111,117,114,99,101,99,2, + 0,0,0,0,0,0,0,0,0,0,0,3,0,0,0,4, + 0,0,0,67,0,0,0,115,40,0,0,0,116,0,124,0, + 124,1,131,2,125,2,124,2,100,1,117,0,114,18,116,1, + 100,2,124,1,155,2,157,2,124,1,100,3,141,2,130,1, + 124,2,83,0,41,4,122,171,105,115,95,112,97,99,107,97, + 103,101,40,102,117,108,108,110,97,109,101,41,32,45,62,32, + 98,111,111,108,46,10,10,32,32,32,32,32,32,32,32,82, + 101,116,117,114,110,32,84,114,117,101,32,105,102,32,116,104, + 101,32,109,111,100,117,108,101,32,115,112,101,99,105,102,105, + 101,100,32,98,121,32,102,117,108,108,110,97,109,101,32,105, + 115,32,97,32,112,97,99,107,97,103,101,46,10,32,32,32, + 32,32,32,32,32,82,97,105,115,101,32,90,105,112,73,109, + 112,111,114,116,69,114,114,111,114,32,105,102,32,116,104,101, + 32,109,111,100,117,108,101,32,99,111,117,108,100,110,39,116, + 32,98,101,32,102,111,117,110,100,46,10,32,32,32,32,32, + 32,32,32,78,114,64,0,0,0,114,65,0,0,0,41,2, + 114,38,0,0,0,114,3,0,0,0,41,3,114,32,0,0, + 0,114,41,0,0,0,114,42,0,0,0,114,9,0,0,0, + 114,9,0,0,0,114,10,0,0,0,114,46,0,0,0,3, + 1,0,0,115,8,0,0,0,10,6,8,1,18,1,4,1, + 122,22,122,105,112,105,109,112,111,114,116,101,114,46,105,115, + 95,112,97,99,107,97,103,101,99,2,0,0,0,0,0,0, + 0,0,0,0,0,9,0,0,0,8,0,0,0,67,0,0, + 0,115,252,0,0,0,100,1,125,2,116,0,160,1,124,2, + 116,2,161,2,1,0,116,3,124,0,124,1,131,2,92,3, + 125,3,125,4,125,5,116,4,106,5,160,6,124,1,161,1, + 125,6,124,6,100,2,117,0,115,31,116,7,124,6,116,8, + 131,2,115,40,116,8,124,1,131,1,125,6,124,6,116,4, + 106,5,124,1,60,0,124,0,124,6,95,9,122,42,124,4, + 114,62,116,10,124,0,124,1,131,2,125,7,116,11,160,12, + 124,0,106,13,124,7,161,2,125,8,124,8,103,1,124,6, + 95,14,116,15,124,6,100,3,131,2,115,70,116,16,124,6, + 95,16,116,11,160,17,124,6,106,18,124,1,124,5,161,3, + 1,0,116,19,124,3,124,6,106,18,131,2,1,0,87,0, + 110,8,1,0,1,0,1,0,116,4,106,5,124,1,61,0, + 130,0,122,7,116,4,106,5,124,1,25,0,125,6,87,0, + 110,15,4,0,116,20,121,116,1,0,1,0,1,0,116,21, + 100,4,124,1,155,2,100,5,157,3,131,1,130,1,119,0, + 116,22,160,23,100,6,124,1,124,5,161,3,1,0,124,6, + 83,0,41,7,97,64,1,0,0,108,111,97,100,95,109,111, + 100,117,108,101,40,102,117,108,108,110,97,109,101,41,32,45, + 62,32,109,111,100,117,108,101,46,10,10,32,32,32,32,32, + 32,32,32,76,111,97,100,32,116,104,101,32,109,111,100,117, + 108,101,32,115,112,101,99,105,102,105,101,100,32,98,121,32, + 39,102,117,108,108,110,97,109,101,39,46,32,39,102,117,108, + 108,110,97,109,101,39,32,109,117,115,116,32,98,101,32,116, + 104,101,10,32,32,32,32,32,32,32,32,102,117,108,108,121, + 32,113,117,97,108,105,102,105,101,100,32,40,100,111,116,116, + 101,100,41,32,109,111,100,117,108,101,32,110,97,109,101,46, + 32,73,116,32,114,101,116,117,114,110,115,32,116,104,101,32, + 105,109,112,111,114,116,101,100,10,32,32,32,32,32,32,32, + 32,109,111,100,117,108,101,44,32,111,114,32,114,97,105,115, + 101,115,32,90,105,112,73,109,112,111,114,116,69,114,114,111, + 114,32,105,102,32,105,116,32,99,111,117,108,100,32,110,111, + 116,32,98,101,32,105,109,112,111,114,116,101,100,46,10,10, + 32,32,32,32,32,32,32,32,68,101,112,114,101,99,97,116, + 101,100,32,115,105,110,99,101,32,80,121,116,104,111,110,32, + 51,46,49,48,46,32,85,115,101,32,101,120,101,99,95,109, + 111,100,117,108,101,40,41,32,105,110,115,116,101,97,100,46, + 10,32,32,32,32,32,32,32,32,122,114,122,105,112,105,109, + 112,111,114,116,46,122,105,112,105,109,112,111,114,116,101,114, + 46,108,111,97,100,95,109,111,100,117,108,101,40,41,32,105, + 115,32,100,101,112,114,101,99,97,116,101,100,32,97,110,100, + 32,115,108,97,116,101,100,32,102,111,114,32,114,101,109,111, + 118,97,108,32,105,110,32,80,121,116,104,111,110,32,51,46, + 49,50,59,32,117,115,101,32,101,120,101,99,95,109,111,100, + 117,108,101,40,41,32,105,110,115,116,101,97,100,78,218,12, + 95,95,98,117,105,108,116,105,110,115,95,95,122,14,76,111, + 97,100,101,100,32,109,111,100,117,108,101,32,122,25,32,110, + 111,116,32,102,111,117,110,100,32,105,110,32,115,121,115,46, + 109,111,100,117,108,101,115,122,30,105,109,112,111,114,116,32, + 123,125,32,35,32,108,111,97,100,101,100,32,102,114,111,109, + 32,90,105,112,32,123,125,41,24,114,35,0,0,0,114,36, + 0,0,0,114,37,0,0,0,114,51,0,0,0,218,3,115, + 121,115,218,7,109,111,100,117,108,101,115,218,3,103,101,116, + 114,15,0,0,0,218,12,95,109,111,100,117,108,101,95,116, + 121,112,101,218,10,95,95,108,111,97,100,101,114,95,95,114, + 39,0,0,0,114,21,0,0,0,114,30,0,0,0,114,29, + 0,0,0,90,8,95,95,112,97,116,104,95,95,218,7,104, + 97,115,97,116,116,114,114,71,0,0,0,90,14,95,102,105, + 120,95,117,112,95,109,111,100,117,108,101,218,8,95,95,100, + 105,99,116,95,95,218,4,101,120,101,99,114,26,0,0,0, + 218,11,73,109,112,111,114,116,69,114,114,111,114,114,48,0, + 0,0,218,16,95,118,101,114,98,111,115,101,95,109,101,115, + 115,97,103,101,41,9,114,32,0,0,0,114,41,0,0,0, + 218,3,109,115,103,114,53,0,0,0,114,54,0,0,0,114, + 43,0,0,0,90,3,109,111,100,114,13,0,0,0,114,69, 0,0,0,114,9,0,0,0,114,9,0,0,0,114,10,0, - 0,0,218,8,95,95,114,101,112,114,95,95,34,1,0,0, - 115,2,0,0,0,0,1,122,20,122,105,112,105,109,112,111, - 114,116,101,114,46,95,95,114,101,112,114,95,95,41,1,78, - 41,1,78,41,15,114,6,0,0,0,114,7,0,0,0,114, - 8,0,0,0,218,7,95,95,100,111,99,95,95,114,34,0, - 0,0,114,41,0,0,0,114,42,0,0,0,114,48,0,0, - 0,114,55,0,0,0,114,56,0,0,0,114,64,0,0,0, - 114,65,0,0,0,114,78,0,0,0,114,82,0,0,0,114, - 83,0,0,0,114,9,0,0,0,114,9,0,0,0,114,9, - 0,0,0,114,10,0,0,0,114,4,0,0,0,45,0,0, - 0,115,24,0,0,0,8,1,4,17,8,46,10,32,10,12, - 8,10,8,21,8,11,8,26,8,13,8,38,8,18,122,12, - 95,95,105,110,105,116,95,95,46,112,121,99,84,114,60,0, - 0,0,70,41,3,122,4,46,112,121,99,84,70,41,3,114, - 61,0,0,0,70,70,99,2,0,0,0,0,0,0,0,0, - 0,0,0,2,0,0,0,4,0,0,0,67,0,0,0,115, - 20,0,0,0,124,0,106,0,124,1,160,1,100,1,161,1, - 100,2,25,0,23,0,83,0,41,3,78,218,1,46,233,2, - 0,0,0,41,2,114,31,0,0,0,218,10,114,112,97,114, - 116,105,116,105,111,110,41,2,114,32,0,0,0,114,38,0, - 0,0,114,9,0,0,0,114,9,0,0,0,114,10,0,0, - 0,114,36,0,0,0,52,1,0,0,115,2,0,0,0,0, - 1,114,36,0,0,0,99,2,0,0,0,0,0,0,0,0, - 0,0,0,3,0,0,0,2,0,0,0,67,0,0,0,115, - 18,0,0,0,124,1,116,0,23,0,125,2,124,2,124,0, - 106,1,118,0,83,0,169,1,78,41,2,114,20,0,0,0, - 114,28,0,0,0,41,3,114,32,0,0,0,114,13,0,0, - 0,90,7,100,105,114,112,97,116,104,114,9,0,0,0,114, - 9,0,0,0,114,10,0,0,0,114,37,0,0,0,56,1, - 0,0,115,4,0,0,0,0,4,8,2,114,37,0,0,0, - 99,2,0,0,0,0,0,0,0,0,0,0,0,7,0,0, - 0,4,0,0,0,67,0,0,0,115,56,0,0,0,116,0, - 124,0,124,1,131,2,125,2,116,1,68,0,93,36,92,3, - 125,3,125,4,125,5,124,2,124,3,23,0,125,6,124,6, - 124,0,106,2,118,0,114,14,124,5,2,0,1,0,83,0, - 113,14,100,0,83,0,114,88,0,0,0,41,3,114,36,0, - 0,0,218,16,95,122,105,112,95,115,101,97,114,99,104,111, - 114,100,101,114,114,28,0,0,0,41,7,114,32,0,0,0, - 114,38,0,0,0,114,13,0,0,0,218,6,115,117,102,102, - 105,120,218,10,105,115,98,121,116,101,99,111,100,101,114,47, - 0,0,0,114,63,0,0,0,114,9,0,0,0,114,9,0, - 0,0,114,10,0,0,0,114,35,0,0,0,65,1,0,0, - 115,12,0,0,0,0,1,10,1,14,1,8,1,10,1,10, - 1,114,35,0,0,0,99,1,0,0,0,0,0,0,0,0, - 0,0,0,26,0,0,0,9,0,0,0,67,0,0,0,115, - 2,5,0,0,122,14,116,0,160,1,124,0,161,1,125,1, - 87,0,110,36,4,0,116,2,121,50,1,0,1,0,1,0, - 116,3,100,1,124,0,155,2,157,2,124,0,100,2,141,2, - 130,1,89,0,110,2,48,0,124,1,144,4,143,164,1,0, - 122,36,124,1,160,4,116,5,11,0,100,3,161,2,1,0, - 124,1,160,6,161,0,125,2,124,1,160,7,116,5,161,1, - 125,3,87,0,110,36,4,0,116,2,121,132,1,0,1,0, - 1,0,116,3,100,4,124,0,155,2,157,2,124,0,100,2, - 141,2,130,1,89,0,110,2,48,0,116,8,124,3,131,1, - 116,5,107,3,114,164,116,3,100,4,124,0,155,2,157,2, + 0,0,218,11,108,111,97,100,95,109,111,100,117,108,101,16, + 1,0,0,115,54,0,0,0,4,9,12,2,16,1,12,1, + 18,1,8,1,10,1,6,1,2,2,4,1,10,3,14,1, + 8,1,10,2,6,1,16,1,16,1,6,1,8,1,2,1, + 2,2,14,1,12,1,16,1,2,255,14,2,4,1,122,23, + 122,105,112,105,109,112,111,114,116,101,114,46,108,111,97,100, + 95,109,111,100,117,108,101,99,2,0,0,0,0,0,0,0, + 0,0,0,0,3,0,0,0,8,0,0,0,67,0,0,0, + 115,64,0,0,0,122,10,124,0,160,0,124,1,161,1,115, + 9,87,0,100,1,83,0,87,0,110,10,4,0,116,1,121, + 20,1,0,1,0,1,0,89,0,100,1,83,0,119,0,100, + 2,100,3,108,2,109,3,125,2,1,0,124,2,124,0,124, + 1,131,2,83,0,41,4,122,204,82,101,116,117,114,110,32, + 116,104,101,32,82,101,115,111,117,114,99,101,82,101,97,100, + 101,114,32,102,111,114,32,97,32,112,97,99,107,97,103,101, + 32,105,110,32,97,32,122,105,112,32,102,105,108,101,46,10, + 10,32,32,32,32,32,32,32,32,73,102,32,39,102,117,108, + 108,110,97,109,101,39,32,105,115,32,97,32,112,97,99,107, + 97,103,101,32,119,105,116,104,105,110,32,116,104,101,32,122, + 105,112,32,102,105,108,101,44,32,114,101,116,117,114,110,32, + 116,104,101,10,32,32,32,32,32,32,32,32,39,82,101,115, + 111,117,114,99,101,82,101,97,100,101,114,39,32,111,98,106, + 101,99,116,32,102,111,114,32,116,104,101,32,112,97,99,107, + 97,103,101,46,32,32,79,116,104,101,114,119,105,115,101,32, + 114,101,116,117,114,110,32,78,111,110,101,46,10,32,32,32, + 32,32,32,32,32,78,114,0,0,0,0,41,1,218,9,90, + 105,112,82,101,97,100,101,114,41,4,114,46,0,0,0,114, + 3,0,0,0,90,17,105,109,112,111,114,116,108,105,98,46, + 114,101,97,100,101,114,115,114,84,0,0,0,41,3,114,32, + 0,0,0,114,41,0,0,0,114,84,0,0,0,114,9,0, + 0,0,114,9,0,0,0,114,10,0,0,0,218,19,103,101, + 116,95,114,101,115,111,117,114,99,101,95,114,101,97,100,101, + 114,59,1,0,0,115,18,0,0,0,2,6,10,1,6,1, + 4,255,12,2,6,1,2,255,12,2,10,1,122,31,122,105, + 112,105,109,112,111,114,116,101,114,46,103,101,116,95,114,101, + 115,111,117,114,99,101,95,114,101,97,100,101,114,99,1,0, + 0,0,0,0,0,0,0,0,0,0,1,0,0,0,8,0, + 0,0,67,0,0,0,115,72,0,0,0,122,15,116,0,124, + 0,106,1,131,1,124,0,95,2,124,0,106,2,116,3,124, + 0,106,1,60,0,87,0,100,1,83,0,4,0,116,4,121, + 35,1,0,1,0,1,0,116,3,160,5,124,0,106,1,100, + 1,161,2,1,0,105,0,124,0,95,2,89,0,100,1,83, + 0,119,0,41,2,122,41,82,101,108,111,97,100,32,116,104, + 101,32,102,105,108,101,32,100,97,116,97,32,111,102,32,116, + 104,101,32,97,114,99,104,105,118,101,32,112,97,116,104,46, + 78,41,6,114,27,0,0,0,114,29,0,0,0,114,28,0, + 0,0,114,25,0,0,0,114,3,0,0,0,218,3,112,111, + 112,169,1,114,32,0,0,0,114,9,0,0,0,114,9,0, + 0,0,114,10,0,0,0,218,17,105,110,118,97,108,105,100, + 97,116,101,95,99,97,99,104,101,115,74,1,0,0,115,14, + 0,0,0,2,2,12,1,18,1,12,1,14,1,12,1,2, + 254,122,29,122,105,112,105,109,112,111,114,116,101,114,46,105, + 110,118,97,108,105,100,97,116,101,95,99,97,99,104,101,115, + 99,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0, + 0,5,0,0,0,67,0,0,0,115,24,0,0,0,100,1, + 124,0,106,0,155,0,116,1,155,0,124,0,106,2,155,0, + 100,2,157,5,83,0,41,3,78,122,21,60,122,105,112,105, + 109,112,111,114,116,101,114,32,111,98,106,101,99,116,32,34, + 122,2,34,62,41,3,114,29,0,0,0,114,20,0,0,0, + 114,31,0,0,0,114,87,0,0,0,114,9,0,0,0,114, + 9,0,0,0,114,10,0,0,0,218,8,95,95,114,101,112, + 114,95,95,84,1,0,0,115,2,0,0,0,24,1,122,20, + 122,105,112,105,109,112,111,114,116,101,114,46,95,95,114,101, + 112,114,95,95,169,1,78,41,17,114,6,0,0,0,114,7, + 0,0,0,114,8,0,0,0,218,7,95,95,100,111,99,95, + 95,114,34,0,0,0,114,44,0,0,0,114,45,0,0,0, + 114,49,0,0,0,114,55,0,0,0,114,62,0,0,0,114, + 63,0,0,0,114,70,0,0,0,114,46,0,0,0,114,83, + 0,0,0,114,85,0,0,0,114,88,0,0,0,114,89,0, + 0,0,114,9,0,0,0,114,9,0,0,0,114,9,0,0, + 0,114,10,0,0,0,114,4,0,0,0,46,0,0,0,115, + 30,0,0,0,8,0,4,1,8,17,10,46,10,37,10,16, + 8,27,8,10,8,21,8,12,8,26,8,13,8,43,8,15, + 12,10,122,12,95,95,105,110,105,116,95,95,46,112,121,99, + 84,114,66,0,0,0,70,41,3,122,4,46,112,121,99,84, + 70,41,3,114,67,0,0,0,70,70,99,2,0,0,0,0, + 0,0,0,0,0,0,0,2,0,0,0,4,0,0,0,67, + 0,0,0,115,20,0,0,0,124,0,106,0,124,1,160,1, + 100,1,161,1,100,2,25,0,23,0,83,0,41,3,78,218, + 1,46,233,2,0,0,0,41,2,114,31,0,0,0,218,10, + 114,112,97,114,116,105,116,105,111,110,41,2,114,32,0,0, + 0,114,41,0,0,0,114,9,0,0,0,114,9,0,0,0, + 114,10,0,0,0,114,39,0,0,0,102,1,0,0,115,2, + 0,0,0,20,1,114,39,0,0,0,99,2,0,0,0,0, + 0,0,0,0,0,0,0,3,0,0,0,2,0,0,0,67, + 0,0,0,115,18,0,0,0,124,1,116,0,23,0,125,2, + 124,2,124,0,106,1,118,0,83,0,114,90,0,0,0,41, + 2,114,20,0,0,0,114,28,0,0,0,41,3,114,32,0, + 0,0,114,13,0,0,0,90,7,100,105,114,112,97,116,104, + 114,9,0,0,0,114,9,0,0,0,114,10,0,0,0,114, + 40,0,0,0,106,1,0,0,115,4,0,0,0,8,4,10, + 2,114,40,0,0,0,99,2,0,0,0,0,0,0,0,0, + 0,0,0,7,0,0,0,4,0,0,0,67,0,0,0,115, + 56,0,0,0,116,0,124,0,124,1,131,2,125,2,116,1, + 68,0,93,18,92,3,125,3,125,4,125,5,124,2,124,3, + 23,0,125,6,124,6,124,0,106,2,118,0,114,25,124,5, + 2,0,1,0,83,0,113,7,100,0,83,0,114,90,0,0, + 0,41,3,114,39,0,0,0,218,16,95,122,105,112,95,115, + 101,97,114,99,104,111,114,100,101,114,114,28,0,0,0,41, + 7,114,32,0,0,0,114,41,0,0,0,114,13,0,0,0, + 218,6,115,117,102,102,105,120,218,10,105,115,98,121,116,101, + 99,111,100,101,114,54,0,0,0,114,69,0,0,0,114,9, + 0,0,0,114,9,0,0,0,114,10,0,0,0,114,38,0, + 0,0,115,1,0,0,115,14,0,0,0,10,1,14,1,8, + 1,10,1,8,1,2,255,4,2,114,38,0,0,0,99,1, + 0,0,0,0,0,0,0,0,0,0,0,26,0,0,0,9, + 0,0,0,67,0,0,0,115,220,4,0,0,122,7,116,0, + 160,1,124,0,161,1,125,1,87,0,110,16,4,0,116,2, + 121,23,1,0,1,0,1,0,116,3,100,1,124,0,155,2, + 157,2,124,0,100,2,141,2,130,1,119,0,124,1,144,2, + 143,65,1,0,122,18,124,1,160,4,116,5,11,0,100,3, + 161,2,1,0,124,1,160,6,161,0,125,2,124,1,160,7, + 116,5,161,1,125,3,87,0,110,16,4,0,116,2,121,62, + 1,0,1,0,1,0,116,3,100,4,124,0,155,2,157,2, + 124,0,100,2,141,2,130,1,119,0,116,8,124,3,131,1, + 116,5,107,3,114,78,116,3,100,4,124,0,155,2,157,2, 124,0,100,2,141,2,130,1,124,3,100,0,100,5,133,2, - 25,0,116,9,107,3,144,1,114,170,122,24,124,1,160,4, - 100,6,100,3,161,2,1,0,124,1,160,6,161,0,125,4, - 87,0,110,36,4,0,116,2,121,242,1,0,1,0,1,0, - 116,3,100,4,124,0,155,2,157,2,124,0,100,2,141,2, - 130,1,89,0,110,2,48,0,116,10,124,4,116,11,24,0, - 116,5,24,0,100,6,131,2,125,5,122,22,124,1,160,4, - 124,5,161,1,1,0,124,1,160,7,161,0,125,6,87,0, - 110,38,4,0,116,2,144,1,121,66,1,0,1,0,1,0, - 116,3,100,4,124,0,155,2,157,2,124,0,100,2,141,2, - 130,1,89,0,110,2,48,0,124,6,160,12,116,9,161,1, - 125,7,124,7,100,6,107,0,144,1,114,106,116,3,100,7, - 124,0,155,2,157,2,124,0,100,2,141,2,130,1,124,6, - 124,7,124,7,116,5,23,0,133,2,25,0,125,3,116,8, - 124,3,131,1,116,5,107,3,144,1,114,154,116,3,100,8, + 25,0,116,9,107,3,114,201,122,12,124,1,160,4,100,6, + 100,3,161,2,1,0,124,1,160,6,161,0,125,4,87,0, + 110,16,4,0,116,2,121,114,1,0,1,0,1,0,116,3, + 100,4,124,0,155,2,157,2,124,0,100,2,141,2,130,1, + 119,0,116,10,124,4,116,11,24,0,116,5,24,0,100,6, + 131,2,125,5,122,11,124,1,160,4,124,5,161,1,1,0, + 124,1,160,7,161,0,125,6,87,0,110,16,4,0,116,2, + 121,151,1,0,1,0,1,0,116,3,100,4,124,0,155,2, + 157,2,124,0,100,2,141,2,130,1,119,0,124,6,160,12, + 116,9,161,1,125,7,124,7,100,6,107,0,114,170,116,3, + 100,7,124,0,155,2,157,2,124,0,100,2,141,2,130,1, + 124,6,124,7,124,7,116,5,23,0,133,2,25,0,125,3, + 116,8,124,3,131,1,116,5,107,3,114,193,116,3,100,8, 124,0,155,2,157,2,124,0,100,2,141,2,130,1,124,4, 116,8,124,6,131,1,24,0,124,7,23,0,125,2,116,13, 124,3,100,9,100,10,133,2,25,0,131,1,125,8,116,13, 124,3,100,10,100,11,133,2,25,0,131,1,125,9,124,2, - 124,8,107,0,144,1,114,230,116,3,100,12,124,0,155,2, - 157,2,124,0,100,2,141,2,130,1,124,2,124,9,107,0, - 144,2,114,2,116,3,100,13,124,0,155,2,157,2,124,0, - 100,2,141,2,130,1,124,2,124,8,56,0,125,2,124,2, - 124,9,24,0,125,10,124,10,100,6,107,0,144,2,114,46, - 116,3,100,14,124,0,155,2,157,2,124,0,100,2,141,2, - 130,1,105,0,125,11,100,6,125,12,122,14,124,1,160,4, - 124,2,161,1,1,0,87,0,110,38,4,0,116,2,144,2, - 121,106,1,0,1,0,1,0,116,3,100,4,124,0,155,2, - 157,2,124,0,100,2,141,2,130,1,89,0,110,2,48,0, - 124,1,160,7,100,15,161,1,125,3,116,8,124,3,131,1, - 100,5,107,0,144,2,114,140,116,14,100,16,131,1,130,1, - 124,3,100,0,100,5,133,2,25,0,100,17,107,3,144,2, - 114,162,144,4,113,208,116,8,124,3,131,1,100,15,107,3, - 144,2,114,184,116,14,100,16,131,1,130,1,116,15,124,3, - 100,18,100,19,133,2,25,0,131,1,125,13,116,15,124,3, - 100,19,100,9,133,2,25,0,131,1,125,14,116,15,124,3, - 100,9,100,20,133,2,25,0,131,1,125,15,116,15,124,3, - 100,20,100,10,133,2,25,0,131,1,125,16,116,13,124,3, - 100,10,100,11,133,2,25,0,131,1,125,17,116,13,124,3, - 100,11,100,21,133,2,25,0,131,1,125,18,116,13,124,3, - 100,21,100,22,133,2,25,0,131,1,125,4,116,15,124,3, - 100,22,100,23,133,2,25,0,131,1,125,19,116,15,124,3, - 100,23,100,24,133,2,25,0,131,1,125,20,116,15,124,3, - 100,24,100,25,133,2,25,0,131,1,125,21,116,13,124,3, - 100,26,100,15,133,2,25,0,131,1,125,22,124,19,124,20, - 23,0,124,21,23,0,125,8,124,22,124,9,107,4,144,3, - 114,144,116,3,100,27,124,0,155,2,157,2,124,0,100,2, - 141,2,130,1,124,22,124,10,55,0,125,22,122,14,124,1, - 160,7,124,19,161,1,125,23,87,0,110,38,4,0,116,2, - 144,3,121,204,1,0,1,0,1,0,116,3,100,4,124,0, - 155,2,157,2,124,0,100,2,141,2,130,1,89,0,110,2, - 48,0,116,8,124,23,131,1,124,19,107,3,144,3,114,238, - 116,3,100,4,124,0,155,2,157,2,124,0,100,2,141,2, - 130,1,122,50,116,8,124,1,160,7,124,8,124,19,24,0, - 161,1,131,1,124,8,124,19,24,0,107,3,144,4,114,30, - 116,3,100,4,124,0,155,2,157,2,124,0,100,2,141,2, - 130,1,87,0,110,38,4,0,116,2,144,4,121,70,1,0, + 124,8,107,0,114,230,116,3,100,12,124,0,155,2,157,2, + 124,0,100,2,141,2,130,1,124,2,124,9,107,0,114,243, + 116,3,100,13,124,0,155,2,157,2,124,0,100,2,141,2, + 130,1,124,2,124,8,56,0,125,2,124,2,124,9,24,0, + 125,10,124,10,100,6,107,0,144,1,114,9,116,3,100,14, + 124,0,155,2,157,2,124,0,100,2,141,2,130,1,105,0, + 125,11,100,6,125,12,122,7,124,1,160,4,124,2,161,1, + 1,0,87,0,110,17,4,0,116,2,144,1,121,37,1,0, 1,0,1,0,116,3,100,4,124,0,155,2,157,2,124,0, - 100,2,141,2,130,1,89,0,110,2,48,0,124,13,100,28, - 64,0,144,4,114,92,124,23,160,16,161,0,125,23,110,52, - 122,14,124,23,160,16,100,29,161,1,125,23,87,0,110,36, - 4,0,116,17,144,4,121,142,1,0,1,0,1,0,124,23, - 160,16,100,30,161,1,160,18,116,19,161,1,125,23,89,0, - 110,2,48,0,124,23,160,20,100,31,116,21,161,2,125,23, - 116,22,160,23,124,0,124,23,161,2,125,24,124,24,124,14, - 124,18,124,4,124,22,124,15,124,16,124,17,102,8,125,25, - 124,25,124,11,124,23,60,0,124,12,100,32,55,0,125,12, - 144,2,113,108,87,0,100,0,4,0,4,0,131,3,1,0, - 110,18,49,0,144,4,115,230,48,0,1,0,1,0,1,0, - 89,0,1,0,116,24,160,25,100,33,124,12,124,0,161,3, - 1,0,124,11,83,0,41,34,78,122,21,99,97,110,39,116, - 32,111,112,101,110,32,90,105,112,32,102,105,108,101,58,32, - 114,12,0,0,0,114,86,0,0,0,250,21,99,97,110,39, - 116,32,114,101,97,100,32,90,105,112,32,102,105,108,101,58, - 32,233,4,0,0,0,114,0,0,0,0,122,16,110,111,116, - 32,97,32,90,105,112,32,102,105,108,101,58,32,122,18,99, - 111,114,114,117,112,116,32,90,105,112,32,102,105,108,101,58, - 32,233,12,0,0,0,233,16,0,0,0,233,20,0,0,0, - 122,28,98,97,100,32,99,101,110,116,114,97,108,32,100,105, - 114,101,99,116,111,114,121,32,115,105,122,101,58,32,122,30, - 98,97,100,32,99,101,110,116,114,97,108,32,100,105,114,101, - 99,116,111,114,121,32,111,102,102,115,101,116,58,32,122,38, - 98,97,100,32,99,101,110,116,114,97,108,32,100,105,114,101, - 99,116,111,114,121,32,115,105,122,101,32,111,114,32,111,102, - 102,115,101,116,58,32,233,46,0,0,0,250,27,69,79,70, - 32,114,101,97,100,32,119,104,101,114,101,32,110,111,116,32, - 101,120,112,101,99,116,101,100,115,4,0,0,0,80,75,1, - 2,233,8,0,0,0,233,10,0,0,0,233,14,0,0,0, - 233,24,0,0,0,233,28,0,0,0,233,30,0,0,0,233, - 32,0,0,0,233,34,0,0,0,233,42,0,0,0,122,25, - 98,97,100,32,108,111,99,97,108,32,104,101,97,100,101,114, - 32,111,102,102,115,101,116,58,32,105,0,8,0,0,218,5, - 97,115,99,105,105,90,6,108,97,116,105,110,49,250,1,47, - 114,5,0,0,0,122,33,122,105,112,105,109,112,111,114,116, - 58,32,102,111,117,110,100,32,123,125,32,110,97,109,101,115, - 32,105,110,32,123,33,114,125,41,26,218,3,95,105,111,218, - 9,111,112,101,110,95,99,111,100,101,114,22,0,0,0,114, - 3,0,0,0,218,4,115,101,101,107,218,20,69,78,68,95, - 67,69,78,84,82,65,76,95,68,73,82,95,83,73,90,69, - 90,4,116,101,108,108,218,4,114,101,97,100,114,51,0,0, - 0,218,18,83,84,82,73,78,71,95,69,78,68,95,65,82, - 67,72,73,86,69,218,3,109,97,120,218,15,77,65,88,95, - 67,79,77,77,69,78,84,95,76,69,78,218,5,114,102,105, - 110,100,114,2,0,0,0,218,8,69,79,70,69,114,114,111, - 114,114,1,0,0,0,114,62,0,0,0,218,18,85,110,105, - 99,111,100,101,68,101,99,111,100,101,69,114,114,111,114,218, - 9,116,114,97,110,115,108,97,116,101,218,11,99,112,52,51, - 55,95,116,97,98,108,101,114,19,0,0,0,114,20,0,0, - 0,114,21,0,0,0,114,30,0,0,0,114,76,0,0,0, - 114,77,0,0,0,41,26,114,29,0,0,0,218,2,102,112, - 90,15,104,101,97,100,101,114,95,112,111,115,105,116,105,111, - 110,218,6,98,117,102,102,101,114,218,9,102,105,108,101,95, - 115,105,122,101,90,17,109,97,120,95,99,111,109,109,101,110, - 116,95,115,116,97,114,116,218,4,100,97,116,97,90,3,112, - 111,115,218,11,104,101,97,100,101,114,95,115,105,122,101,90, - 13,104,101,97,100,101,114,95,111,102,102,115,101,116,90,10, - 97,114,99,95,111,102,102,115,101,116,114,33,0,0,0,218, - 5,99,111,117,110,116,218,5,102,108,97,103,115,218,8,99, - 111,109,112,114,101,115,115,218,4,116,105,109,101,218,4,100, - 97,116,101,218,3,99,114,99,218,9,100,97,116,97,95,115, - 105,122,101,218,9,110,97,109,101,95,115,105,122,101,218,10, - 101,120,116,114,97,95,115,105,122,101,90,12,99,111,109,109, - 101,110,116,95,115,105,122,101,218,11,102,105,108,101,95,111, - 102,102,115,101,116,114,59,0,0,0,114,13,0,0,0,218, - 1,116,114,9,0,0,0,114,9,0,0,0,114,10,0,0, - 0,114,27,0,0,0,96,1,0,0,115,212,0,0,0,0, - 1,2,1,14,1,12,1,24,2,8,1,2,1,14,1,8, - 1,14,1,12,1,24,1,12,1,18,1,18,3,2,1,12, - 1,12,1,12,1,10,1,2,255,12,2,8,1,2,255,2, - 1,2,255,4,2,2,1,10,1,12,1,14,1,10,1,2, - 255,12,2,10,1,10,1,10,1,2,255,6,2,16,1,14, - 1,10,1,2,255,6,2,16,2,16,1,16,1,10,1,18, - 1,10,1,18,1,8,1,8,1,10,1,18,2,4,2,4, - 1,2,1,14,1,14,1,24,2,10,1,14,1,8,2,18, - 1,4,1,14,1,8,1,16,1,16,1,16,1,16,1,16, - 1,16,1,16,1,16,1,16,1,16,1,16,1,12,1,10, - 1,18,1,8,2,2,1,14,1,14,1,24,1,14,1,18, - 4,2,1,28,1,22,1,14,1,24,2,10,2,10,3,2, - 1,14,1,14,1,22,2,12,1,12,1,20,1,8,1,44, - 1,14,1,114,27,0,0,0,117,190,1,0,0,0,1,2, - 3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18, - 19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34, - 35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50, - 51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66, - 67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82, - 83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98, - 99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114, - 115,116,117,118,119,120,121,122,123,124,125,126,127,195,135,195, - 188,195,169,195,162,195,164,195,160,195,165,195,167,195,170,195, - 171,195,168,195,175,195,174,195,172,195,132,195,133,195,137,195, - 166,195,134,195,180,195,182,195,178,195,187,195,185,195,191,195, - 150,195,156,194,162,194,163,194,165,226,130,167,198,146,195,161, - 195,173,195,179,195,186,195,177,195,145,194,170,194,186,194,191, - 226,140,144,194,172,194,189,194,188,194,161,194,171,194,187,226, - 150,145,226,150,146,226,150,147,226,148,130,226,148,164,226,149, - 161,226,149,162,226,149,150,226,149,149,226,149,163,226,149,145, - 226,149,151,226,149,157,226,149,156,226,149,155,226,148,144,226, - 148,148,226,148,180,226,148,172,226,148,156,226,148,128,226,148, - 188,226,149,158,226,149,159,226,149,154,226,149,148,226,149,169, - 226,149,166,226,149,160,226,149,144,226,149,172,226,149,167,226, - 149,168,226,149,164,226,149,165,226,149,153,226,149,152,226,149, - 146,226,149,147,226,149,171,226,149,170,226,148,152,226,148,140, - 226,150,136,226,150,132,226,150,140,226,150,144,226,150,128,206, - 177,195,159,206,147,207,128,206,163,207,131,194,181,207,132,206, - 166,206,152,206,169,206,180,226,136,158,207,134,206,181,226,136, - 169,226,137,161,194,177,226,137,165,226,137,164,226,140,160,226, - 140,161,195,183,226,137,136,194,176,226,136,153,194,183,226,136, - 154,226,129,191,194,178,226,150,160,194,160,99,0,0,0,0, - 0,0,0,0,0,0,0,0,1,0,0,0,8,0,0,0, - 67,0,0,0,115,110,0,0,0,116,0,114,22,116,1,160, - 2,100,1,161,1,1,0,116,3,100,2,131,1,130,1,100, - 3,97,0,122,62,122,16,100,4,100,5,108,4,109,5,125, - 0,1,0,87,0,110,36,4,0,116,6,121,80,1,0,1, - 0,1,0,116,1,160,2,100,1,161,1,1,0,116,3,100, - 2,131,1,130,1,89,0,110,2,48,0,87,0,100,6,97, - 0,110,6,100,6,97,0,48,0,116,1,160,2,100,7,161, - 1,1,0,124,0,83,0,41,8,78,122,27,122,105,112,105, - 109,112,111,114,116,58,32,122,108,105,98,32,85,78,65,86, - 65,73,76,65,66,76,69,250,41,99,97,110,39,116,32,100, - 101,99,111,109,112,114,101,115,115,32,100,97,116,97,59,32, - 122,108,105,98,32,110,111,116,32,97,118,97,105,108,97,98, - 108,101,84,114,0,0,0,0,169,1,218,10,100,101,99,111, - 109,112,114,101,115,115,70,122,25,122,105,112,105,109,112,111, - 114,116,58,32,122,108,105,98,32,97,118,97,105,108,97,98, - 108,101,41,7,218,15,95,105,109,112,111,114,116,105,110,103, - 95,122,108,105,98,114,76,0,0,0,114,77,0,0,0,114, - 3,0,0,0,90,4,122,108,105,98,114,141,0,0,0,218, - 9,69,120,99,101,112,116,105,111,110,114,140,0,0,0,114, - 9,0,0,0,114,9,0,0,0,114,10,0,0,0,218,20, - 95,103,101,116,95,100,101,99,111,109,112,114,101,115,115,95, - 102,117,110,99,254,1,0,0,115,24,0,0,0,0,2,4, - 3,10,1,8,2,4,1,4,1,16,1,12,1,10,1,16, - 2,12,2,10,1,114,144,0,0,0,99,2,0,0,0,0, - 0,0,0,0,0,0,0,17,0,0,0,9,0,0,0,67, - 0,0,0,115,144,1,0,0,124,1,92,8,125,2,125,3, - 125,4,125,5,125,6,125,7,125,8,125,9,124,4,100,1, - 107,0,114,36,116,0,100,2,131,1,130,1,116,1,160,2, - 124,0,161,1,144,1,143,14,125,10,122,14,124,10,160,3, - 124,6,161,1,1,0,87,0,110,36,4,0,116,4,121,100, - 1,0,1,0,1,0,116,0,100,3,124,0,155,2,157,2, - 124,0,100,4,141,2,130,1,89,0,110,2,48,0,124,10, - 160,5,100,5,161,1,125,11,116,6,124,11,131,1,100,5, - 107,3,114,132,116,7,100,6,131,1,130,1,124,11,100,0, - 100,7,133,2,25,0,100,8,107,3,114,166,116,0,100,9, - 124,0,155,2,157,2,124,0,100,4,141,2,130,1,116,8, - 124,11,100,10,100,11,133,2,25,0,131,1,125,12,116,8, - 124,11,100,11,100,5,133,2,25,0,131,1,125,13,100,5, - 124,12,23,0,124,13,23,0,125,14,124,6,124,14,55,0, - 125,6,122,14,124,10,160,3,124,6,161,1,1,0,87,0, - 110,38,4,0,116,4,144,1,121,14,1,0,1,0,1,0, - 116,0,100,3,124,0,155,2,157,2,124,0,100,4,141,2, - 130,1,89,0,110,2,48,0,124,10,160,5,124,4,161,1, - 125,15,116,6,124,15,131,1,124,4,107,3,144,1,114,48, - 116,4,100,12,131,1,130,1,87,0,100,0,4,0,4,0, - 131,3,1,0,110,18,49,0,144,1,115,70,48,0,1,0, - 1,0,1,0,89,0,1,0,124,3,100,1,107,2,144,1, - 114,94,124,15,83,0,122,10,116,9,131,0,125,16,87,0, - 110,28,4,0,116,10,144,1,121,132,1,0,1,0,1,0, - 116,0,100,13,131,1,130,1,89,0,110,2,48,0,124,16, - 124,15,100,14,131,2,83,0,41,15,78,114,0,0,0,0, - 122,18,110,101,103,97,116,105,118,101,32,100,97,116,97,32, - 115,105,122,101,114,92,0,0,0,114,12,0,0,0,114,104, - 0,0,0,114,98,0,0,0,114,93,0,0,0,115,4,0, - 0,0,80,75,3,4,122,23,98,97,100,32,108,111,99,97, - 108,32,102,105,108,101,32,104,101,97,100,101,114,58,32,233, - 26,0,0,0,114,103,0,0,0,122,26,122,105,112,105,109, - 112,111,114,116,58,32,99,97,110,39,116,32,114,101,97,100, - 32,100,97,116,97,114,139,0,0,0,105,241,255,255,255,41, - 11,114,3,0,0,0,114,110,0,0,0,114,111,0,0,0, - 114,112,0,0,0,114,22,0,0,0,114,114,0,0,0,114, - 51,0,0,0,114,119,0,0,0,114,1,0,0,0,114,144, - 0,0,0,114,143,0,0,0,41,17,114,29,0,0,0,114, - 54,0,0,0,90,8,100,97,116,97,112,97,116,104,114,130, - 0,0,0,114,134,0,0,0,114,125,0,0,0,114,137,0, - 0,0,114,131,0,0,0,114,132,0,0,0,114,133,0,0, - 0,114,123,0,0,0,114,124,0,0,0,114,135,0,0,0, - 114,136,0,0,0,114,127,0,0,0,90,8,114,97,119,95, - 100,97,116,97,114,141,0,0,0,114,9,0,0,0,114,9, - 0,0,0,114,10,0,0,0,114,52,0,0,0,19,2,0, - 0,115,62,0,0,0,0,1,20,1,8,1,8,2,14,2, - 2,1,14,1,12,1,24,1,10,1,12,1,8,2,16,2, - 18,2,16,1,16,1,12,1,8,1,2,1,14,1,14,1, - 24,1,10,1,14,1,40,2,10,2,4,3,2,1,10,1, - 14,1,14,1,114,52,0,0,0,99,2,0,0,0,0,0, - 0,0,0,0,0,0,2,0,0,0,3,0,0,0,67,0, - 0,0,115,16,0,0,0,116,0,124,0,124,1,24,0,131, - 1,100,1,107,1,83,0,41,2,78,114,5,0,0,0,41, - 1,218,3,97,98,115,41,2,90,2,116,49,90,2,116,50, - 114,9,0,0,0,114,9,0,0,0,114,10,0,0,0,218, - 9,95,101,113,95,109,116,105,109,101,65,2,0,0,115,2, - 0,0,0,0,2,114,147,0,0,0,99,5,0,0,0,0, - 0,0,0,0,0,0,0,14,0,0,0,8,0,0,0,67, - 0,0,0,115,56,1,0,0,124,3,124,2,100,1,156,2, - 125,5,122,18,116,0,160,1,124,4,124,3,124,5,161,3, - 125,6,87,0,110,20,4,0,116,2,121,48,1,0,1,0, - 1,0,89,0,100,0,83,0,48,0,124,6,100,2,64,0, - 100,3,107,3,125,7,124,7,114,178,124,6,100,4,64,0, - 100,3,107,3,125,8,116,3,106,4,100,5,107,3,114,176, - 124,8,115,102,116,3,106,4,100,6,107,2,114,176,116,5, - 124,0,124,2,131,2,125,9,124,9,100,0,117,1,114,176, - 116,3,160,6,116,0,106,7,124,9,161,2,125,10,122,20, - 116,0,160,8,124,4,124,10,124,3,124,5,161,4,1,0, - 87,0,110,20,4,0,116,2,121,174,1,0,1,0,1,0, - 89,0,100,0,83,0,48,0,110,84,116,9,124,0,124,2, - 131,2,92,2,125,11,125,12,124,11,144,1,114,6,116,10, - 116,11,124,4,100,7,100,8,133,2,25,0,131,1,124,11, - 131,2,114,242,116,11,124,4,100,8,100,9,133,2,25,0, - 131,1,124,12,107,3,144,1,114,6,116,12,160,13,100,10, - 124,3,155,2,157,2,161,1,1,0,100,0,83,0,116,14, - 160,15,124,4,100,9,100,0,133,2,25,0,161,1,125,13, - 116,16,124,13,116,17,131,2,144,1,115,52,116,18,100,11, - 124,1,155,2,100,12,157,3,131,1,130,1,124,13,83,0, - 41,13,78,41,2,114,59,0,0,0,114,13,0,0,0,114, - 5,0,0,0,114,0,0,0,0,114,86,0,0,0,90,5, - 110,101,118,101,114,90,6,97,108,119,97,121,115,114,99,0, - 0,0,114,94,0,0,0,114,95,0,0,0,122,22,98,121, - 116,101,99,111,100,101,32,105,115,32,115,116,97,108,101,32, - 102,111,114,32,122,16,99,111,109,112,105,108,101,100,32,109, - 111,100,117,108,101,32,122,21,32,105,115,32,110,111,116,32, - 97,32,99,111,100,101,32,111,98,106,101,99,116,41,19,114, - 21,0,0,0,90,13,95,99,108,97,115,115,105,102,121,95, - 112,121,99,114,75,0,0,0,218,4,95,105,109,112,90,21, + 100,2,141,2,130,1,119,0,9,0,124,1,160,7,100,16, + 161,1,125,3,116,8,124,3,131,1,100,5,107,0,144,1, + 114,55,116,14,100,17,131,1,130,1,124,3,100,0,100,5, + 133,2,25,0,100,18,107,3,144,1,114,66,144,1,110,19, + 116,8,124,3,131,1,100,16,107,3,144,1,114,77,116,14, + 100,17,131,1,130,1,116,15,124,3,100,19,100,20,133,2, + 25,0,131,1,125,13,116,15,124,3,100,20,100,9,133,2, + 25,0,131,1,125,14,116,15,124,3,100,9,100,21,133,2, + 25,0,131,1,125,15,116,15,124,3,100,21,100,10,133,2, + 25,0,131,1,125,16,116,13,124,3,100,10,100,11,133,2, + 25,0,131,1,125,17,116,13,124,3,100,11,100,22,133,2, + 25,0,131,1,125,18,116,13,124,3,100,22,100,23,133,2, + 25,0,131,1,125,4,116,15,124,3,100,23,100,24,133,2, + 25,0,131,1,125,19,116,15,124,3,100,24,100,25,133,2, + 25,0,131,1,125,20,116,15,124,3,100,25,100,26,133,2, + 25,0,131,1,125,21,116,13,124,3,100,27,100,16,133,2, + 25,0,131,1,125,22,124,19,124,20,23,0,124,21,23,0, + 125,8,124,22,124,9,107,4,144,1,114,185,116,3,100,28, + 124,0,155,2,157,2,124,0,100,2,141,2,130,1,124,22, + 124,10,55,0,125,22,122,7,124,1,160,7,124,19,161,1, + 125,23,87,0,110,17,4,0,116,2,144,1,121,213,1,0, + 1,0,1,0,116,3,100,4,124,0,155,2,157,2,124,0, + 100,2,141,2,130,1,119,0,116,8,124,23,131,1,124,19, + 107,3,144,1,114,230,116,3,100,4,124,0,155,2,157,2, + 124,0,100,2,141,2,130,1,122,25,116,8,124,1,160,7, + 124,8,124,19,24,0,161,1,131,1,124,8,124,19,24,0, + 107,3,144,1,114,254,116,3,100,4,124,0,155,2,157,2, + 124,0,100,2,141,2,130,1,87,0,110,17,4,0,116,2, + 144,2,121,16,1,0,1,0,1,0,116,3,100,4,124,0, + 155,2,157,2,124,0,100,2,141,2,130,1,119,0,124,13, + 100,29,64,0,144,2,114,27,124,23,160,16,161,0,125,23, + 110,26,122,7,124,23,160,16,100,30,161,1,125,23,87,0, + 110,18,4,0,116,17,144,2,121,52,1,0,1,0,1,0, + 124,23,160,16,100,31,161,1,160,18,116,19,161,1,125,23, + 89,0,110,1,119,0,124,23,160,20,100,32,116,21,161,2, + 125,23,116,22,160,23,124,0,124,23,161,2,125,24,124,24, + 124,14,124,18,124,4,124,22,124,15,124,16,124,17,102,8, + 125,25,124,25,124,11,124,23,60,0,124,12,100,33,55,0, + 125,12,144,1,113,39,87,0,100,0,4,0,4,0,131,3, + 1,0,110,9,49,0,144,2,115,96,119,1,1,0,1,0, + 1,0,89,0,1,0,116,24,160,25,100,34,124,12,124,0, + 161,3,1,0,124,11,83,0,41,35,78,122,21,99,97,110, + 39,116,32,111,112,101,110,32,90,105,112,32,102,105,108,101, + 58,32,114,12,0,0,0,114,93,0,0,0,250,21,99,97, + 110,39,116,32,114,101,97,100,32,90,105,112,32,102,105,108, + 101,58,32,233,4,0,0,0,114,0,0,0,0,122,16,110, + 111,116,32,97,32,90,105,112,32,102,105,108,101,58,32,122, + 18,99,111,114,114,117,112,116,32,90,105,112,32,102,105,108, + 101,58,32,233,12,0,0,0,233,16,0,0,0,233,20,0, + 0,0,122,28,98,97,100,32,99,101,110,116,114,97,108,32, + 100,105,114,101,99,116,111,114,121,32,115,105,122,101,58,32, + 122,30,98,97,100,32,99,101,110,116,114,97,108,32,100,105, + 114,101,99,116,111,114,121,32,111,102,102,115,101,116,58,32, + 122,38,98,97,100,32,99,101,110,116,114,97,108,32,100,105, + 114,101,99,116,111,114,121,32,115,105,122,101,32,111,114,32, + 111,102,102,115,101,116,58,32,84,233,46,0,0,0,250,27, + 69,79,70,32,114,101,97,100,32,119,104,101,114,101,32,110, + 111,116,32,101,120,112,101,99,116,101,100,115,4,0,0,0, + 80,75,1,2,233,8,0,0,0,233,10,0,0,0,233,14, + 0,0,0,233,24,0,0,0,233,28,0,0,0,233,30,0, + 0,0,233,32,0,0,0,233,34,0,0,0,233,42,0,0, + 0,122,25,98,97,100,32,108,111,99,97,108,32,104,101,97, + 100,101,114,32,111,102,102,115,101,116,58,32,105,0,8,0, + 0,218,5,97,115,99,105,105,90,6,108,97,116,105,110,49, + 250,1,47,114,5,0,0,0,122,33,122,105,112,105,109,112, + 111,114,116,58,32,102,111,117,110,100,32,123,125,32,110,97, + 109,101,115,32,105,110,32,123,33,114,125,41,26,218,3,95, + 105,111,218,9,111,112,101,110,95,99,111,100,101,114,22,0, + 0,0,114,3,0,0,0,218,4,115,101,101,107,218,20,69, + 78,68,95,67,69,78,84,82,65,76,95,68,73,82,95,83, + 73,90,69,90,4,116,101,108,108,218,4,114,101,97,100,114, + 58,0,0,0,218,18,83,84,82,73,78,71,95,69,78,68, + 95,65,82,67,72,73,86,69,218,3,109,97,120,218,15,77, + 65,88,95,67,79,77,77,69,78,84,95,76,69,78,218,5, + 114,102,105,110,100,114,2,0,0,0,218,8,69,79,70,69, + 114,114,111,114,114,1,0,0,0,114,68,0,0,0,218,18, + 85,110,105,99,111,100,101,68,101,99,111,100,101,69,114,114, + 111,114,218,9,116,114,97,110,115,108,97,116,101,218,11,99, + 112,52,51,55,95,116,97,98,108,101,114,19,0,0,0,114, + 20,0,0,0,114,21,0,0,0,114,30,0,0,0,114,48, + 0,0,0,114,81,0,0,0,41,26,114,29,0,0,0,218, + 2,102,112,90,15,104,101,97,100,101,114,95,112,111,115,105, + 116,105,111,110,218,6,98,117,102,102,101,114,218,9,102,105, + 108,101,95,115,105,122,101,90,17,109,97,120,95,99,111,109, + 109,101,110,116,95,115,116,97,114,116,218,4,100,97,116,97, + 90,3,112,111,115,218,11,104,101,97,100,101,114,95,115,105, + 122,101,90,13,104,101,97,100,101,114,95,111,102,102,115,101, + 116,90,10,97,114,99,95,111,102,102,115,101,116,114,33,0, + 0,0,218,5,99,111,117,110,116,218,5,102,108,97,103,115, + 218,8,99,111,109,112,114,101,115,115,218,4,116,105,109,101, + 218,4,100,97,116,101,218,3,99,114,99,218,9,100,97,116, + 97,95,115,105,122,101,218,9,110,97,109,101,95,115,105,122, + 101,218,10,101,120,116,114,97,95,115,105,122,101,90,12,99, + 111,109,109,101,110,116,95,115,105,122,101,218,11,102,105,108, + 101,95,111,102,102,115,101,116,114,47,0,0,0,114,13,0, + 0,0,218,1,116,114,9,0,0,0,114,9,0,0,0,114, + 10,0,0,0,114,27,0,0,0,146,1,0,0,115,238,0, + 0,0,2,1,14,1,12,1,18,1,2,255,8,3,2,1, + 14,1,8,1,14,1,12,1,18,1,2,255,12,2,18,1, + 16,1,2,3,12,1,12,1,12,1,10,1,2,1,6,255, + 2,255,8,3,2,1,2,255,2,1,4,255,2,2,10,1, + 12,1,12,1,10,1,2,1,6,255,2,255,10,3,8,1, + 10,1,2,1,6,255,16,2,12,1,10,1,2,1,6,255, + 16,2,16,2,16,1,8,1,18,1,8,1,18,1,8,1, + 8,1,10,1,18,1,4,2,4,2,2,1,14,1,14,1, + 18,1,2,255,2,2,10,1,14,1,8,1,18,2,4,1, + 14,1,8,1,16,1,16,1,16,1,16,1,16,1,16,1, + 16,1,16,1,16,1,16,1,16,1,12,1,10,1,18,1, + 8,1,2,2,14,1,14,1,18,1,2,255,14,2,18,1, + 2,4,28,1,18,1,4,255,14,2,18,1,2,255,10,3, + 10,2,2,3,14,1,14,1,20,1,2,255,12,3,12,1, + 20,1,8,1,8,1,4,202,2,6,30,196,14,109,4,1, + 114,27,0,0,0,117,190,1,0,0,0,1,2,3,4,5, + 6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21, + 22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37, + 38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53, + 54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69, + 70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85, + 86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101, + 102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117, + 118,119,120,121,122,123,124,125,126,127,195,135,195,188,195,169, + 195,162,195,164,195,160,195,165,195,167,195,170,195,171,195,168, + 195,175,195,174,195,172,195,132,195,133,195,137,195,166,195,134, + 195,180,195,182,195,178,195,187,195,185,195,191,195,150,195,156, + 194,162,194,163,194,165,226,130,167,198,146,195,161,195,173,195, + 179,195,186,195,177,195,145,194,170,194,186,194,191,226,140,144, + 194,172,194,189,194,188,194,161,194,171,194,187,226,150,145,226, + 150,146,226,150,147,226,148,130,226,148,164,226,149,161,226,149, + 162,226,149,150,226,149,149,226,149,163,226,149,145,226,149,151, + 226,149,157,226,149,156,226,149,155,226,148,144,226,148,148,226, + 148,180,226,148,172,226,148,156,226,148,128,226,148,188,226,149, + 158,226,149,159,226,149,154,226,149,148,226,149,169,226,149,166, + 226,149,160,226,149,144,226,149,172,226,149,167,226,149,168,226, + 149,164,226,149,165,226,149,153,226,149,152,226,149,146,226,149, + 147,226,149,171,226,149,170,226,148,152,226,148,140,226,150,136, + 226,150,132,226,150,140,226,150,144,226,150,128,206,177,195,159, + 206,147,207,128,206,163,207,131,194,181,207,132,206,166,206,152, + 206,169,206,180,226,136,158,207,134,206,181,226,136,169,226,137, + 161,194,177,226,137,165,226,137,164,226,140,160,226,140,161,195, + 183,226,137,136,194,176,226,136,153,194,183,226,136,154,226,129, + 191,194,178,226,150,160,194,160,99,0,0,0,0,0,0,0, + 0,0,0,0,0,1,0,0,0,8,0,0,0,67,0,0, + 0,115,106,0,0,0,116,0,114,11,116,1,160,2,100,1, + 161,1,1,0,116,3,100,2,131,1,130,1,100,3,97,0, + 122,29,122,8,100,4,100,5,108,4,109,5,125,0,1,0, + 87,0,110,16,4,0,116,6,121,38,1,0,1,0,1,0, + 116,1,160,2,100,1,161,1,1,0,116,3,100,2,131,1, + 130,1,119,0,87,0,100,6,97,0,110,3,100,6,97,0, + 119,0,116,1,160,2,100,7,161,1,1,0,124,0,83,0, + 41,8,78,122,27,122,105,112,105,109,112,111,114,116,58,32, + 122,108,105,98,32,85,78,65,86,65,73,76,65,66,76,69, + 250,41,99,97,110,39,116,32,100,101,99,111,109,112,114,101, + 115,115,32,100,97,116,97,59,32,122,108,105,98,32,110,111, + 116,32,97,118,97,105,108,97,98,108,101,84,114,0,0,0, + 0,169,1,218,10,100,101,99,111,109,112,114,101,115,115,70, + 122,25,122,105,112,105,109,112,111,114,116,58,32,122,108,105, + 98,32,97,118,97,105,108,97,98,108,101,41,7,218,15,95, + 105,109,112,111,114,116,105,110,103,95,122,108,105,98,114,48, + 0,0,0,114,81,0,0,0,114,3,0,0,0,90,4,122, + 108,105,98,114,147,0,0,0,218,9,69,120,99,101,112,116, + 105,111,110,114,146,0,0,0,114,9,0,0,0,114,9,0, + 0,0,114,10,0,0,0,218,20,95,103,101,116,95,100,101, + 99,111,109,112,114,101,115,115,95,102,117,110,99,48,2,0, + 0,115,28,0,0,0,4,2,10,3,8,1,4,2,4,1, + 16,1,12,1,10,1,8,1,2,254,2,255,12,5,10,2, + 4,1,114,150,0,0,0,99,2,0,0,0,0,0,0,0, + 0,0,0,0,17,0,0,0,9,0,0,0,67,0,0,0, + 115,120,1,0,0,124,1,92,8,125,2,125,3,125,4,125, + 5,125,6,125,7,125,8,125,9,124,4,100,1,107,0,114, + 18,116,0,100,2,131,1,130,1,116,1,160,2,124,0,161, + 1,143,129,125,10,122,7,124,10,160,3,124,6,161,1,1, + 0,87,0,110,16,4,0,116,4,121,47,1,0,1,0,1, + 0,116,0,100,3,124,0,155,2,157,2,124,0,100,4,141, + 2,130,1,119,0,124,10,160,5,100,5,161,1,125,11,116, + 6,124,11,131,1,100,5,107,3,114,63,116,7,100,6,131, + 1,130,1,124,11,100,0,100,7,133,2,25,0,100,8,107, + 3,114,80,116,0,100,9,124,0,155,2,157,2,124,0,100, + 4,141,2,130,1,116,8,124,11,100,10,100,11,133,2,25, + 0,131,1,125,12,116,8,124,11,100,11,100,5,133,2,25, + 0,131,1,125,13,100,5,124,12,23,0,124,13,23,0,125, + 14,124,6,124,14,55,0,125,6,122,7,124,10,160,3,124, + 6,161,1,1,0,87,0,110,16,4,0,116,4,121,129,1, + 0,1,0,1,0,116,0,100,3,124,0,155,2,157,2,124, + 0,100,4,141,2,130,1,119,0,124,10,160,5,124,4,161, + 1,125,15,116,6,124,15,131,1,124,4,107,3,114,145,116, + 4,100,12,131,1,130,1,87,0,100,0,4,0,4,0,131, + 3,1,0,110,8,49,0,115,155,119,1,1,0,1,0,1, + 0,89,0,1,0,124,3,100,1,107,2,114,166,124,15,83, + 0,122,5,116,9,131,0,125,16,87,0,110,11,4,0,116, + 10,121,182,1,0,1,0,1,0,116,0,100,13,131,1,130, + 1,119,0,124,16,124,15,100,14,131,2,83,0,41,15,78, + 114,0,0,0,0,122,18,110,101,103,97,116,105,118,101,32, + 100,97,116,97,32,115,105,122,101,114,98,0,0,0,114,12, + 0,0,0,114,110,0,0,0,114,104,0,0,0,114,99,0, + 0,0,115,4,0,0,0,80,75,3,4,122,23,98,97,100, + 32,108,111,99,97,108,32,102,105,108,101,32,104,101,97,100, + 101,114,58,32,233,26,0,0,0,114,109,0,0,0,122,26, + 122,105,112,105,109,112,111,114,116,58,32,99,97,110,39,116, + 32,114,101,97,100,32,100,97,116,97,114,145,0,0,0,105, + 241,255,255,255,41,11,114,3,0,0,0,114,116,0,0,0, + 114,117,0,0,0,114,118,0,0,0,114,22,0,0,0,114, + 120,0,0,0,114,58,0,0,0,114,125,0,0,0,114,1, + 0,0,0,114,150,0,0,0,114,149,0,0,0,41,17,114, + 29,0,0,0,114,61,0,0,0,90,8,100,97,116,97,112, + 97,116,104,114,136,0,0,0,114,140,0,0,0,114,131,0, + 0,0,114,143,0,0,0,114,137,0,0,0,114,138,0,0, + 0,114,139,0,0,0,114,129,0,0,0,114,130,0,0,0, + 114,141,0,0,0,114,142,0,0,0,114,133,0,0,0,90, + 8,114,97,119,95,100,97,116,97,114,147,0,0,0,114,9, + 0,0,0,114,9,0,0,0,114,10,0,0,0,114,59,0, + 0,0,69,2,0,0,115,72,0,0,0,20,1,8,1,8, + 1,12,2,2,2,14,1,12,1,18,1,2,255,10,2,12, + 1,8,1,16,2,18,2,16,2,16,1,12,1,8,1,2, + 1,14,1,12,1,18,1,2,255,10,2,12,1,8,1,2, + 255,28,233,8,26,4,2,2,3,10,1,12,1,8,1,2, + 255,10,2,114,59,0,0,0,99,2,0,0,0,0,0,0, + 0,0,0,0,0,2,0,0,0,3,0,0,0,67,0,0, + 0,115,16,0,0,0,116,0,124,0,124,1,24,0,131,1, + 100,1,107,1,83,0,41,2,78,114,5,0,0,0,41,1, + 218,3,97,98,115,41,2,90,2,116,49,90,2,116,50,114, + 9,0,0,0,114,9,0,0,0,114,10,0,0,0,218,9, + 95,101,113,95,109,116,105,109,101,115,2,0,0,115,2,0, + 0,0,16,2,114,153,0,0,0,99,5,0,0,0,0,0, + 0,0,0,0,0,0,14,0,0,0,6,0,0,0,67,0, + 0,0,115,254,0,0,0,124,3,124,2,100,1,156,2,125, + 5,116,0,160,1,124,4,124,3,124,5,161,3,125,6,124, + 6,100,2,64,0,100,3,107,3,125,7,124,7,114,63,124, + 6,100,4,64,0,100,3,107,3,125,8,116,2,106,3,100, + 5,107,3,114,62,124,8,115,38,116,2,106,3,100,6,107, + 2,114,62,116,4,124,0,124,2,131,2,125,9,124,9,100, + 0,117,1,114,62,116,2,160,5,116,0,106,6,124,9,161, + 2,125,10,116,0,160,7,124,4,124,10,124,3,124,5,161, + 4,1,0,110,40,116,8,124,0,124,2,131,2,92,2,125, + 11,125,12,124,11,114,103,116,9,116,10,124,4,100,7,100, + 8,133,2,25,0,131,1,124,11,131,2,114,93,116,10,124, + 4,100,8,100,9,133,2,25,0,131,1,124,12,107,3,114, + 103,116,11,160,12,100,10,124,3,155,2,157,2,161,1,1, + 0,100,0,83,0,116,13,160,14,124,4,100,9,100,0,133, + 2,25,0,161,1,125,13,116,15,124,13,116,16,131,2,115, + 125,116,17,100,11,124,1,155,2,100,12,157,3,131,1,130, + 1,124,13,83,0,41,13,78,41,2,114,47,0,0,0,114, + 13,0,0,0,114,5,0,0,0,114,0,0,0,0,114,93, + 0,0,0,90,5,110,101,118,101,114,90,6,97,108,119,97, + 121,115,114,105,0,0,0,114,100,0,0,0,114,101,0,0, + 0,122,22,98,121,116,101,99,111,100,101,32,105,115,32,115, + 116,97,108,101,32,102,111,114,32,122,16,99,111,109,112,105, + 108,101,100,32,109,111,100,117,108,101,32,122,21,32,105,115, + 32,110,111,116,32,97,32,99,111,100,101,32,111,98,106,101, + 99,116,41,18,114,21,0,0,0,90,13,95,99,108,97,115, + 115,105,102,121,95,112,121,99,218,4,95,105,109,112,90,21, 99,104,101,99,107,95,104,97,115,104,95,98,97,115,101,100, 95,112,121,99,115,218,15,95,103,101,116,95,112,121,99,95, 115,111,117,114,99,101,218,11,115,111,117,114,99,101,95,104, @@ -821,259 +907,157 @@ const unsigned char _Py_M__zipimport[] = { 78,85,77,66,69,82,90,18,95,118,97,108,105,100,97,116, 101,95,104,97,115,104,95,112,121,99,218,29,95,103,101,116, 95,109,116,105,109,101,95,97,110,100,95,115,105,122,101,95, - 111,102,95,115,111,117,114,99,101,114,147,0,0,0,114,2, - 0,0,0,114,76,0,0,0,114,77,0,0,0,218,7,109, + 111,102,95,115,111,117,114,99,101,114,153,0,0,0,114,2, + 0,0,0,114,48,0,0,0,114,81,0,0,0,218,7,109, 97,114,115,104,97,108,90,5,108,111,97,100,115,114,15,0, 0,0,218,10,95,99,111,100,101,95,116,121,112,101,218,9, 84,121,112,101,69,114,114,111,114,41,14,114,32,0,0,0, - 114,53,0,0,0,114,63,0,0,0,114,38,0,0,0,114, - 126,0,0,0,90,11,101,120,99,95,100,101,116,97,105,108, - 115,114,129,0,0,0,90,10,104,97,115,104,95,98,97,115, + 114,60,0,0,0,114,69,0,0,0,114,41,0,0,0,114, + 132,0,0,0,90,11,101,120,99,95,100,101,116,97,105,108, + 115,114,135,0,0,0,90,10,104,97,115,104,95,98,97,115, 101,100,90,12,99,104,101,99,107,95,115,111,117,114,99,101, - 90,12,115,111,117,114,99,101,95,98,121,116,101,115,114,150, + 90,12,115,111,117,114,99,101,95,98,121,116,101,115,114,156, 0,0,0,90,12,115,111,117,114,99,101,95,109,116,105,109, - 101,90,11,115,111,117,114,99,101,95,115,105,122,101,114,46, + 101,90,11,115,111,117,114,99,101,95,115,105,122,101,114,53, 0,0,0,114,9,0,0,0,114,9,0,0,0,114,10,0, 0,0,218,15,95,117,110,109,97,114,115,104,97,108,95,99, - 111,100,101,75,2,0,0,115,82,0,0,0,0,2,2,1, - 2,254,6,5,2,1,18,1,12,1,8,2,12,1,4,1, - 12,1,10,1,2,255,2,1,8,255,2,2,10,1,8,1, - 4,1,4,1,2,254,4,5,2,1,4,1,8,255,8,2, - 12,1,10,3,8,255,6,3,6,3,22,1,18,255,4,2, - 4,1,8,255,4,2,4,2,18,1,12,1,16,1,114,155, - 0,0,0,99,1,0,0,0,0,0,0,0,0,0,0,0, - 1,0,0,0,4,0,0,0,67,0,0,0,115,28,0,0, - 0,124,0,160,0,100,1,100,2,161,2,125,0,124,0,160, - 0,100,3,100,2,161,2,125,0,124,0,83,0,41,4,78, - 115,2,0,0,0,13,10,243,1,0,0,0,10,243,1,0, - 0,0,13,41,1,114,19,0,0,0,41,1,218,6,115,111, - 117,114,99,101,114,9,0,0,0,114,9,0,0,0,114,10, - 0,0,0,218,23,95,110,111,114,109,97,108,105,122,101,95, - 108,105,110,101,95,101,110,100,105,110,103,115,126,2,0,0, - 115,6,0,0,0,0,1,12,1,12,1,114,159,0,0,0, - 99,2,0,0,0,0,0,0,0,0,0,0,0,2,0,0, - 0,6,0,0,0,67,0,0,0,115,24,0,0,0,116,0, - 124,1,131,1,125,1,116,1,124,1,124,0,100,1,100,2, - 100,3,141,4,83,0,41,4,78,114,74,0,0,0,84,41, - 1,90,12,100,111,110,116,95,105,110,104,101,114,105,116,41, - 2,114,159,0,0,0,218,7,99,111,109,112,105,108,101,41, - 2,114,53,0,0,0,114,158,0,0,0,114,9,0,0,0, - 114,9,0,0,0,114,10,0,0,0,218,15,95,99,111,109, - 112,105,108,101,95,115,111,117,114,99,101,133,2,0,0,115, - 4,0,0,0,0,1,8,1,114,161,0,0,0,99,2,0, - 0,0,0,0,0,0,0,0,0,0,2,0,0,0,11,0, - 0,0,67,0,0,0,115,68,0,0,0,116,0,160,1,124, - 0,100,1,63,0,100,2,23,0,124,0,100,3,63,0,100, - 4,64,0,124,0,100,5,64,0,124,1,100,6,63,0,124, - 1,100,3,63,0,100,7,64,0,124,1,100,5,64,0,100, - 8,20,0,100,9,100,9,100,9,102,9,161,1,83,0,41, - 10,78,233,9,0,0,0,105,188,7,0,0,233,5,0,0, - 0,233,15,0,0,0,233,31,0,0,0,233,11,0,0,0, - 233,63,0,0,0,114,86,0,0,0,114,14,0,0,0,41, - 2,114,131,0,0,0,90,6,109,107,116,105,109,101,41,2, - 218,1,100,114,138,0,0,0,114,9,0,0,0,114,9,0, - 0,0,114,10,0,0,0,218,14,95,112,97,114,115,101,95, - 100,111,115,116,105,109,101,139,2,0,0,115,18,0,0,0, - 0,1,4,1,10,1,10,1,6,1,6,1,10,1,10,1, - 6,249,114,169,0,0,0,99,2,0,0,0,0,0,0,0, - 0,0,0,0,6,0,0,0,10,0,0,0,67,0,0,0, - 115,114,0,0,0,122,82,124,1,100,1,100,0,133,2,25, - 0,100,2,118,0,115,22,74,0,130,1,124,1,100,0,100, - 1,133,2,25,0,125,1,124,0,106,0,124,1,25,0,125, - 2,124,2,100,3,25,0,125,3,124,2,100,4,25,0,125, - 4,124,2,100,5,25,0,125,5,116,1,124,4,124,3,131, - 2,124,5,102,2,87,0,83,0,4,0,116,2,116,3,116, - 4,102,3,121,108,1,0,1,0,1,0,89,0,100,6,83, - 0,48,0,100,0,83,0,41,7,78,114,14,0,0,0,169, - 2,218,1,99,218,1,111,114,163,0,0,0,233,6,0,0, - 0,233,3,0,0,0,41,2,114,0,0,0,0,114,0,0, - 0,0,41,5,114,28,0,0,0,114,169,0,0,0,114,26, - 0,0,0,218,10,73,110,100,101,120,69,114,114,111,114,114, - 154,0,0,0,41,6,114,32,0,0,0,114,13,0,0,0, - 114,54,0,0,0,114,131,0,0,0,114,132,0,0,0,90, - 17,117,110,99,111,109,112,114,101,115,115,101,100,95,115,105, - 122,101,114,9,0,0,0,114,9,0,0,0,114,10,0,0, - 0,114,151,0,0,0,152,2,0,0,115,20,0,0,0,0, - 1,2,2,20,1,12,1,10,3,8,1,8,1,8,1,16, - 1,18,1,114,151,0,0,0,99,2,0,0,0,0,0,0, - 0,0,0,0,0,3,0,0,0,8,0,0,0,67,0,0, - 0,115,84,0,0,0,124,1,100,1,100,0,133,2,25,0, - 100,2,118,0,115,20,74,0,130,1,124,1,100,0,100,1, - 133,2,25,0,125,1,122,14,124,0,106,0,124,1,25,0, - 125,2,87,0,110,20,4,0,116,1,121,66,1,0,1,0, - 1,0,89,0,100,0,83,0,48,0,116,2,124,0,106,3, - 124,2,131,2,83,0,100,0,83,0,41,3,78,114,14,0, - 0,0,114,170,0,0,0,41,4,114,28,0,0,0,114,26, - 0,0,0,114,52,0,0,0,114,29,0,0,0,41,3,114, - 32,0,0,0,114,13,0,0,0,114,54,0,0,0,114,9, - 0,0,0,114,9,0,0,0,114,10,0,0,0,114,149,0, - 0,0,171,2,0,0,115,14,0,0,0,0,2,20,1,12, - 2,2,1,14,1,12,1,8,2,114,149,0,0,0,99,2, - 0,0,0,0,0,0,0,0,0,0,0,11,0,0,0,9, - 0,0,0,67,0,0,0,115,196,0,0,0,116,0,124,0, - 124,1,131,2,125,2,116,1,68,0,93,158,92,3,125,3, - 125,4,125,5,124,2,124,3,23,0,125,6,116,2,106,3, - 100,1,124,0,106,4,116,5,124,6,100,2,100,3,141,5, - 1,0,122,14,124,0,106,6,124,6,25,0,125,7,87,0, - 110,18,4,0,116,7,121,86,1,0,1,0,1,0,89,0, - 113,14,48,0,124,7,100,4,25,0,125,8,116,8,124,0, - 106,4,124,7,131,2,125,9,124,4,114,130,116,9,124,0, - 124,8,124,6,124,1,124,9,131,5,125,10,110,10,116,10, - 124,8,124,9,131,2,125,10,124,10,100,0,117,0,114,150, - 113,14,124,7,100,4,25,0,125,8,124,10,124,5,124,8, - 102,3,2,0,1,0,83,0,113,14,116,11,100,5,124,1, - 155,2,157,2,124,1,100,6,141,2,130,1,100,0,83,0, - 41,7,78,122,13,116,114,121,105,110,103,32,123,125,123,125, - 123,125,114,86,0,0,0,41,1,90,9,118,101,114,98,111, - 115,105,116,121,114,0,0,0,0,114,57,0,0,0,114,58, - 0,0,0,41,12,114,36,0,0,0,114,89,0,0,0,114, - 76,0,0,0,114,77,0,0,0,114,29,0,0,0,114,20, - 0,0,0,114,28,0,0,0,114,26,0,0,0,114,52,0, - 0,0,114,155,0,0,0,114,161,0,0,0,114,3,0,0, - 0,41,11,114,32,0,0,0,114,38,0,0,0,114,13,0, - 0,0,114,90,0,0,0,114,91,0,0,0,114,47,0,0, - 0,114,63,0,0,0,114,54,0,0,0,114,40,0,0,0, - 114,126,0,0,0,114,46,0,0,0,114,9,0,0,0,114, - 9,0,0,0,114,10,0,0,0,114,44,0,0,0,186,2, - 0,0,115,36,0,0,0,0,1,10,1,14,1,8,1,22, - 1,2,1,14,1,12,1,6,2,8,1,12,1,4,1,18, - 2,10,1,8,3,2,1,8,1,16,2,114,44,0,0,0, - 99,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,2,0,0,0,64,0,0,0,115,60,0,0,0,101,0, - 90,1,100,0,90,2,100,1,90,3,100,2,90,4,100,3, - 100,4,132,0,90,5,100,5,100,6,132,0,90,6,100,7, - 100,8,132,0,90,7,100,9,100,10,132,0,90,8,100,11, - 100,12,132,0,90,9,100,13,83,0,41,14,114,80,0,0, - 0,122,165,80,114,105,118,97,116,101,32,99,108,97,115,115, - 32,117,115,101,100,32,116,111,32,115,117,112,112,111,114,116, - 32,90,105,112,73,109,112,111,114,116,46,103,101,116,95,114, - 101,115,111,117,114,99,101,95,114,101,97,100,101,114,40,41, - 46,10,10,32,32,32,32,84,104,105,115,32,99,108,97,115, - 115,32,105,115,32,97,108,108,111,119,101,100,32,116,111,32, - 114,101,102,101,114,101,110,99,101,32,97,108,108,32,116,104, - 101,32,105,110,110,97,114,100,115,32,97,110,100,32,112,114, - 105,118,97,116,101,32,112,97,114,116,115,32,111,102,10,32, - 32,32,32,116,104,101,32,122,105,112,105,109,112,111,114,116, - 101,114,46,10,32,32,32,32,70,99,3,0,0,0,0,0, - 0,0,0,0,0,0,3,0,0,0,2,0,0,0,67,0, - 0,0,115,16,0,0,0,124,1,124,0,95,0,124,2,124, - 0,95,1,100,0,83,0,114,88,0,0,0,41,2,114,4, - 0,0,0,114,38,0,0,0,41,3,114,32,0,0,0,114, - 4,0,0,0,114,38,0,0,0,114,9,0,0,0,114,9, - 0,0,0,114,10,0,0,0,114,34,0,0,0,220,2,0, - 0,115,4,0,0,0,0,1,6,1,122,33,95,90,105,112, - 73,109,112,111,114,116,82,101,115,111,117,114,99,101,82,101, - 97,100,101,114,46,95,95,105,110,105,116,95,95,99,2,0, - 0,0,0,0,0,0,0,0,0,0,5,0,0,0,8,0, - 0,0,67,0,0,0,115,90,0,0,0,124,0,106,0,160, - 1,100,1,100,2,161,2,125,2,124,2,155,0,100,2,124, - 1,155,0,157,3,125,3,100,3,100,4,108,2,109,3,125, - 4,1,0,122,18,124,4,124,0,106,4,160,5,124,3,161, - 1,131,1,87,0,83,0,4,0,116,6,121,84,1,0,1, - 0,1,0,116,7,124,3,131,1,130,1,89,0,110,2,48, - 0,100,0,83,0,41,5,78,114,85,0,0,0,114,109,0, - 0,0,114,0,0,0,0,41,1,218,7,66,121,116,101,115, - 73,79,41,8,114,38,0,0,0,114,19,0,0,0,90,2, - 105,111,114,176,0,0,0,114,4,0,0,0,114,55,0,0, - 0,114,22,0,0,0,218,17,70,105,108,101,78,111,116,70, - 111,117,110,100,69,114,114,111,114,41,5,114,32,0,0,0, - 218,8,114,101,115,111,117,114,99,101,218,16,102,117,108,108, - 110,97,109,101,95,97,115,95,112,97,116,104,114,13,0,0, - 0,114,176,0,0,0,114,9,0,0,0,114,9,0,0,0, - 114,10,0,0,0,218,13,111,112,101,110,95,114,101,115,111, - 117,114,99,101,224,2,0,0,115,14,0,0,0,0,1,14, - 1,14,1,12,1,2,1,18,1,12,1,122,38,95,90,105, - 112,73,109,112,111,114,116,82,101,115,111,117,114,99,101,82, - 101,97,100,101,114,46,111,112,101,110,95,114,101,115,111,117, - 114,99,101,99,2,0,0,0,0,0,0,0,0,0,0,0, - 2,0,0,0,1,0,0,0,67,0,0,0,115,8,0,0, - 0,116,0,130,1,100,0,83,0,114,88,0,0,0,41,1, - 114,177,0,0,0,41,2,114,32,0,0,0,114,178,0,0, + 111,100,101,123,2,0,0,115,72,0,0,0,2,2,2,1, + 6,254,14,5,12,2,4,1,12,1,10,1,2,1,2,255, + 8,1,2,255,10,2,8,1,4,1,4,1,2,1,4,254, + 4,5,8,1,4,255,2,128,8,4,6,255,4,3,22,3, + 18,1,2,255,4,2,8,1,4,255,4,2,18,2,10,1, + 16,1,4,1,114,161,0,0,0,99,1,0,0,0,0,0, + 0,0,0,0,0,0,1,0,0,0,4,0,0,0,67,0, + 0,0,115,28,0,0,0,124,0,160,0,100,1,100,2,161, + 2,125,0,124,0,160,0,100,3,100,2,161,2,125,0,124, + 0,83,0,41,4,78,115,2,0,0,0,13,10,243,1,0, + 0,0,10,243,1,0,0,0,13,41,1,114,19,0,0,0, + 41,1,218,6,115,111,117,114,99,101,114,9,0,0,0,114, + 9,0,0,0,114,10,0,0,0,218,23,95,110,111,114,109, + 97,108,105,122,101,95,108,105,110,101,95,101,110,100,105,110, + 103,115,168,2,0,0,115,6,0,0,0,12,1,12,1,4, + 1,114,165,0,0,0,99,2,0,0,0,0,0,0,0,0, + 0,0,0,2,0,0,0,6,0,0,0,67,0,0,0,115, + 24,0,0,0,116,0,124,1,131,1,125,1,116,1,124,1, + 124,0,100,1,100,2,100,3,141,4,83,0,41,4,78,114, + 79,0,0,0,84,41,1,90,12,100,111,110,116,95,105,110, + 104,101,114,105,116,41,2,114,165,0,0,0,218,7,99,111, + 109,112,105,108,101,41,2,114,60,0,0,0,114,164,0,0, 0,114,9,0,0,0,114,9,0,0,0,114,10,0,0,0, - 218,13,114,101,115,111,117,114,99,101,95,112,97,116,104,233, - 2,0,0,115,2,0,0,0,0,4,122,38,95,90,105,112, - 73,109,112,111,114,116,82,101,115,111,117,114,99,101,82,101, - 97,100,101,114,46,114,101,115,111,117,114,99,101,95,112,97, - 116,104,99,2,0,0,0,0,0,0,0,0,0,0,0,4, - 0,0,0,8,0,0,0,67,0,0,0,115,70,0,0,0, - 124,0,106,0,160,1,100,1,100,2,161,2,125,2,124,2, - 155,0,100,2,124,1,155,0,157,3,125,3,122,16,124,0, - 106,2,160,3,124,3,161,1,1,0,87,0,110,20,4,0, - 116,4,121,64,1,0,1,0,1,0,89,0,100,3,83,0, - 48,0,100,4,83,0,41,5,78,114,85,0,0,0,114,109, - 0,0,0,70,84,41,5,114,38,0,0,0,114,19,0,0, - 0,114,4,0,0,0,114,55,0,0,0,114,22,0,0,0, - 41,4,114,32,0,0,0,114,59,0,0,0,114,179,0,0, - 0,114,13,0,0,0,114,9,0,0,0,114,9,0,0,0, - 114,10,0,0,0,218,11,105,115,95,114,101,115,111,117,114, - 99,101,239,2,0,0,115,14,0,0,0,0,3,14,1,14, - 1,2,1,16,1,12,1,8,1,122,36,95,90,105,112,73, - 109,112,111,114,116,82,101,115,111,117,114,99,101,82,101,97, - 100,101,114,46,105,115,95,114,101,115,111,117,114,99,101,99, - 1,0,0,0,0,0,0,0,0,0,0,0,9,0,0,0, - 9,0,0,0,99,0,0,0,115,184,0,0,0,100,1,100, - 2,108,0,109,1,125,1,1,0,124,1,124,0,106,2,160, - 3,124,0,106,4,161,1,131,1,125,2,124,2,160,5,124, - 0,106,2,106,6,161,1,125,3,124,3,106,7,100,3,107, - 2,115,58,74,0,130,1,124,3,106,8,125,4,116,9,131, - 0,125,5,124,0,106,2,106,10,68,0,93,100,125,6,122, - 18,124,1,124,6,131,1,160,5,124,4,161,1,125,7,87, - 0,110,22,4,0,116,11,121,122,1,0,1,0,1,0,89, - 0,113,78,89,0,110,2,48,0,124,7,106,8,106,7,125, - 8,116,12,124,8,131,1,100,1,107,2,114,154,124,7,106, - 7,86,0,1,0,113,78,124,8,124,5,118,1,114,78,124, - 5,160,13,124,8,161,1,1,0,124,8,86,0,1,0,113, - 78,100,0,83,0,41,4,78,114,0,0,0,0,41,1,218, - 4,80,97,116,104,114,60,0,0,0,41,14,90,7,112,97, - 116,104,108,105,98,114,183,0,0,0,114,4,0,0,0,114, - 56,0,0,0,114,38,0,0,0,90,11,114,101,108,97,116, - 105,118,101,95,116,111,114,29,0,0,0,114,59,0,0,0, - 90,6,112,97,114,101,110,116,218,3,115,101,116,114,28,0, - 0,0,114,23,0,0,0,114,51,0,0,0,218,3,97,100, - 100,41,9,114,32,0,0,0,114,183,0,0,0,90,13,102, - 117,108,108,110,97,109,101,95,112,97,116,104,90,13,114,101, - 108,97,116,105,118,101,95,112,97,116,104,90,12,112,97,99, - 107,97,103,101,95,112,97,116,104,90,12,115,117,98,100,105, - 114,115,95,115,101,101,110,218,8,102,105,108,101,110,97,109, - 101,90,8,114,101,108,97,116,105,118,101,90,11,112,97,114, - 101,110,116,95,110,97,109,101,114,9,0,0,0,114,9,0, - 0,0,114,10,0,0,0,218,8,99,111,110,116,101,110,116, - 115,250,2,0,0,115,34,0,0,0,0,8,12,1,18,1, - 14,3,14,1,6,1,6,1,12,1,2,1,18,1,12,1, - 10,5,8,1,12,1,10,1,8,1,10,1,122,33,95,90, - 105,112,73,109,112,111,114,116,82,101,115,111,117,114,99,101, - 82,101,97,100,101,114,46,99,111,110,116,101,110,116,115,78, - 41,10,114,6,0,0,0,114,7,0,0,0,114,8,0,0, - 0,114,84,0,0,0,114,81,0,0,0,114,34,0,0,0, - 114,180,0,0,0,114,181,0,0,0,114,182,0,0,0,114, - 187,0,0,0,114,9,0,0,0,114,9,0,0,0,114,9, - 0,0,0,114,10,0,0,0,114,80,0,0,0,212,2,0, - 0,115,14,0,0,0,8,1,4,5,4,2,8,4,8,9, - 8,6,8,11,114,80,0,0,0,41,45,114,84,0,0,0, - 90,26,95,102,114,111,122,101,110,95,105,109,112,111,114,116, - 108,105,98,95,101,120,116,101,114,110,97,108,114,21,0,0, - 0,114,1,0,0,0,114,2,0,0,0,90,17,95,102,114, - 111,122,101,110,95,105,109,112,111,114,116,108,105,98,114,76, - 0,0,0,114,148,0,0,0,114,110,0,0,0,114,152,0, - 0,0,114,67,0,0,0,114,131,0,0,0,90,7,95,95, - 97,108,108,95,95,114,20,0,0,0,90,15,112,97,116,104, - 95,115,101,112,97,114,97,116,111,114,115,114,18,0,0,0, - 114,75,0,0,0,114,3,0,0,0,114,25,0,0,0,218, - 4,116,121,112,101,114,70,0,0,0,114,113,0,0,0,114, - 115,0,0,0,114,117,0,0,0,114,4,0,0,0,114,89, - 0,0,0,114,36,0,0,0,114,37,0,0,0,114,35,0, - 0,0,114,27,0,0,0,114,122,0,0,0,114,142,0,0, - 0,114,144,0,0,0,114,52,0,0,0,114,147,0,0,0, - 114,155,0,0,0,218,8,95,95,99,111,100,101,95,95,114, - 153,0,0,0,114,159,0,0,0,114,161,0,0,0,114,169, - 0,0,0,114,151,0,0,0,114,149,0,0,0,114,44,0, - 0,0,114,80,0,0,0,114,9,0,0,0,114,9,0,0, - 0,114,9,0,0,0,114,10,0,0,0,218,8,60,109,111, - 100,117,108,101,62,1,0,0,0,115,88,0,0,0,4,16, - 8,1,16,1,8,1,8,1,8,1,8,1,8,1,8,2, - 8,3,6,1,14,3,16,4,4,2,8,2,4,1,4,1, - 4,2,14,127,0,127,0,1,12,1,12,1,2,1,2,252, - 4,9,8,4,8,9,8,31,8,126,2,254,2,29,4,5, - 8,21,8,46,8,10,8,46,10,5,8,7,8,6,8,13, - 8,19,8,15,8,26, + 218,15,95,99,111,109,112,105,108,101,95,115,111,117,114,99, + 101,175,2,0,0,115,4,0,0,0,8,1,16,1,114,167, + 0,0,0,99,2,0,0,0,0,0,0,0,0,0,0,0, + 2,0,0,0,11,0,0,0,67,0,0,0,115,68,0,0, + 0,116,0,160,1,124,0,100,1,63,0,100,2,23,0,124, + 0,100,3,63,0,100,4,64,0,124,0,100,5,64,0,124, + 1,100,6,63,0,124,1,100,3,63,0,100,7,64,0,124, + 1,100,5,64,0,100,8,20,0,100,9,100,9,100,9,102, + 9,161,1,83,0,41,10,78,233,9,0,0,0,105,188,7, + 0,0,233,5,0,0,0,233,15,0,0,0,233,31,0,0, + 0,233,11,0,0,0,233,63,0,0,0,114,93,0,0,0, + 114,14,0,0,0,41,2,114,137,0,0,0,90,6,109,107, + 116,105,109,101,41,2,218,1,100,114,144,0,0,0,114,9, + 0,0,0,114,9,0,0,0,114,10,0,0,0,218,14,95, + 112,97,114,115,101,95,100,111,115,116,105,109,101,181,2,0, + 0,115,18,0,0,0,4,1,10,1,10,1,6,1,6,1, + 10,1,10,1,6,1,6,249,114,175,0,0,0,99,2,0, + 0,0,0,0,0,0,0,0,0,0,6,0,0,0,10,0, + 0,0,67,0,0,0,115,110,0,0,0,122,41,124,1,100, + 1,100,0,133,2,25,0,100,2,118,0,115,11,74,0,130, + 1,124,1,100,0,100,1,133,2,25,0,125,1,124,0,106, + 0,124,1,25,0,125,2,124,2,100,3,25,0,125,3,124, + 2,100,4,25,0,125,4,124,2,100,5,25,0,125,5,116, + 1,124,4,124,3,131,2,124,5,102,2,87,0,83,0,4, + 0,116,2,116,3,116,4,102,3,121,54,1,0,1,0,1, + 0,89,0,100,6,83,0,119,0,41,7,78,114,14,0,0, + 0,169,2,218,1,99,218,1,111,114,169,0,0,0,233,6, + 0,0,0,233,3,0,0,0,41,2,114,0,0,0,0,114, + 0,0,0,0,41,5,114,28,0,0,0,114,175,0,0,0, + 114,26,0,0,0,218,10,73,110,100,101,120,69,114,114,111, + 114,114,160,0,0,0,41,6,114,32,0,0,0,114,13,0, + 0,0,114,61,0,0,0,114,137,0,0,0,114,138,0,0, + 0,90,17,117,110,99,111,109,112,114,101,115,115,101,100,95, + 115,105,122,101,114,9,0,0,0,114,9,0,0,0,114,10, + 0,0,0,114,157,0,0,0,194,2,0,0,115,22,0,0, + 0,2,1,20,2,12,1,10,1,8,3,8,1,8,1,16, + 1,18,1,6,1,2,255,114,157,0,0,0,99,2,0,0, + 0,0,0,0,0,0,0,0,0,3,0,0,0,8,0,0, + 0,67,0,0,0,115,80,0,0,0,124,1,100,1,100,0, + 133,2,25,0,100,2,118,0,115,10,74,0,130,1,124,1, + 100,0,100,1,133,2,25,0,125,1,122,7,124,0,106,0, + 124,1,25,0,125,2,87,0,110,10,4,0,116,1,121,33, + 1,0,1,0,1,0,89,0,100,0,83,0,119,0,116,2, + 124,0,106,3,124,2,131,2,83,0,41,3,78,114,14,0, + 0,0,114,176,0,0,0,41,4,114,28,0,0,0,114,26, + 0,0,0,114,59,0,0,0,114,29,0,0,0,41,3,114, + 32,0,0,0,114,13,0,0,0,114,61,0,0,0,114,9, + 0,0,0,114,9,0,0,0,114,10,0,0,0,114,155,0, + 0,0,213,2,0,0,115,16,0,0,0,20,2,12,1,2, + 2,14,1,12,1,6,1,2,255,12,3,114,155,0,0,0, + 99,2,0,0,0,0,0,0,0,0,0,0,0,14,0,0, + 0,11,0,0,0,67,0,0,0,115,14,1,0,0,116,0, + 124,0,124,1,131,2,125,2,100,0,125,3,116,1,68,0, + 93,102,92,3,125,4,125,5,125,6,124,2,124,4,23,0, + 125,7,116,2,106,3,100,1,124,0,106,4,116,5,124,7, + 100,2,100,3,141,5,1,0,122,7,124,0,106,6,124,7, + 25,0,125,8,87,0,110,9,4,0,116,7,121,45,1,0, + 1,0,1,0,89,0,113,9,119,0,124,8,100,4,25,0, + 125,9,116,8,124,0,106,4,124,8,131,2,125,10,100,0, + 125,11,124,5,114,91,122,10,116,9,124,0,124,9,124,7, + 124,1,124,10,131,5,125,11,87,0,110,25,4,0,116,10, + 121,90,1,0,125,12,1,0,122,8,124,12,125,3,87,0, + 89,0,100,0,125,12,126,12,110,10,100,0,125,12,126,12, + 119,1,119,0,116,11,124,9,124,10,131,2,125,11,124,11, + 100,0,117,0,114,101,113,9,124,8,100,4,25,0,125,9, + 124,11,124,6,124,9,102,3,2,0,1,0,83,0,124,3, + 114,126,100,5,124,3,155,0,157,2,125,13,116,12,124,13, + 124,1,100,6,141,2,124,3,130,2,116,12,100,7,124,1, + 155,2,157,2,124,1,100,6,141,2,130,1,41,8,78,122, + 13,116,114,121,105,110,103,32,123,125,123,125,123,125,114,93, + 0,0,0,41,1,90,9,118,101,114,98,111,115,105,116,121, + 114,0,0,0,0,122,20,109,111,100,117,108,101,32,108,111, + 97,100,32,102,97,105,108,101,100,58,32,114,65,0,0,0, + 114,64,0,0,0,41,13,114,39,0,0,0,114,95,0,0, + 0,114,48,0,0,0,114,81,0,0,0,114,29,0,0,0, + 114,20,0,0,0,114,28,0,0,0,114,26,0,0,0,114, + 59,0,0,0,114,161,0,0,0,114,80,0,0,0,114,167, + 0,0,0,114,3,0,0,0,41,14,114,32,0,0,0,114, + 41,0,0,0,114,13,0,0,0,90,12,105,109,112,111,114, + 116,95,101,114,114,111,114,114,96,0,0,0,114,97,0,0, + 0,114,54,0,0,0,114,69,0,0,0,114,61,0,0,0, + 114,43,0,0,0,114,132,0,0,0,114,53,0,0,0,90, + 3,101,120,99,114,82,0,0,0,114,9,0,0,0,114,9, + 0,0,0,114,10,0,0,0,114,51,0,0,0,228,2,0, + 0,115,58,0,0,0,10,1,4,1,14,1,8,1,22,1, + 2,1,14,1,12,1,4,1,2,255,8,3,12,1,4,1, + 4,1,2,1,20,1,14,1,16,1,8,128,2,255,10,3, + 8,1,2,3,8,1,14,1,4,2,10,1,14,1,18,2, + 114,51,0,0,0,41,46,114,91,0,0,0,90,26,95,102, + 114,111,122,101,110,95,105,109,112,111,114,116,108,105,98,95, + 101,120,116,101,114,110,97,108,114,21,0,0,0,114,1,0, + 0,0,114,2,0,0,0,90,17,95,102,114,111,122,101,110, + 95,105,109,112,111,114,116,108,105,98,114,48,0,0,0,114, + 154,0,0,0,114,116,0,0,0,114,158,0,0,0,114,72, + 0,0,0,114,137,0,0,0,114,35,0,0,0,90,7,95, + 95,97,108,108,95,95,114,20,0,0,0,90,15,112,97,116, + 104,95,115,101,112,97,114,97,116,111,114,115,114,18,0,0, + 0,114,80,0,0,0,114,3,0,0,0,114,25,0,0,0, + 218,4,116,121,112,101,114,75,0,0,0,114,119,0,0,0, + 114,121,0,0,0,114,123,0,0,0,90,13,95,76,111,97, + 100,101,114,66,97,115,105,99,115,114,4,0,0,0,114,95, + 0,0,0,114,39,0,0,0,114,40,0,0,0,114,38,0, + 0,0,114,27,0,0,0,114,128,0,0,0,114,148,0,0, + 0,114,150,0,0,0,114,59,0,0,0,114,153,0,0,0, + 114,161,0,0,0,218,8,95,95,99,111,100,101,95,95,114, + 159,0,0,0,114,165,0,0,0,114,167,0,0,0,114,175, + 0,0,0,114,157,0,0,0,114,155,0,0,0,114,51,0, + 0,0,114,9,0,0,0,114,9,0,0,0,114,9,0,0, + 0,114,10,0,0,0,218,8,60,109,111,100,117,108,101,62, + 1,0,0,0,115,90,0,0,0,4,0,8,16,16,1,8, + 1,8,1,8,1,8,1,8,1,8,1,8,1,8,2,6, + 3,14,1,16,3,4,4,8,2,4,2,4,1,4,1,18, + 2,0,127,0,127,12,50,12,1,2,1,2,1,4,252,8, + 9,8,4,8,9,8,31,2,126,2,254,4,29,8,5,8, + 21,8,46,8,8,10,40,8,5,8,7,8,6,8,13,8, + 19,12,15, }; diff --git a/contrib/tools/python3/src/Python/initconfig.c b/contrib/tools/python3/src/Python/initconfig.c index 9c109cef2c1..86472c0ff8f 100644 --- a/contrib/tools/python3/src/Python/initconfig.c +++ b/contrib/tools/python3/src/Python/initconfig.c @@ -11,11 +11,7 @@ #include "osdefs.h" // DELIM #include <locale.h> // setlocale() -#ifdef HAVE_LANGINFO_H -# include <langinfo.h> // nl_langinfo(CODESET) -#endif #if defined(MS_WINDOWS) || defined(__CYGWIN__) -# include <windows.h> // GetACP() # ifdef HAVE_IO_H # include <io.h> # endif @@ -73,7 +69,6 @@ static const char usage_3[] = "\ -X opt : set implementation-specific option. The following options are available:\n\ \n\ -X faulthandler: enable faulthandler\n\ - -X oldparser: enable the traditional LL(1) parser; also PYTHONOLDPARSER\n\ -X showrefcount: output the total reference count and number of used\n\ memory blocks when the program finishes or after each statement in the\n\ interactive interpreter. This only works on debug builds\n\ @@ -99,6 +94,7 @@ static const char usage_3[] = "\ otherwise activate automatically)\n\ -X pycache_prefix=PATH: enable writing .pyc files to a parallel tree rooted at the\n\ given directory instead of to the code tree\n\ + -X warn_default_encoding: enable opt-in EncodingWarning for 'encoding=None'\n\ \n\ --check-hash-based-pycs always|default|never:\n\ control how Python invalidates hash-based .pyc files\n\ @@ -134,7 +130,8 @@ static const char usage_6[] = "PYTHONBREAKPOINT: if this variable is set to 0, it disables the default\n" " debugger. It can be set to the callable of your debugger of choice.\n" "PYTHONDEVMODE: enable the development mode.\n" -"PYTHONPYCACHEPREFIX: root directory for bytecode cache (pyc) files.\n"; +"PYTHONPYCACHEPREFIX: root directory for bytecode cache (pyc) files.\n" +"PYTHONWARNDEFAULTENCODING: enable opt-in EncodingWarning for 'encoding=None'.\n"; #if defined(MS_WINDOWS) # define PYTHONHOMEHELP "<prefix>\\python{major}{minor}" @@ -248,8 +245,9 @@ PyStatus PyStatus_Ok(void) PyStatus PyStatus_Error(const char *err_msg) { + assert(err_msg != NULL); return (PyStatus){._type = _PyStatus_TYPE_ERROR, - .err_msg = err_msg}; + .err_msg = err_msg}; } PyStatus PyStatus_NoMemory(void) @@ -268,6 +266,23 @@ int PyStatus_IsExit(PyStatus status) int PyStatus_Exception(PyStatus status) { return _PyStatus_EXCEPTION(status); } +PyObject* +_PyErr_SetFromPyStatus(PyStatus status) +{ + if (!_PyStatus_IS_ERROR(status)) { + PyErr_Format(PyExc_SystemError, + "%s() expects an error PyStatus", + _PyStatus_GET_FUNC()); + } + else if (status.func) { + PyErr_Format(PyExc_ValueError, "%s: %s", status.func, status.err_msg); + } + else { + PyErr_Format(PyExc_ValueError, "%s", status.err_msg); + } + return NULL; +} + /* --- PyWideStringList ------------------------------------------------ */ @@ -549,6 +564,7 @@ _Py_SetArgcArgv(Py_ssize_t argc, wchar_t * const *argv) } +// _PyConfig_Write() calls _Py_SetArgcArgv() with PyConfig.orig_argv. void Py_GetArgcArgv(int *argc, wchar_t ***argv) { @@ -570,6 +586,66 @@ Py_InitArgcArgv(int argc, wchar_t **argv) ? _PyStatus_ERR("cannot decode " NAME) \ : _PyStatus_NO_MEMORY()) +#define MAX_HASH_SEED 4294967295UL + + +#ifndef NDEBUG +static int +config_check_consistency(const PyConfig *config) +{ + /* Check config consistency */ + assert(config->isolated >= 0); + assert(config->use_environment >= 0); + assert(config->dev_mode >= 0); + assert(config->install_signal_handlers >= 0); + assert(config->use_hash_seed >= 0); + assert(config->hash_seed <= MAX_HASH_SEED); + assert(config->faulthandler >= 0); + assert(config->tracemalloc >= 0); + assert(config->import_time >= 0); + assert(config->show_ref_count >= 0); + assert(config->dump_refs >= 0); + assert(config->malloc_stats >= 0); + assert(config->site_import >= 0); + assert(config->bytes_warning >= 0); + assert(config->warn_default_encoding >= 0); + assert(config->inspect >= 0); + assert(config->interactive >= 0); + assert(config->optimization_level >= 0); + assert(config->parser_debug >= 0); + assert(config->write_bytecode >= 0); + assert(config->verbose >= 0); + assert(config->quiet >= 0); + assert(config->user_site_directory >= 0); + assert(config->parse_argv >= 0); + assert(config->configure_c_stdio >= 0); + assert(config->buffered_stdio >= 0); + assert(config->program_name != NULL); + assert(_PyWideStringList_CheckConsistency(&config->orig_argv)); + assert(_PyWideStringList_CheckConsistency(&config->argv)); + /* sys.argv must be non-empty: empty argv is replaced with [''] */ + assert(config->argv.length >= 1); + assert(_PyWideStringList_CheckConsistency(&config->xoptions)); + assert(_PyWideStringList_CheckConsistency(&config->warnoptions)); + assert(_PyWideStringList_CheckConsistency(&config->module_search_paths)); + assert(config->module_search_paths_set >= 0); + assert(config->platlibdir != NULL); + assert(config->filesystem_encoding != NULL); + assert(config->filesystem_errors != NULL); + assert(config->stdio_encoding != NULL); + assert(config->stdio_errors != NULL); +#ifdef MS_WINDOWS + assert(config->legacy_windows_stdio >= 0); +#endif + /* -c and -m options are exclusive */ + assert(!(config->run_command != NULL && config->run_module != NULL)); + assert(config->check_hash_pycs_mode != NULL); + assert(config->_install_importlib >= 0); + assert(config->pathconfig_warnings >= 0); + return 1; +} +#endif + /* Free memory allocated in config, but don't clear all attributes */ void @@ -609,7 +685,7 @@ PyConfig_Clear(PyConfig *config) CLEAR(config->run_filename); CLEAR(config->check_hash_pycs_mode); - _PyWideStringList_Clear(&config->_orig_argv); + _PyWideStringList_Clear(&config->orig_argv); #undef CLEAR } @@ -631,6 +707,7 @@ _PyConfig_InitCompatConfig(PyConfig *config) config->parse_argv = 0; config->site_import = -1; config->bytes_warning = -1; + config->warn_default_encoding = 0; config->inspect = -1; config->interactive = -1; config->optimization_level = -1; @@ -649,7 +726,6 @@ _PyConfig_InitCompatConfig(PyConfig *config) #ifdef MS_WINDOWS config->legacy_windows_stdio = -1; #endif - config->_use_peg_parser = 1; } @@ -775,7 +851,7 @@ config_set_bytes_string(PyConfig *config, wchar_t **config_str, configured. */ PyStatus PyConfig_SetBytesString(PyConfig *config, wchar_t **config_str, - const char *str) + const char *str) { return CONFIG_SET_BYTES_STR(config, config_str, str, "string"); } @@ -807,7 +883,6 @@ _PyConfig_Copy(PyConfig *config, const PyConfig *config2) COPY_ATTR(isolated); COPY_ATTR(use_environment); COPY_ATTR(dev_mode); - COPY_ATTR(_use_peg_parser); COPY_ATTR(install_signal_handlers); COPY_ATTR(use_hash_seed); COPY_ATTR(hash_seed); @@ -841,6 +916,7 @@ _PyConfig_Copy(PyConfig *config, const PyConfig *config2) COPY_ATTR(site_import); COPY_ATTR(bytes_warning); + COPY_ATTR(warn_default_encoding); COPY_ATTR(inspect); COPY_ATTR(interactive); COPY_ATTR(optimization_level); @@ -866,7 +942,7 @@ _PyConfig_Copy(PyConfig *config, const PyConfig *config2) COPY_ATTR(pathconfig_warnings); COPY_ATTR(_init_main); COPY_ATTR(_isolated_interpreter); - COPY_WSTRLIST(_orig_argv); + COPY_WSTRLIST(orig_argv); #undef COPY_ATTR #undef COPY_WSTR_ATTR @@ -875,12 +951,10 @@ _PyConfig_Copy(PyConfig *config, const PyConfig *config2) } -static PyObject * -config_as_dict(const PyConfig *config) +PyObject * +_PyConfig_AsDict(const PyConfig *config) { - PyObject *dict; - - dict = PyDict_New(); + PyObject *dict = PyDict_New(); if (dict == NULL) { return NULL; } @@ -914,7 +988,6 @@ config_as_dict(const PyConfig *config) SET_ITEM_INT(isolated); SET_ITEM_INT(use_environment); SET_ITEM_INT(dev_mode); - SET_ITEM_INT(_use_peg_parser); SET_ITEM_INT(install_signal_handlers); SET_ITEM_INT(use_hash_seed); SET_ITEM_UINT(hash_seed); @@ -934,6 +1007,7 @@ config_as_dict(const PyConfig *config) SET_ITEM_WSTRLIST(warnoptions); SET_ITEM_WSTR(pythonpath_env); SET_ITEM_WSTR(home); + SET_ITEM_INT(module_search_paths_set); SET_ITEM_WSTRLIST(module_search_paths); SET_ITEM_WSTR(executable); SET_ITEM_WSTR(base_executable); @@ -944,6 +1018,7 @@ config_as_dict(const PyConfig *config) SET_ITEM_WSTR(platlibdir); SET_ITEM_INT(site_import); SET_ITEM_INT(bytes_warning); + SET_ITEM_INT(warn_default_encoding); SET_ITEM_INT(inspect); SET_ITEM_INT(interactive); SET_ITEM_INT(optimization_level); @@ -968,7 +1043,7 @@ config_as_dict(const PyConfig *config) SET_ITEM_INT(pathconfig_warnings); SET_ITEM_INT(_init_main); SET_ITEM_INT(_isolated_interpreter); - SET_ITEM_WSTRLIST(_orig_argv); + SET_ITEM_WSTRLIST(orig_argv); return dict; @@ -985,6 +1060,280 @@ fail: } +static PyObject* +config_dict_get(PyObject *dict, const char *name) +{ + PyObject *item = _PyDict_GetItemStringWithError(dict, name); + if (item == NULL && !PyErr_Occurred()) { + PyErr_Format(PyExc_ValueError, "missing config key: %s", name); + return NULL; + } + return item; +} + + +static void +config_dict_invalid_value(const char *name) +{ + PyErr_Format(PyExc_ValueError, "invalid config value: %s", name); +} + + +static void +config_dict_invalid_type(const char *name) +{ + PyErr_Format(PyExc_TypeError, "invalid config type: %s", name); +} + + +static int +config_dict_get_int(PyObject *dict, const char *name, int *result) +{ + PyObject *item = config_dict_get(dict, name); + if (item == NULL) { + return -1; + } + int value = _PyLong_AsInt(item); + if (value == -1 && PyErr_Occurred()) { + if (PyErr_ExceptionMatches(PyExc_TypeError)) { + config_dict_invalid_type(name); + } + else if (PyErr_ExceptionMatches(PyExc_OverflowError)) { + config_dict_invalid_value(name); + } + return -1; + } + *result = value; + return 0; +} + + +static int +config_dict_get_ulong(PyObject *dict, const char *name, unsigned long *result) +{ + PyObject *item = config_dict_get(dict, name); + if (item == NULL) { + return -1; + } + unsigned long value = PyLong_AsUnsignedLong(item); + if (value == (unsigned long)-1 && PyErr_Occurred()) { + if (PyErr_ExceptionMatches(PyExc_TypeError)) { + config_dict_invalid_type(name); + } + else if (PyErr_ExceptionMatches(PyExc_OverflowError)) { + config_dict_invalid_value(name); + } + return -1; + } + *result = value; + return 0; +} + + +static int +config_dict_get_wstr(PyObject *dict, const char *name, PyConfig *config, + wchar_t **result) +{ + PyObject *item = config_dict_get(dict, name); + if (item == NULL) { + return -1; + } + PyStatus status; + if (item == Py_None) { + status = PyConfig_SetString(config, result, NULL); + } + else if (!PyUnicode_Check(item)) { + config_dict_invalid_type(name); + return -1; + } + else { + wchar_t *wstr = PyUnicode_AsWideCharString(item, NULL); + if (wstr == NULL) { + return -1; + } + status = PyConfig_SetString(config, result, wstr); + PyMem_Free(wstr); + } + if (_PyStatus_EXCEPTION(status)) { + PyErr_NoMemory(); + return -1; + } + return 0; +} + + +static int +config_dict_get_wstrlist(PyObject *dict, const char *name, PyConfig *config, + PyWideStringList *result) +{ + PyObject *list = config_dict_get(dict, name); + if (list == NULL) { + return -1; + } + + if (!PyList_CheckExact(list)) { + config_dict_invalid_type(name); + return -1; + } + + PyWideStringList wstrlist = _PyWideStringList_INIT; + for (Py_ssize_t i=0; i < PyList_GET_SIZE(list); i++) { + PyObject *item = PyList_GET_ITEM(list, i); + + if (item == Py_None) { + config_dict_invalid_value(name); + goto error; + } + else if (!PyUnicode_Check(item)) { + config_dict_invalid_type(name); + goto error; + } + wchar_t *wstr = PyUnicode_AsWideCharString(item, NULL); + if (wstr == NULL) { + goto error; + } + PyStatus status = PyWideStringList_Append(&wstrlist, wstr); + PyMem_Free(wstr); + if (_PyStatus_EXCEPTION(status)) { + PyErr_NoMemory(); + goto error; + } + } + + if (_PyWideStringList_Copy(result, &wstrlist) < 0) { + PyErr_NoMemory(); + goto error; + } + _PyWideStringList_Clear(&wstrlist); + return 0; + +error: + _PyWideStringList_Clear(&wstrlist); + return -1; +} + + +int +_PyConfig_FromDict(PyConfig *config, PyObject *dict) +{ + if (!PyDict_Check(dict)) { + PyErr_SetString(PyExc_TypeError, "dict expected"); + return -1; + } + +#define CHECK_VALUE(NAME, TEST) \ + if (!(TEST)) { \ + config_dict_invalid_value(NAME); \ + return -1; \ + } +#define GET_UINT(KEY) \ + do { \ + if (config_dict_get_int(dict, #KEY, &config->KEY) < 0) { \ + return -1; \ + } \ + CHECK_VALUE(#KEY, config->KEY >= 0); \ + } while (0) +#define GET_WSTR(KEY) \ + do { \ + if (config_dict_get_wstr(dict, #KEY, config, &config->KEY) < 0) { \ + return -1; \ + } \ + CHECK_VALUE(#KEY, config->KEY != NULL); \ + } while (0) +#define GET_WSTR_OPT(KEY) \ + do { \ + if (config_dict_get_wstr(dict, #KEY, config, &config->KEY) < 0) { \ + return -1; \ + } \ + } while (0) +#define GET_WSTRLIST(KEY) \ + do { \ + if (config_dict_get_wstrlist(dict, #KEY, config, &config->KEY) < 0) { \ + return -1; \ + } \ + } while (0) + + GET_UINT(_config_init); + CHECK_VALUE("_config_init", + config->_config_init == _PyConfig_INIT_COMPAT + || config->_config_init == _PyConfig_INIT_PYTHON + || config->_config_init == _PyConfig_INIT_ISOLATED); + GET_UINT(isolated); + GET_UINT(use_environment); + GET_UINT(dev_mode); + GET_UINT(install_signal_handlers); + GET_UINT(use_hash_seed); + if (config_dict_get_ulong(dict, "hash_seed", &config->hash_seed) < 0) { + return -1; + } + CHECK_VALUE("hash_seed", config->hash_seed <= MAX_HASH_SEED); + GET_UINT(faulthandler); + GET_UINT(tracemalloc); + GET_UINT(import_time); + GET_UINT(show_ref_count); + GET_UINT(dump_refs); + GET_UINT(malloc_stats); + GET_WSTR(filesystem_encoding); + GET_WSTR(filesystem_errors); + GET_WSTR_OPT(pycache_prefix); + GET_UINT(parse_argv); + GET_WSTRLIST(orig_argv); + GET_WSTRLIST(argv); + GET_WSTRLIST(xoptions); + GET_WSTRLIST(warnoptions); + GET_UINT(site_import); + GET_UINT(bytes_warning); + GET_UINT(warn_default_encoding); + GET_UINT(inspect); + GET_UINT(interactive); + GET_UINT(optimization_level); + GET_UINT(parser_debug); + GET_UINT(write_bytecode); + GET_UINT(verbose); + GET_UINT(quiet); + GET_UINT(user_site_directory); + GET_UINT(configure_c_stdio); + GET_UINT(buffered_stdio); + GET_WSTR(stdio_encoding); + GET_WSTR(stdio_errors); +#ifdef MS_WINDOWS + GET_UINT(legacy_windows_stdio); +#endif + GET_WSTR(check_hash_pycs_mode); + + GET_UINT(pathconfig_warnings); + GET_WSTR(program_name); + GET_WSTR_OPT(pythonpath_env); + GET_WSTR_OPT(home); + GET_WSTR(platlibdir); + + // Path configuration output + GET_UINT(module_search_paths_set); + GET_WSTRLIST(module_search_paths); + GET_WSTR_OPT(executable); + GET_WSTR_OPT(base_executable); + GET_WSTR_OPT(prefix); + GET_WSTR_OPT(base_prefix); + GET_WSTR_OPT(exec_prefix); + GET_WSTR_OPT(base_exec_prefix); + + GET_UINT(skip_source_first_line); + GET_WSTR_OPT(run_command); + GET_WSTR_OPT(run_module); + GET_WSTR_OPT(run_filename); + + GET_UINT(_install_importlib); + GET_UINT(_init_main); + GET_UINT(_isolated_interpreter); + +#undef CHECK_VALUE +#undef GET_UINT +#undef GET_WSTR +#undef GET_WSTR_OPT + return 0; +} + + static const char* config_get_env(const PyConfig *config, const char *name) { @@ -1252,7 +1601,6 @@ config_init_home(PyConfig *config) L"PYTHONHOME", "PYTHONHOME"); } - static PyStatus config_init_hash_seed(PyConfig *config) { @@ -1266,7 +1614,7 @@ config_init_hash_seed(PyConfig *config) errno = 0; seed = strtoul(seed_text, (char **)&endptr, 10); if (*endptr != '\0' - || seed > 4294967295UL + || seed > MAX_HASH_SEED || (errno == ERANGE && seed == ULONG_MAX)) { return _PyStatus_ERR("PYTHONHASHSEED must be \"random\" " @@ -1335,7 +1683,7 @@ config_read_env_vars(PyConfig *config) #ifdef MS_WINDOWS _Py_get_env_flag(use_env, &config->legacy_windows_stdio, - "PYTHONLEGACYWINDOWSSTDIO"); + "PYTHONLEGACYWINDOWSSTDIO"); #endif if (config_get_env(config, "PYTHONDUMPREFS")) { @@ -1460,11 +1808,6 @@ config_read_complex_options(PyConfig *config) config->import_time = 1; } - if (config_get_env(config, "PYTHONOLDPARSER") - || config_get_xoption(config, L"oldparser")) { - config->_use_peg_parser = 0; - } - PyStatus status; if (config->tracemalloc < 0) { status = config_init_tracemalloc(config); @@ -1484,8 +1827,13 @@ config_read_complex_options(PyConfig *config) static const wchar_t * -config_get_stdio_errors(void) +config_get_stdio_errors(const PyPreConfig *preconfig) { + if (preconfig->utf8_mode) { + /* UTF-8 Mode uses UTF-8/surrogateescape */ + return L"surrogateescape"; + } + #ifndef MS_WINDOWS const char *loc = setlocale(LC_CTYPE, NULL); if (loc != NULL) { @@ -1510,26 +1858,18 @@ config_get_stdio_errors(void) } +// See also config_get_fs_encoding() static PyStatus -config_get_locale_encoding(PyConfig *config, wchar_t **locale_encoding) +config_get_locale_encoding(PyConfig *config, const PyPreConfig *preconfig, + wchar_t **locale_encoding) { -#ifdef MS_WINDOWS - char encoding[20]; - PyOS_snprintf(encoding, sizeof(encoding), "cp%u", GetACP()); - return PyConfig_SetBytesString(config, locale_encoding, encoding); -#elif defined(_Py_FORCE_UTF8_LOCALE) - return PyConfig_SetString(config, locale_encoding, L"utf-8"); -#else - const char *encoding = nl_langinfo(CODESET); - if (!encoding || encoding[0] == '\0') { - return _PyStatus_ERR("failed to get the locale encoding: " - "nl_langinfo(CODESET) failed"); - } - /* nl_langinfo(CODESET) is decoded by Py_DecodeLocale() */ - return CONFIG_SET_BYTES_STR(config, - locale_encoding, encoding, - "nl_langinfo(CODESET)"); -#endif + wchar_t *encoding = _Py_GetLocaleEncoding(); + if (encoding == NULL) { + return _PyStatus_NO_MEMORY(); + } + PyStatus status = PyConfig_SetString(config, locale_encoding, encoding); + PyMem_RawFree(encoding); + return status; } @@ -1539,8 +1879,8 @@ config_init_stdio_encoding(PyConfig *config, { PyStatus status; - /* If Py_SetStandardStreamEncoding() have been called, use these - parameters. */ + /* If Py_SetStandardStreamEncoding() has been called, use its + arguments if they are not NULL. */ if (config->stdio_encoding == NULL && _Py_StandardStreamEncoding != NULL) { status = CONFIG_SET_BYTES_STR(config, &config->stdio_encoding, _Py_StandardStreamEncoding, @@ -1559,6 +1899,7 @@ config_init_stdio_encoding(PyConfig *config, } } + // Exit if encoding and errors are defined if (config->stdio_encoding != NULL && config->stdio_errors != NULL) { return _PyStatus_OK(); } @@ -1614,33 +1955,16 @@ config_init_stdio_encoding(PyConfig *config, PyMem_RawFree(pythonioencoding); } - /* UTF-8 Mode uses UTF-8/surrogateescape */ - if (preconfig->utf8_mode) { - if (config->stdio_encoding == NULL) { - status = PyConfig_SetString(config, &config->stdio_encoding, - L"utf-8"); - if (_PyStatus_EXCEPTION(status)) { - return status; - } - } - if (config->stdio_errors == NULL) { - status = PyConfig_SetString(config, &config->stdio_errors, - L"surrogateescape"); - if (_PyStatus_EXCEPTION(status)) { - return status; - } - } - } - /* Choose the default error handler based on the current locale. */ if (config->stdio_encoding == NULL) { - status = config_get_locale_encoding(config, &config->stdio_encoding); + status = config_get_locale_encoding(config, preconfig, + &config->stdio_encoding); if (_PyStatus_EXCEPTION(status)) { return status; } } if (config->stdio_errors == NULL) { - const wchar_t *errors = config_get_stdio_errors(); + const wchar_t *errors = config_get_stdio_errors(preconfig); assert(errors != NULL); status = PyConfig_SetString(config, &config->stdio_errors, errors); @@ -1653,46 +1977,46 @@ config_init_stdio_encoding(PyConfig *config, } +// See also config_get_locale_encoding() +static PyStatus +config_get_fs_encoding(PyConfig *config, const PyPreConfig *preconfig, + wchar_t **fs_encoding) +{ +#ifdef _Py_FORCE_UTF8_FS_ENCODING + return PyConfig_SetString(config, fs_encoding, L"utf-8"); +#elif defined(MS_WINDOWS) + const wchar_t *encoding; + if (preconfig->legacy_windows_fs_encoding) { + // Legacy Windows filesystem encoding: mbcs/replace + encoding = L"mbcs"; + } + else { + // Windows defaults to utf-8/surrogatepass (PEP 529) + encoding = L"utf-8"; + } + return PyConfig_SetString(config, fs_encoding, encoding); +#else // !MS_WINDOWS + if (preconfig->utf8_mode) { + return PyConfig_SetString(config, fs_encoding, L"utf-8"); + } + + if (_Py_GetForceASCII()) { + return PyConfig_SetString(config, fs_encoding, L"ascii"); + } + + return config_get_locale_encoding(config, preconfig, fs_encoding); +#endif // !MS_WINDOWS +} + + static PyStatus config_init_fs_encoding(PyConfig *config, const PyPreConfig *preconfig) { PyStatus status; if (config->filesystem_encoding == NULL) { -#ifdef _Py_FORCE_UTF8_FS_ENCODING - status = PyConfig_SetString(config, &config->filesystem_encoding, L"utf-8"); -#else - -#ifdef MS_WINDOWS - if (preconfig->legacy_windows_fs_encoding) { - /* Legacy Windows filesystem encoding: mbcs/replace */ - status = PyConfig_SetString(config, &config->filesystem_encoding, - L"mbcs"); - } - else -#endif - if (preconfig->utf8_mode) { - status = PyConfig_SetString(config, &config->filesystem_encoding, - L"utf-8"); - } -#ifndef MS_WINDOWS - else if (_Py_GetForceASCII()) { - status = PyConfig_SetString(config, &config->filesystem_encoding, - L"ascii"); - } -#endif - else { -#ifdef MS_WINDOWS - /* Windows defaults to utf-8/surrogatepass (PEP 529). */ - status = PyConfig_SetString(config, &config->filesystem_encoding, - L"utf-8"); -#else - status = config_get_locale_encoding(config, - &config->filesystem_encoding); -#endif - } -#endif /* !_Py_FORCE_UTF8_FS_ENCODING */ - + status = config_get_fs_encoding(config, preconfig, + &config->filesystem_encoding); if (_PyStatus_EXCEPTION(status)) { return status; } @@ -1720,7 +2044,7 @@ config_init_fs_encoding(PyConfig *config, const PyPreConfig *preconfig) static PyStatus -config_read(PyConfig *config) +config_read(PyConfig *config, int compute_path_config) { PyStatus status; const PyPreConfig *preconfig = &_PyRuntime.preconfig; @@ -1765,7 +2089,7 @@ config_read(PyConfig *config) } if (config->_install_importlib) { - status = _PyConfig_InitPathConfig(config); + status = _PyConfig_InitPathConfig(config, compute_path_config); if (_PyStatus_EXCEPTION(status)) { return status; } @@ -1820,6 +2144,11 @@ config_read(PyConfig *config) config->configure_c_stdio = 1; } + // Only parse arguments once. + if (config->parse_argv == 1) { + config->parse_argv = 2; + } + return _PyStatus_OK(); } @@ -1880,8 +2209,8 @@ _PyConfig_Write(const PyConfig *config, _PyRuntimeState *runtime) preconfig->use_environment = config->use_environment; preconfig->dev_mode = config->dev_mode; - if (_Py_SetArgcArgv(config->_orig_argv.length, - config->_orig_argv.items) < 0) + if (_Py_SetArgcArgv(config->orig_argv.length, + config->orig_argv.items) < 0) { return _PyStatus_NO_MEMORY(); } @@ -2310,7 +2639,7 @@ core_read_precmdline(PyConfig *config, _PyPreCmdline *precmdline) { PyStatus status; - if (config->parse_argv) { + if (config->parse_argv == 1) { if (_PyWideStringList_Copy(&precmdline->argv, &config->argv) < 0) { return _PyStatus_NO_MEMORY(); } @@ -2388,7 +2717,7 @@ config_read_cmdline(PyConfig *config) } } - if (config->parse_argv) { + if (config->parse_argv == 1) { Py_ssize_t opt_index; status = config_parse_cmdline(config, &cmdline_warnoptions, &opt_index); if (_PyStatus_EXCEPTION(status)) { @@ -2506,7 +2835,7 @@ PyConfig_SetWideStringList(PyConfig *config, PyWideStringList *list, The only side effects are to modify config and to call _Py_SetArgcArgv(). */ PyStatus -PyConfig_Read(PyConfig *config) +_PyConfig_Read(PyConfig *config, int compute_path_config) { PyStatus status; @@ -2517,11 +2846,11 @@ PyConfig_Read(PyConfig *config) config_get_global_vars(config); - if (config->_orig_argv.length == 0 + if (config->orig_argv.length == 0 && !(config->argv.length == 1 && wcscmp(config->argv.items[0], L"") == 0)) { - if (_PyWideStringList_Copy(&config->_orig_argv, &config->argv) < 0) { + if (_PyWideStringList_Copy(&config->orig_argv, &config->argv) < 0) { return _PyStatus_NO_MEMORY(); } } @@ -2549,64 +2878,12 @@ PyConfig_Read(PyConfig *config) goto done; } - status = config_read(config); + status = config_read(config, compute_path_config); if (_PyStatus_EXCEPTION(status)) { goto done; } - /* Check config consistency */ - assert(config->isolated >= 0); - assert(config->use_environment >= 0); - assert(config->dev_mode >= 0); - assert(config->_use_peg_parser >= 0); - assert(config->install_signal_handlers >= 0); - assert(config->use_hash_seed >= 0); - assert(config->faulthandler >= 0); - assert(config->tracemalloc >= 0); - assert(config->site_import >= 0); - assert(config->bytes_warning >= 0); - assert(config->inspect >= 0); - assert(config->interactive >= 0); - assert(config->optimization_level >= 0); - assert(config->parser_debug >= 0); - assert(config->write_bytecode >= 0); - assert(config->verbose >= 0); - assert(config->quiet >= 0); - assert(config->user_site_directory >= 0); - assert(config->parse_argv >= 0); - assert(config->configure_c_stdio >= 0); - assert(config->buffered_stdio >= 0); - assert(config->program_name != NULL); - assert(_PyWideStringList_CheckConsistency(&config->argv)); - /* sys.argv must be non-empty: empty argv is replaced with [''] */ - assert(config->argv.length >= 1); - assert(_PyWideStringList_CheckConsistency(&config->xoptions)); - assert(_PyWideStringList_CheckConsistency(&config->warnoptions)); - assert(_PyWideStringList_CheckConsistency(&config->module_search_paths)); - if (config->_install_importlib) { - assert(config->module_search_paths_set != 0); - /* don't check config->module_search_paths */ - assert(config->executable != NULL); - assert(config->base_executable != NULL); - assert(config->prefix != NULL); - assert(config->base_prefix != NULL); - assert(config->exec_prefix != NULL); - assert(config->base_exec_prefix != NULL); - } - assert(config->platlibdir != NULL); - assert(config->filesystem_encoding != NULL); - assert(config->filesystem_errors != NULL); - assert(config->stdio_encoding != NULL); - assert(config->stdio_errors != NULL); -#ifdef MS_WINDOWS - assert(config->legacy_windows_stdio >= 0); -#endif - /* -c and -m options are exclusive */ - assert(!(config->run_command != NULL && config->run_module != NULL)); - assert(config->check_hash_pycs_mode != NULL); - assert(config->_install_importlib >= 0); - assert(config->pathconfig_warnings >= 0); - assert(_PyWideStringList_CheckConsistency(&config->_orig_argv)); + assert(config_check_consistency(config)); status = _PyStatus_OK(); @@ -2616,6 +2893,13 @@ done: } +PyStatus +PyConfig_Read(PyConfig *config) +{ + return _PyConfig_Read(config, 1); +} + + PyObject* _Py_GetConfigsAsDict(void) { @@ -2638,8 +2922,8 @@ _Py_GetConfigsAsDict(void) Py_CLEAR(dict); /* pre config */ - PyThreadState *tstate = _PyThreadState_GET(); - const PyPreConfig *pre_config = &tstate->interp->runtime->preconfig; + PyInterpreterState *interp = _PyInterpreterState_GET(); + const PyPreConfig *pre_config = &interp->runtime->preconfig; dict = _PyPreConfig_AsDict(pre_config); if (dict == NULL) { goto error; @@ -2650,8 +2934,8 @@ _Py_GetConfigsAsDict(void) Py_CLEAR(dict); /* core config */ - const PyConfig *config = _PyInterpreterState_GetConfig(tstate->interp); - dict = config_as_dict(config); + const PyConfig *config = _PyInterpreterState_GetConfig(interp); + dict = _PyConfig_AsDict(config); if (dict == NULL) { goto error; } @@ -2660,6 +2944,16 @@ _Py_GetConfigsAsDict(void) } Py_CLEAR(dict); + /* path config */ + dict = _PyPathConfig_AsDict(); + if (dict == NULL) { + goto error; + } + if (PyDict_SetItemString(result, "path_config", dict) < 0) { + goto error; + } + Py_CLEAR(dict); + return result; error: diff --git a/contrib/tools/python3/src/Python/marshal.c b/contrib/tools/python3/src/Python/marshal.c index baafa3ecfbf..41252406060 100644 --- a/contrib/tools/python3/src/Python/marshal.c +++ b/contrib/tools/python3/src/Python/marshal.c @@ -524,7 +524,7 @@ w_complex_object(PyObject *v, char flag, WFILE *p) w_object(co->co_filename, p); w_object(co->co_name, p); w_long(co->co_firstlineno, p); - w_object(co->co_lnotab, p); + w_object(co->co_linetable, p); } else if (PyObject_CheckBuffer(v)) { /* Write unknown bytes-like objects as a bytes object */ @@ -642,7 +642,7 @@ r_string(Py_ssize_t n, RFILE *p) return res; } if (p->buf == NULL) { - p->buf = PyMem_MALLOC(n); + p->buf = PyMem_Malloc(n); if (p->buf == NULL) { PyErr_NoMemory(); return NULL; @@ -650,7 +650,7 @@ r_string(Py_ssize_t n, RFILE *p) p->buf_size = n; } else if (p->buf_size < n) { - char *tmp = PyMem_REALLOC(p->buf, n); + char *tmp = PyMem_Realloc(p->buf, n); if (tmp == NULL) { PyErr_NoMemory(); return NULL; @@ -1316,7 +1316,7 @@ r_object(RFILE *p) PyObject *filename = NULL; PyObject *name = NULL; int firstlineno; - PyObject *lnotab = NULL; + PyObject *linetable = NULL; idx = r_ref_reserve(flag, p); if (idx < 0) @@ -1371,8 +1371,8 @@ r_object(RFILE *p) firstlineno = (int)r_long(p); if (firstlineno == -1 && PyErr_Occurred()) break; - lnotab = r_object(p); - if (lnotab == NULL) + linetable = r_object(p); + if (linetable == NULL) goto code_error; v = (PyObject *) PyCode_NewWithPosOnlyArgs( @@ -1380,7 +1380,7 @@ r_object(RFILE *p) nlocals, stacksize, flags, code, consts, names, varnames, freevars, cellvars, filename, name, - firstlineno, lnotab); + firstlineno, linetable); v = r_ref_insert(v, idx, flag, p); code_error: @@ -1392,7 +1392,7 @@ r_object(RFILE *p) Py_XDECREF(cellvars); Py_XDECREF(filename); Py_XDECREF(name); - Py_XDECREF(lnotab); + Py_XDECREF(linetable); } retval = v; break; @@ -1460,7 +1460,7 @@ PyMarshal_ReadShortFromFile(FILE *fp) rf.buf = NULL; res = r_short(&rf); if (rf.buf != NULL) - PyMem_FREE(rf.buf); + PyMem_Free(rf.buf); return res; } @@ -1475,7 +1475,7 @@ PyMarshal_ReadLongFromFile(FILE *fp) rf.buf = NULL; res = r_long(&rf); if (rf.buf != NULL) - PyMem_FREE(rf.buf); + PyMem_Free(rf.buf); return res; } @@ -1508,11 +1508,11 @@ PyMarshal_ReadLastObjectFromFile(FILE *fp) off_t filesize; filesize = getfilesize(fp); if (filesize > 0 && filesize <= REASONABLE_FILE_LIMIT) { - char* pBuf = (char *)PyMem_MALLOC(filesize); + char* pBuf = (char *)PyMem_Malloc(filesize); if (pBuf != NULL) { size_t n = fread(pBuf, 1, (size_t)filesize, fp); PyObject* v = PyMarshal_ReadObjectFromString(pBuf, n); - PyMem_FREE(pBuf); + PyMem_Free(pBuf); return v; } @@ -1541,7 +1541,7 @@ PyMarshal_ReadObjectFromFile(FILE *fp) result = read_object(&rf); Py_DECREF(rf.refs); if (rf.buf != NULL) - PyMem_FREE(rf.buf); + PyMem_Free(rf.buf); return result; } @@ -1562,7 +1562,7 @@ PyMarshal_ReadObjectFromString(const char *str, Py_ssize_t len) result = read_object(&rf); Py_DECREF(rf.refs); if (rf.buf != NULL) - PyMem_FREE(rf.buf); + PyMem_Free(rf.buf); return result; } @@ -1694,7 +1694,7 @@ marshal_load(PyObject *module, PyObject *file) result = read_object(&rf); Py_DECREF(rf.refs); if (rf.buf != NULL) - PyMem_FREE(rf.buf); + PyMem_Free(rf.buf); } else result = NULL; } @@ -1795,28 +1795,30 @@ dumps() -- marshal value as a bytes object\n\ loads() -- read value from a bytes-like object"); +static int +marshal_module_exec(PyObject *mod) +{ + if (PyModule_AddIntConstant(mod, "version", Py_MARSHAL_VERSION) < 0) { + return -1; + } + return 0; +} + +static PyModuleDef_Slot marshalmodule_slots[] = { + {Py_mod_exec, marshal_module_exec}, + {0, NULL} +}; static struct PyModuleDef marshalmodule = { PyModuleDef_HEAD_INIT, - "marshal", - module_doc, - 0, - marshal_methods, - NULL, - NULL, - NULL, - NULL + .m_name = "marshal", + .m_doc = module_doc, + .m_methods = marshal_methods, + .m_slots = marshalmodule_slots, }; PyMODINIT_FUNC PyMarshal_Init(void) { - PyObject *mod = PyModule_Create(&marshalmodule); - if (mod == NULL) - return NULL; - if (PyModule_AddIntConstant(mod, "version", Py_MARSHAL_VERSION) < 0) { - Py_DECREF(mod); - return NULL; - } - return mod; + return PyModuleDef_Init(&marshalmodule); } diff --git a/contrib/tools/python3/src/Python/modsupport.c b/contrib/tools/python3/src/Python/modsupport.c index 13482c65083..8655daa1fc5 100644 --- a/contrib/tools/python3/src/Python/modsupport.c +++ b/contrib/tools/python3/src/Python/modsupport.c @@ -283,6 +283,13 @@ do_mktuple(const char **p_format, va_list *p_va, char endchar, Py_ssize_t n, int static PyObject * do_mkvalue(const char **p_format, va_list *p_va, int flags) { +#define ERROR_NEED_PY_SSIZE_T_CLEAN \ + { \ + PyErr_SetString(PyExc_SystemError, \ + "PY_SSIZE_T_CLEAN macro must be defined for '#' formats"); \ + return NULL; \ + } + for (;;) { switch (*(*p_format)++) { case '(': @@ -341,14 +348,12 @@ do_mkvalue(const char **p_format, va_list *p_va, int flags) Py_ssize_t n; if (**p_format == '#') { ++*p_format; - if (flags & FLAG_SIZE_T) + if (flags & FLAG_SIZE_T) { n = va_arg(*p_va, Py_ssize_t); + } else { n = va_arg(*p_va, int); - if (PyErr_WarnEx(PyExc_DeprecationWarning, - "PY_SSIZE_T_CLEAN will be required for '#' formats", 1)) { - return NULL; - } + ERROR_NEED_PY_SSIZE_T_CLEAN; } } else @@ -394,14 +399,12 @@ do_mkvalue(const char **p_format, va_list *p_va, int flags) Py_ssize_t n; if (**p_format == '#') { ++*p_format; - if (flags & FLAG_SIZE_T) + if (flags & FLAG_SIZE_T) { n = va_arg(*p_va, Py_ssize_t); + } else { n = va_arg(*p_va, int); - if (PyErr_WarnEx(PyExc_DeprecationWarning, - "PY_SSIZE_T_CLEAN will be required for '#' formats", 1)) { - return NULL; - } + ERROR_NEED_PY_SSIZE_T_CLEAN; } } else @@ -432,14 +435,12 @@ do_mkvalue(const char **p_format, va_list *p_va, int flags) Py_ssize_t n; if (**p_format == '#') { ++*p_format; - if (flags & FLAG_SIZE_T) + if (flags & FLAG_SIZE_T) { n = va_arg(*p_va, Py_ssize_t); + } else { n = va_arg(*p_va, int); - if (PyErr_WarnEx(PyExc_DeprecationWarning, - "PY_SSIZE_T_CLEAN will be required for '#' formats", 1)) { - return NULL; - } + ERROR_NEED_PY_SSIZE_T_CLEAN; } } else @@ -507,6 +508,8 @@ do_mkvalue(const char **p_format, va_list *p_va, int flags) } } + +#undef ERROR_NEED_PY_SSIZE_T_CLEAN } @@ -631,56 +634,70 @@ va_build_stack(PyObject **small_stack, Py_ssize_t small_stack_len, int -PyModule_AddObject(PyObject *m, const char *name, PyObject *o) +PyModule_AddObjectRef(PyObject *mod, const char *name, PyObject *value) { - PyObject *dict; - if (!PyModule_Check(m)) { + if (!PyModule_Check(mod)) { PyErr_SetString(PyExc_TypeError, - "PyModule_AddObject() needs module as first arg"); + "PyModule_AddObjectRef() first argument " + "must be a module"); return -1; } - if (!o) { - if (!PyErr_Occurred()) - PyErr_SetString(PyExc_TypeError, - "PyModule_AddObject() needs non-NULL value"); + if (!value) { + if (!PyErr_Occurred()) { + PyErr_SetString(PyExc_SystemError, + "PyModule_AddObjectRef() must be called " + "with an exception raised if value is NULL"); + } return -1; } - dict = PyModule_GetDict(m); + PyObject *dict = PyModule_GetDict(mod); if (dict == NULL) { /* Internal error -- modules must have a dict! */ PyErr_Format(PyExc_SystemError, "module '%s' has no __dict__", - PyModule_GetName(m)); + PyModule_GetName(mod)); return -1; } - if (PyDict_SetItemString(dict, name, o)) + + if (PyDict_SetItemString(dict, name, value)) { return -1; - Py_DECREF(o); + } return 0; } + +int +PyModule_AddObject(PyObject *mod, const char *name, PyObject *value) +{ + int res = PyModule_AddObjectRef(mod, name, value); + if (res == 0) { + Py_DECREF(value); + } + return res; +} + int PyModule_AddIntConstant(PyObject *m, const char *name, long value) { - PyObject *o = PyLong_FromLong(value); - if (!o) + PyObject *obj = PyLong_FromLong(value); + if (!obj) { return -1; - if (PyModule_AddObject(m, name, o) == 0) - return 0; - Py_DECREF(o); - return -1; + } + int res = PyModule_AddObjectRef(m, name, obj); + Py_DECREF(obj); + return res; } int PyModule_AddStringConstant(PyObject *m, const char *name, const char *value) { - PyObject *o = PyUnicode_FromString(value); - if (!o) + PyObject *obj = PyUnicode_FromString(value); + if (!obj) { return -1; - if (PyModule_AddObject(m, name, o) == 0) - return 0; - Py_DECREF(o); - return -1; + } + int res = PyModule_AddObjectRef(m, name, obj); + Py_DECREF(obj); + return res; } int @@ -693,11 +710,5 @@ PyModule_AddType(PyObject *module, PyTypeObject *type) const char *name = _PyType_Name(type); assert(name != NULL); - Py_INCREF(type); - if (PyModule_AddObject(module, name, (PyObject *)type) < 0) { - Py_DECREF(type); - return -1; - } - - return 0; + return PyModule_AddObjectRef(module, name, (PyObject *)type); } diff --git a/contrib/tools/python3/src/Python/mysnprintf.c b/contrib/tools/python3/src/Python/mysnprintf.c index 458ca14d5c6..cd69198011e 100644 --- a/contrib/tools/python3/src/Python/mysnprintf.c +++ b/contrib/tools/python3/src/Python/mysnprintf.c @@ -15,10 +15,6 @@ PyOS_snprintf and PyOS_vsnprintf never write more than size bytes (including the trailing '\0') into str. - If the platform doesn't have vsnprintf, and the buffer size needed to - avoid truncation exceeds size by more than 512, Python aborts with a - Py_FatalError. - Return value (rv): When 0 <= rv < size, the output conversion was unexceptional, and @@ -37,6 +33,7 @@ PyMem_Malloc couldn't obtain space for a temp buffer. CAUTION: Unlike C99, str != NULL and size > 0 are required. + Also, size must be smaller than INT_MAX. */ int @@ -56,50 +53,22 @@ PyOS_vsnprintf(char *str, size_t size, const char *format, va_list va) { assert(str != NULL); assert(size > 0); + assert(size <= (INT_MAX - 1)); assert(format != NULL); int len; /* # bytes written, excluding \0 */ -#if defined(_MSC_VER) || defined(HAVE_SNPRINTF) -# define _PyOS_vsnprintf_EXTRA_SPACE 1 -#else -# define _PyOS_vsnprintf_EXTRA_SPACE 512 - char *buffer; -#endif /* We take a size_t as input but return an int. Sanity check * our input so that it won't cause an overflow in the - * vsnprintf return value or the buffer malloc size. */ - if (size > INT_MAX - _PyOS_vsnprintf_EXTRA_SPACE) { + * vsnprintf return value. */ + if (size > INT_MAX - 1) { len = -666; goto Done; } #if defined(_MSC_VER) len = _vsnprintf(str, size, format, va); -#elif defined(HAVE_SNPRINTF) - len = vsnprintf(str, size, format, va); #else - /* Emulate vsnprintf(). */ - buffer = PyMem_MALLOC(size + _PyOS_vsnprintf_EXTRA_SPACE); - if (buffer == NULL) { - len = -666; - goto Done; - } - - len = vsprintf(buffer, format, va); - if (len < 0) { - /* ignore the error */; - } - else if ((size_t)len >= size + _PyOS_vsnprintf_EXTRA_SPACE) { - _Py_FatalErrorFunc(__func__, "Buffer overflow"); - } - else { - const size_t to_copy = (size_t)len < size ? - (size_t)len : size - 1; - assert(to_copy < size); - memcpy(str, buffer, to_copy); - str[to_copy] = '\0'; - } - PyMem_FREE(buffer); + len = vsnprintf(str, size, format, va); #endif Done: @@ -107,5 +76,4 @@ Done: str[size-1] = '\0'; } return len; -#undef _PyOS_vsnprintf_EXTRA_SPACE } diff --git a/contrib/tools/python3/src/Python/opcode_targets.h b/contrib/tools/python3/src/Python/opcode_targets.h index 538fdbe3e0b..951f8f8a556 100644 --- a/contrib/tools/python3/src/Python/opcode_targets.h +++ b/contrib/tools/python3/src/Python/opcode_targets.h @@ -29,6 +29,11 @@ static void *opcode_targets[256] = { &&TARGET_BINARY_TRUE_DIVIDE, &&TARGET_INPLACE_FLOOR_DIVIDE, &&TARGET_INPLACE_TRUE_DIVIDE, + &&TARGET_GET_LEN, + &&TARGET_MATCH_MAPPING, + &&TARGET_MATCH_SEQUENCE, + &&TARGET_MATCH_KEYS, + &&TARGET_COPY_DICT_WITHOUT_KEYS, &&_unknown_opcode, &&_unknown_opcode, &&_unknown_opcode, @@ -43,11 +48,6 @@ static void *opcode_targets[256] = { &&_unknown_opcode, &&_unknown_opcode, &&_unknown_opcode, - &&_unknown_opcode, - &&_unknown_opcode, - &&_unknown_opcode, - &&_unknown_opcode, - &&TARGET_RERAISE, &&TARGET_WITH_EXCEPT_START, &&TARGET_GET_AITER, &&TARGET_GET_ANEXT, @@ -98,7 +98,7 @@ static void *opcode_targets[256] = { &&TARGET_DELETE_ATTR, &&TARGET_STORE_GLOBAL, &&TARGET_DELETE_GLOBAL, - &&_unknown_opcode, + &&TARGET_ROT_N, &&TARGET_LOAD_CONST, &&TARGET_LOAD_NAME, &&TARGET_BUILD_TUPLE, @@ -118,7 +118,7 @@ static void *opcode_targets[256] = { &&TARGET_LOAD_GLOBAL, &&TARGET_IS_OP, &&TARGET_CONTAINS_OP, - &&_unknown_opcode, + &&TARGET_RERAISE, &&_unknown_opcode, &&TARGET_JUMP_IF_NOT_EXC_MATCH, &&TARGET_SETUP_FINALLY, @@ -128,7 +128,7 @@ static void *opcode_targets[256] = { &&TARGET_DELETE_FAST, &&_unknown_opcode, &&_unknown_opcode, - &&_unknown_opcode, + &&TARGET_GEN_START, &&TARGET_RAISE_VARARGS, &&TARGET_CALL_FUNCTION, &&TARGET_MAKE_FUNCTION, @@ -151,7 +151,7 @@ static void *opcode_targets[256] = { &&_unknown_opcode, &&_unknown_opcode, &&_unknown_opcode, - &&_unknown_opcode, + &&TARGET_MATCH_CLASS, &&_unknown_opcode, &&TARGET_SETUP_ASYNC_WITH, &&TARGET_FORMAT_VALUE, diff --git a/contrib/tools/python3/src/Python/pathconfig.c b/contrib/tools/python3/src/Python/pathconfig.c index b2ce86e64ce..1017a571f2b 100644 --- a/contrib/tools/python3/src/Python/pathconfig.c +++ b/contrib/tools/python3/src/Python/pathconfig.c @@ -186,6 +186,80 @@ done: return status; } +PyObject * +_PyPathConfig_AsDict(void) +{ + PyObject *dict = PyDict_New(); + if (dict == NULL) { + return NULL; + } + +#define SET_ITEM(KEY, EXPR) \ + do { \ + PyObject *obj = (EXPR); \ + if (obj == NULL) { \ + goto fail; \ + } \ + int res = PyDict_SetItemString(dict, KEY, obj); \ + Py_DECREF(obj); \ + if (res < 0) { \ + goto fail; \ + } \ + } while (0) +#define SET_ITEM_STR(KEY) \ + SET_ITEM(#KEY, \ + (_Py_path_config.KEY \ + ? PyUnicode_FromWideChar(_Py_path_config.KEY, -1) \ + : (Py_INCREF(Py_None), Py_None))) +#define SET_ITEM_INT(KEY) \ + SET_ITEM(#KEY, PyLong_FromLong(_Py_path_config.KEY)) + + SET_ITEM_STR(program_full_path); + SET_ITEM_STR(prefix); + SET_ITEM_STR(exec_prefix); + SET_ITEM_STR(module_search_path); + SET_ITEM_STR(program_name); + SET_ITEM_STR(home); +#ifdef MS_WINDOWS + SET_ITEM_INT(isolated); + SET_ITEM_INT(site_import); + SET_ITEM_STR(base_executable); + + { + wchar_t py3path[MAX_PATH]; + HMODULE hPython3 = GetModuleHandleW(PY3_DLLNAME); + PyObject *obj; + if (hPython3 + && GetModuleFileNameW(hPython3, py3path, Py_ARRAY_LENGTH(py3path))) + { + obj = PyUnicode_FromWideChar(py3path, -1); + if (obj == NULL) { + goto fail; + } + } + else { + obj = Py_None; + Py_INCREF(obj); + } + if (PyDict_SetItemString(dict, "python3_dll", obj) < 0) { + Py_DECREF(obj); + goto fail; + } + Py_DECREF(obj); + } +#endif + +#undef SET_ITEM +#undef SET_ITEM_STR +#undef SET_ITEM_INT + + return dict; + +fail: + Py_DECREF(dict); + return NULL; +} + PyStatus _PyConfig_WritePathConfig(const PyConfig *config) @@ -258,7 +332,8 @@ config_init_module_search_paths(PyConfig *config, _PyPathConfig *pathconfig) - _PyPathConfig_Calculate() */ static PyStatus -pathconfig_calculate(_PyPathConfig *pathconfig, const PyConfig *config) +pathconfig_init(_PyPathConfig *pathconfig, const PyConfig *config, + int compute_path_config) { PyStatus status; @@ -275,12 +350,9 @@ pathconfig_calculate(_PyPathConfig *pathconfig, const PyConfig *config) goto done; } - if (_Py_path_config.module_search_path == NULL) { + if (compute_path_config) { status = _PyPathConfig_Calculate(pathconfig, config); } - else { - /* Py_SetPath() has been called: avoid _PyPathConfig_Calculate() */ - } done: PyMem_SetAllocator(PYMEM_DOMAIN_RAW, &old_alloc); @@ -289,17 +361,19 @@ done: static PyStatus -config_calculate_pathconfig(PyConfig *config) +config_init_pathconfig(PyConfig *config, int compute_path_config) { _PyPathConfig pathconfig = _PyPathConfig_INIT; PyStatus status; - status = pathconfig_calculate(&pathconfig, config); + status = pathconfig_init(&pathconfig, config, compute_path_config); if (_PyStatus_EXCEPTION(status)) { goto done; } - if (!config->module_search_paths_set) { + if (!config->module_search_paths_set + && pathconfig.module_search_path != NULL) + { status = config_init_module_search_paths(config, &pathconfig); if (_PyStatus_EXCEPTION(status)) { goto done; @@ -307,7 +381,7 @@ config_calculate_pathconfig(PyConfig *config) } #define COPY_ATTR(PATH_ATTR, CONFIG_ATTR) \ - if (config->CONFIG_ATTR == NULL) { \ + if (config->CONFIG_ATTR == NULL && pathconfig.PATH_ATTR != NULL) { \ if (copy_wstr(&config->CONFIG_ATTR, pathconfig.PATH_ATTR) < 0) { \ goto no_memory; \ } \ @@ -353,7 +427,7 @@ done: PyStatus -_PyConfig_InitPathConfig(PyConfig *config) +_PyConfig_InitPathConfig(PyConfig *config, int compute_path_config) { /* Do we need to calculate the path? */ if (!config->module_search_paths_set @@ -361,26 +435,26 @@ _PyConfig_InitPathConfig(PyConfig *config) || config->prefix == NULL || config->exec_prefix == NULL) { - PyStatus status = config_calculate_pathconfig(config); + PyStatus status = config_init_pathconfig(config, compute_path_config); if (_PyStatus_EXCEPTION(status)) { return status; } } - if (config->base_prefix == NULL) { + if (config->base_prefix == NULL && config->prefix != NULL) { if (copy_wstr(&config->base_prefix, config->prefix) < 0) { return _PyStatus_NO_MEMORY(); } } - if (config->base_exec_prefix == NULL) { + if (config->base_exec_prefix == NULL && config->exec_prefix != NULL) { if (copy_wstr(&config->base_exec_prefix, config->exec_prefix) < 0) { return _PyStatus_NO_MEMORY(); } } - if (config->base_executable == NULL) { + if (config->base_executable == NULL && config->executable != NULL) { if (copy_wstr(&config->base_executable, config->executable) < 0) { return _PyStatus_NO_MEMORY(); @@ -391,53 +465,6 @@ _PyConfig_InitPathConfig(PyConfig *config) } -static PyStatus -pathconfig_global_read(_PyPathConfig *pathconfig) -{ - PyConfig config; - _PyConfig_InitCompatConfig(&config); - - /* Call _PyConfig_InitPathConfig() */ - PyStatus status = PyConfig_Read(&config); - if (_PyStatus_EXCEPTION(status)) { - goto done; - } - - status = pathconfig_set_from_config(pathconfig, &config); - -done: - PyConfig_Clear(&config); - return status; -} - - -static void -pathconfig_global_init(void) -{ - PyStatus status; - - if (_Py_path_config.module_search_path == NULL) { - status = pathconfig_global_read(&_Py_path_config); - if (_PyStatus_EXCEPTION(status)) { - Py_ExitStatusException(status); - } - } - else { - /* Global configuration already initialized */ - } - - assert(_Py_path_config.program_full_path != NULL); - assert(_Py_path_config.prefix != NULL); - assert(_Py_path_config.exec_prefix != NULL); - assert(_Py_path_config.module_search_path != NULL); - assert(_Py_path_config.program_name != NULL); - /* home can be NULL */ -#ifdef MS_WINDOWS - assert(_Py_path_config.base_executable != NULL); -#endif -} - - /* External interface */ static void _Py_NO_RETURN @@ -457,23 +484,17 @@ Py_SetPath(const wchar_t *path) PyMemAllocatorEx old_alloc; _PyMem_SetDefaultAllocator(PYMEM_DOMAIN_RAW, &old_alloc); - /* Getting the program full path calls pathconfig_global_init() */ - wchar_t *program_full_path = _PyMem_RawWcsdup(Py_GetProgramFullPath()); - - PyMem_RawFree(_Py_path_config.program_full_path); PyMem_RawFree(_Py_path_config.prefix); PyMem_RawFree(_Py_path_config.exec_prefix); PyMem_RawFree(_Py_path_config.module_search_path); - _Py_path_config.program_full_path = program_full_path; _Py_path_config.prefix = _PyMem_RawWcsdup(L""); _Py_path_config.exec_prefix = _PyMem_RawWcsdup(L""); _Py_path_config.module_search_path = _PyMem_RawWcsdup(path); PyMem_SetAllocator(PYMEM_DOMAIN_RAW, &old_alloc); - if (_Py_path_config.program_full_path == NULL - || _Py_path_config.prefix == NULL + if (_Py_path_config.prefix == NULL || _Py_path_config.exec_prefix == NULL || _Py_path_config.module_search_path == NULL) { @@ -547,7 +568,6 @@ _Py_SetProgramFullPath(const wchar_t *program_full_path) wchar_t * Py_GetPath(void) { - pathconfig_global_init(); return _Py_path_config.module_search_path; } @@ -555,7 +575,6 @@ Py_GetPath(void) wchar_t * Py_GetPrefix(void) { - pathconfig_global_init(); return _Py_path_config.prefix; } @@ -563,7 +582,6 @@ Py_GetPrefix(void) wchar_t * Py_GetExecPrefix(void) { - pathconfig_global_init(); return _Py_path_config.exec_prefix; } @@ -571,7 +589,6 @@ Py_GetExecPrefix(void) wchar_t * Py_GetProgramFullPath(void) { - pathconfig_global_init(); return _Py_path_config.program_full_path; } @@ -579,7 +596,6 @@ Py_GetProgramFullPath(void) wchar_t* Py_GetPythonHome(void) { - pathconfig_global_init(); return _Py_path_config.home; } @@ -587,7 +603,6 @@ Py_GetPythonHome(void) wchar_t * Py_GetProgramName(void) { - pathconfig_global_init(); return _Py_path_config.program_name; } diff --git a/contrib/tools/python3/src/Python/peephole.c b/contrib/tools/python3/src/Python/peephole.c deleted file mode 100644 index 6954c87b13b..00000000000 --- a/contrib/tools/python3/src/Python/peephole.c +++ /dev/null @@ -1,538 +0,0 @@ -/* Peephole optimizations for bytecode compiler. */ - -#include "Python.h" - -#include "Python-ast.h" -#include "node.h" -#include "ast.h" -#include "code.h" -#include "symtable.h" -#include "opcode.h" -#include "wordcode_helpers.h" - -#define UNCONDITIONAL_JUMP(op) (op==JUMP_ABSOLUTE || op==JUMP_FORWARD) -#define CONDITIONAL_JUMP(op) (op==POP_JUMP_IF_FALSE || op==POP_JUMP_IF_TRUE \ - || op==JUMP_IF_FALSE_OR_POP || op==JUMP_IF_TRUE_OR_POP) -#define ABSOLUTE_JUMP(op) (op==JUMP_ABSOLUTE \ - || op==POP_JUMP_IF_FALSE || op==POP_JUMP_IF_TRUE \ - || op==JUMP_IF_FALSE_OR_POP || op==JUMP_IF_TRUE_OR_POP || op==JUMP_IF_NOT_EXC_MATCH) -#define JUMPS_ON_TRUE(op) (op==POP_JUMP_IF_TRUE || op==JUMP_IF_TRUE_OR_POP) -#define GETJUMPTGT(arr, i) (get_arg(arr, i) / sizeof(_Py_CODEUNIT) + \ - (ABSOLUTE_JUMP(_Py_OPCODE(arr[i])) ? 0 : i+1)) -#define ISBASICBLOCK(blocks, start, end) \ - (blocks[start]==blocks[end]) - - -/* Scans back N consecutive LOAD_CONST instructions, skipping NOPs, - returns index of the Nth last's LOAD_CONST's EXTENDED_ARG prefix. - Callers are responsible to check CONST_STACK_LEN beforehand. -*/ -static Py_ssize_t -lastn_const_start(const _Py_CODEUNIT *codestr, Py_ssize_t i, Py_ssize_t n) -{ - assert(n > 0); - for (;;) { - i--; - assert(i >= 0); - if (_Py_OPCODE(codestr[i]) == LOAD_CONST) { - if (!--n) { - while (i > 0 && _Py_OPCODE(codestr[i-1]) == EXTENDED_ARG) { - i--; - } - return i; - } - } - else { - assert(_Py_OPCODE(codestr[i]) == EXTENDED_ARG); - } - } -} - -/* Scans through EXTENDED ARGs, seeking the index of the effective opcode */ -static Py_ssize_t -find_op(const _Py_CODEUNIT *codestr, Py_ssize_t codelen, Py_ssize_t i) -{ - while (i < codelen && _Py_OPCODE(codestr[i]) == EXTENDED_ARG) { - i++; - } - return i; -} - -/* Given the index of the effective opcode, - scan back to construct the oparg with EXTENDED_ARG */ -static unsigned int -get_arg(const _Py_CODEUNIT *codestr, Py_ssize_t i) -{ - _Py_CODEUNIT word; - unsigned int oparg = _Py_OPARG(codestr[i]); - if (i >= 1 && _Py_OPCODE(word = codestr[i-1]) == EXTENDED_ARG) { - oparg |= _Py_OPARG(word) << 8; - if (i >= 2 && _Py_OPCODE(word = codestr[i-2]) == EXTENDED_ARG) { - oparg |= _Py_OPARG(word) << 16; - if (i >= 3 && _Py_OPCODE(word = codestr[i-3]) == EXTENDED_ARG) { - oparg |= _Py_OPARG(word) << 24; - } - } - } - return oparg; -} - -/* Fill the region with NOPs. */ -static void -fill_nops(_Py_CODEUNIT *codestr, Py_ssize_t start, Py_ssize_t end) -{ - memset(codestr + start, NOP, (end - start) * sizeof(_Py_CODEUNIT)); -} - -/* Given the index of the effective opcode, - attempt to replace the argument, taking into account EXTENDED_ARG. - Returns -1 on failure, or the new op index on success */ -static Py_ssize_t -set_arg(_Py_CODEUNIT *codestr, Py_ssize_t i, unsigned int oparg) -{ - unsigned int curarg = get_arg(codestr, i); - int curilen, newilen; - if (curarg == oparg) - return i; - curilen = instrsize(curarg); - newilen = instrsize(oparg); - if (curilen < newilen) { - return -1; - } - - write_op_arg(codestr + i + 1 - curilen, _Py_OPCODE(codestr[i]), oparg, newilen); - fill_nops(codestr, i + 1 - curilen + newilen, i + 1); - return i-curilen+newilen; -} - -/* Attempt to write op/arg at end of specified region of memory. - Preceding memory in the region is overwritten with NOPs. - Returns -1 on failure, op index on success */ -static Py_ssize_t -copy_op_arg(_Py_CODEUNIT *codestr, Py_ssize_t i, unsigned char op, - unsigned int oparg, Py_ssize_t maxi) -{ - int ilen = instrsize(oparg); - if (i + ilen > maxi) { - return -1; - } - write_op_arg(codestr + maxi - ilen, op, oparg, ilen); - fill_nops(codestr, i, maxi - ilen); - return maxi - 1; -} - -/* Replace LOAD_CONST c1, LOAD_CONST c2 ... LOAD_CONST cn, BUILD_TUPLE n - with LOAD_CONST (c1, c2, ... cn). - The consts table must still be in list form so that the - new constant (c1, c2, ... cn) can be appended. - Called with codestr pointing to the first LOAD_CONST. -*/ -static Py_ssize_t -fold_tuple_on_constants(_Py_CODEUNIT *codestr, Py_ssize_t codelen, - Py_ssize_t c_start, Py_ssize_t opcode_end, - PyObject *consts, int n) -{ - /* Pre-conditions */ - assert(PyList_CheckExact(consts)); - - /* Buildup new tuple of constants */ - PyObject *newconst = PyTuple_New(n); - if (newconst == NULL) { - return -1; - } - - for (Py_ssize_t i = 0, pos = c_start; i < n; i++, pos++) { - assert(pos < opcode_end); - pos = find_op(codestr, codelen, pos); - assert(_Py_OPCODE(codestr[pos]) == LOAD_CONST); - - unsigned int arg = get_arg(codestr, pos); - PyObject *constant = PyList_GET_ITEM(consts, arg); - Py_INCREF(constant); - PyTuple_SET_ITEM(newconst, i, constant); - } - - Py_ssize_t index = PyList_GET_SIZE(consts); -#if SIZEOF_SIZE_T > SIZEOF_INT - if ((size_t)index >= UINT_MAX - 1) { - Py_DECREF(newconst); - PyErr_SetString(PyExc_OverflowError, "too many constants"); - return -1; - } -#endif - - /* Append folded constant onto consts */ - if (PyList_Append(consts, newconst)) { - Py_DECREF(newconst); - return -1; - } - Py_DECREF(newconst); - - return copy_op_arg(codestr, c_start, LOAD_CONST, - (unsigned int)index, opcode_end); -} - -static unsigned int * -markblocks(_Py_CODEUNIT *code, Py_ssize_t len) -{ - unsigned int *blocks = PyMem_New(unsigned int, len); - int i, j, opcode, blockcnt = 0; - - if (blocks == NULL) { - PyErr_NoMemory(); - return NULL; - } - memset(blocks, 0, len*sizeof(int)); - - /* Mark labels in the first pass */ - for (i = 0; i < len; i++) { - opcode = _Py_OPCODE(code[i]); - switch (opcode) { - case FOR_ITER: - case JUMP_FORWARD: - case JUMP_IF_FALSE_OR_POP: - case JUMP_IF_TRUE_OR_POP: - case POP_JUMP_IF_FALSE: - case POP_JUMP_IF_TRUE: - case JUMP_IF_NOT_EXC_MATCH: - case JUMP_ABSOLUTE: - case SETUP_FINALLY: - case SETUP_WITH: - case SETUP_ASYNC_WITH: - j = GETJUMPTGT(code, i); - assert(j < len); - blocks[j] = 1; - break; - } - } - /* Build block numbers in the second pass */ - for (i = 0; i < len; i++) { - blockcnt += blocks[i]; /* increment blockcnt over labels */ - blocks[i] = blockcnt; - } - return blocks; -} - -/* Perform basic peephole optimizations to components of a code object. - The consts object should still be in list form to allow new constants - to be appended. - - To keep the optimizer simple, it bails when the lineno table has complex - encoding for gaps >= 255. - - Optimizations are restricted to simple transformations occurring within a - single basic block. All transformations keep the code size the same or - smaller. For those that reduce size, the gaps are initially filled with - NOPs. Later those NOPs are removed and the jump addresses retargeted in - a single pass. */ - -PyObject * -PyCode_Optimize(PyObject *code, PyObject* consts, PyObject *names, - PyObject *lnotab_obj) -{ - Py_ssize_t h, i, nexti, op_start, tgt; - unsigned int j, nops; - unsigned char opcode, nextop; - _Py_CODEUNIT *codestr = NULL; - unsigned char *lnotab; - unsigned int cum_orig_offset, last_offset; - Py_ssize_t tabsiz; - // Count runs of consecutive LOAD_CONSTs - unsigned int cumlc = 0, lastlc = 0; - unsigned int *blocks = NULL; - - /* Bail out if an exception is set */ - if (PyErr_Occurred()) - goto exitError; - - /* Bypass optimization when the lnotab table is too complex */ - assert(PyBytes_Check(lnotab_obj)); - lnotab = (unsigned char*)PyBytes_AS_STRING(lnotab_obj); - tabsiz = PyBytes_GET_SIZE(lnotab_obj); - assert(tabsiz == 0 || Py_REFCNT(lnotab_obj) == 1); - - /* Don't optimize if lnotab contains instruction pointer delta larger - than +255 (encoded as multiple bytes), just to keep the peephole optimizer - simple. The optimizer leaves line number deltas unchanged. */ - - for (i = 0; i < tabsiz; i += 2) { - if (lnotab[i] == 255) { - goto exitUnchanged; - } - } - - assert(PyBytes_Check(code)); - Py_ssize_t codesize = PyBytes_GET_SIZE(code); - assert(codesize % sizeof(_Py_CODEUNIT) == 0); - Py_ssize_t codelen = codesize / sizeof(_Py_CODEUNIT); - if (codelen > INT_MAX) { - /* Python assembler is limited to INT_MAX: see assembler.a_offset in - compile.c. */ - goto exitUnchanged; - } - - /* Make a modifiable copy of the code string */ - codestr = (_Py_CODEUNIT *)PyMem_Malloc(codesize); - if (codestr == NULL) { - PyErr_NoMemory(); - goto exitError; - } - memcpy(codestr, PyBytes_AS_STRING(code), codesize); - - blocks = markblocks(codestr, codelen); - if (blocks == NULL) - goto exitError; - assert(PyList_Check(consts)); - - for (i=find_op(codestr, codelen, 0) ; i<codelen ; i=nexti) { - opcode = _Py_OPCODE(codestr[i]); - op_start = i; - while (op_start >= 1 && _Py_OPCODE(codestr[op_start-1]) == EXTENDED_ARG) { - op_start--; - } - - nexti = i + 1; - while (nexti < codelen && _Py_OPCODE(codestr[nexti]) == EXTENDED_ARG) - nexti++; - nextop = nexti < codelen ? _Py_OPCODE(codestr[nexti]) : 0; - - lastlc = cumlc; - cumlc = 0; - - switch (opcode) { - /* Skip over LOAD_CONST trueconst - POP_JUMP_IF_FALSE xx. This improves - "while 1" performance. */ - case LOAD_CONST: - cumlc = lastlc + 1; - if (nextop != POP_JUMP_IF_FALSE || - !ISBASICBLOCK(blocks, op_start, i + 1)) { - break; - } - PyObject* cnt = PyList_GET_ITEM(consts, get_arg(codestr, i)); - int is_true = PyObject_IsTrue(cnt); - if (is_true == -1) { - goto exitError; - } - if (is_true == 1) { - fill_nops(codestr, op_start, nexti + 1); - cumlc = 0; - } - break; - - /* Try to fold tuples of constants. - Skip over BUILD_SEQN 1 UNPACK_SEQN 1. - Replace BUILD_SEQN 2 UNPACK_SEQN 2 with ROT2. - Replace BUILD_SEQN 3 UNPACK_SEQN 3 with ROT3 ROT2. */ - case BUILD_TUPLE: - j = get_arg(codestr, i); - if (j > 0 && lastlc >= j) { - h = lastn_const_start(codestr, op_start, j); - if (ISBASICBLOCK(blocks, h, op_start)) { - h = fold_tuple_on_constants(codestr, codelen, - h, i+1, consts, j); - break; - } - } - if (nextop != UNPACK_SEQUENCE || - !ISBASICBLOCK(blocks, op_start, i + 1) || - j != get_arg(codestr, nexti)) - break; - if (j < 2) { - fill_nops(codestr, op_start, nexti + 1); - } else if (j == 2) { - codestr[op_start] = PACKOPARG(ROT_TWO, 0); - fill_nops(codestr, op_start + 1, nexti + 1); - } else if (j == 3) { - codestr[op_start] = PACKOPARG(ROT_THREE, 0); - codestr[op_start + 1] = PACKOPARG(ROT_TWO, 0); - fill_nops(codestr, op_start + 2, nexti + 1); - } - break; - - /* Simplify conditional jump to conditional jump where the - result of the first test implies the success of a similar - test or the failure of the opposite test. - Arises in code like: - "a and b or c" - "(a and b) and c" - "(a or b) or c" - "(a or b) and c" - x:JUMP_IF_FALSE_OR_POP y y:JUMP_IF_FALSE_OR_POP z - --> x:JUMP_IF_FALSE_OR_POP z - x:JUMP_IF_FALSE_OR_POP y y:JUMP_IF_TRUE_OR_POP z - --> x:POP_JUMP_IF_FALSE y+1 - where y+1 is the instruction following the second test. - */ - case JUMP_IF_FALSE_OR_POP: - case JUMP_IF_TRUE_OR_POP: - h = get_arg(codestr, i) / sizeof(_Py_CODEUNIT); - tgt = find_op(codestr, codelen, h); - - j = _Py_OPCODE(codestr[tgt]); - if (CONDITIONAL_JUMP(j)) { - /* NOTE: all possible jumps here are absolute. */ - if (JUMPS_ON_TRUE(j) == JUMPS_ON_TRUE(opcode)) { - /* The second jump will be taken iff the first is. - The current opcode inherits its target's - stack effect */ - h = set_arg(codestr, i, get_arg(codestr, tgt)); - } else { - /* The second jump is not taken if the first is (so - jump past it), and all conditional jumps pop their - argument when they're not taken (so change the - first jump to pop its argument when it's taken). */ - Py_ssize_t arg = (tgt + 1); - /* cannot overflow: codelen <= INT_MAX */ - assert((size_t)arg <= UINT_MAX / sizeof(_Py_CODEUNIT)); - arg *= sizeof(_Py_CODEUNIT); - h = set_arg(codestr, i, (unsigned int)arg); - j = opcode == JUMP_IF_TRUE_OR_POP ? - POP_JUMP_IF_TRUE : POP_JUMP_IF_FALSE; - } - - if (h >= 0) { - nexti = h; - codestr[nexti] = PACKOPARG(j, _Py_OPARG(codestr[nexti])); - break; - } - } - /* Intentional fallthrough */ - - /* Replace jumps to unconditional jumps */ - case POP_JUMP_IF_FALSE: - case POP_JUMP_IF_TRUE: - case JUMP_FORWARD: - case JUMP_ABSOLUTE: - h = GETJUMPTGT(codestr, i); - tgt = find_op(codestr, codelen, h); - /* Replace JUMP_* to a RETURN into just a RETURN */ - if (UNCONDITIONAL_JUMP(opcode) && - _Py_OPCODE(codestr[tgt]) == RETURN_VALUE) { - codestr[op_start] = PACKOPARG(RETURN_VALUE, 0); - fill_nops(codestr, op_start + 1, i + 1); - } else if (UNCONDITIONAL_JUMP(_Py_OPCODE(codestr[tgt]))) { - size_t arg = GETJUMPTGT(codestr, tgt); - if (opcode == JUMP_FORWARD) { /* JMP_ABS can go backwards */ - opcode = JUMP_ABSOLUTE; - } else if (!ABSOLUTE_JUMP(opcode)) { - if (arg < (size_t)(i + 1)) { - break; /* No backward relative jumps */ - } - arg -= i + 1; /* Calc relative jump addr */ - } - /* cannot overflow: codelen <= INT_MAX */ - assert(arg <= (UINT_MAX / sizeof(_Py_CODEUNIT))); - arg *= sizeof(_Py_CODEUNIT); - copy_op_arg(codestr, op_start, opcode, - (unsigned int)arg, i + 1); - } - break; - - /* Remove unreachable ops after RETURN */ - case RETURN_VALUE: - h = i + 1; - while (h < codelen && ISBASICBLOCK(blocks, i, h)) - { - /* Leave SETUP_FINALLY and RERAISE in place to help find block limits. */ - if (_Py_OPCODE(codestr[h]) == SETUP_FINALLY || _Py_OPCODE(codestr[h]) == RERAISE) { - while (h > i + 1 && - _Py_OPCODE(codestr[h - 1]) == EXTENDED_ARG) - { - h--; - } - break; - } - h++; - } - if (h > i + 1) { - fill_nops(codestr, i + 1, h); - nexti = find_op(codestr, codelen, h); - } - break; - } - } - - /* Fixup lnotab */ - for (i = 0, nops = 0; i < codelen; i++) { - size_t block = (size_t)i - nops; - /* cannot overflow: codelen <= INT_MAX */ - assert(block <= UINT_MAX); - /* original code offset => new code offset */ - blocks[i] = (unsigned int)block; - if (_Py_OPCODE(codestr[i]) == NOP) { - nops++; - } - } - cum_orig_offset = 0; - last_offset = 0; - for (i=0 ; i < tabsiz ; i+=2) { - unsigned int offset_delta, new_offset; - cum_orig_offset += lnotab[i]; - assert(cum_orig_offset % sizeof(_Py_CODEUNIT) == 0); - new_offset = blocks[cum_orig_offset / sizeof(_Py_CODEUNIT)] * - sizeof(_Py_CODEUNIT); - offset_delta = new_offset - last_offset; - assert(offset_delta <= 255); - lnotab[i] = (unsigned char)offset_delta; - last_offset = new_offset; - } - - /* Remove NOPs and fixup jump targets */ - for (op_start = i = h = 0; i < codelen; i++, op_start = i) { - j = _Py_OPARG(codestr[i]); - while (_Py_OPCODE(codestr[i]) == EXTENDED_ARG) { - i++; - j = j<<8 | _Py_OPARG(codestr[i]); - } - opcode = _Py_OPCODE(codestr[i]); - switch (opcode) { - case NOP:continue; - - case JUMP_ABSOLUTE: - case POP_JUMP_IF_FALSE: - case POP_JUMP_IF_TRUE: - case JUMP_IF_FALSE_OR_POP: - case JUMP_IF_TRUE_OR_POP: - case JUMP_IF_NOT_EXC_MATCH: - j = blocks[j / sizeof(_Py_CODEUNIT)] * sizeof(_Py_CODEUNIT); - break; - - case FOR_ITER: - case JUMP_FORWARD: - case SETUP_FINALLY: - case SETUP_WITH: - case SETUP_ASYNC_WITH: - j = blocks[j / sizeof(_Py_CODEUNIT) + i + 1] - blocks[i] - 1; - j *= sizeof(_Py_CODEUNIT); - break; - } - Py_ssize_t ilen = i - op_start + 1; - if (instrsize(j) > ilen) { - goto exitUnchanged; - } - /* If instrsize(j) < ilen, we'll emit EXTENDED_ARG 0 */ - if (ilen > 4) { - /* Can only happen when PyCode_Optimize() is called with - malformed bytecode. */ - goto exitUnchanged; - } - write_op_arg(codestr + h, opcode, j, (int)ilen); - h += ilen; - } - assert(h + (Py_ssize_t)nops == codelen); - - PyMem_Free(blocks); - code = PyBytes_FromStringAndSize((char *)codestr, h * sizeof(_Py_CODEUNIT)); - PyMem_Free(codestr); - return code; - - exitError: - code = NULL; - - exitUnchanged: - Py_XINCREF(code); - PyMem_Free(blocks); - PyMem_Free(codestr); - return code; -} diff --git a/contrib/tools/python3/src/Python/preconfig.c b/contrib/tools/python3/src/Python/preconfig.c index 262738fa57d..ae1cc3f90fc 100644 --- a/contrib/tools/python3/src/Python/preconfig.c +++ b/contrib/tools/python3/src/Python/preconfig.c @@ -19,11 +19,6 @@ preconfig_copy(PyPreConfig *config, const PyPreConfig *config2); /* --- File system encoding/errors -------------------------------- */ -/* The filesystem encoding is chosen by config_init_fs_encoding(), - see also initfsencoding(). - - Py_FileSystemDefaultEncoding and Py_FileSystemDefaultEncodeErrors - are encoded to UTF-8. */ const char *Py_FileSystemDefaultEncoding = NULL; int Py_HasFileSystemDefaultEncoding = 0; const char *Py_FileSystemDefaultEncodeErrors = NULL; @@ -44,7 +39,10 @@ _Py_ClearFileSystemEncoding(void) /* Set Py_FileSystemDefaultEncoding and Py_FileSystemDefaultEncodeErrors - global configuration variables. */ + global configuration variables to PyConfig.filesystem_encoding and + PyConfig.filesystem_errors (encoded to UTF-8). + + Function called by _PyUnicode_InitEncodings(). */ int _Py_SetFileSystemEncoding(const char *encoding, const char *errors) { @@ -171,6 +169,7 @@ _PyPreCmdline_SetConfig(const _PyPreCmdline *cmdline, PyConfig *config) COPY_ATTR(isolated); COPY_ATTR(use_environment); COPY_ATTR(dev_mode); + COPY_ATTR(warn_default_encoding); return _PyStatus_OK(); #undef COPY_ATTR @@ -259,9 +258,17 @@ _PyPreCmdline_Read(_PyPreCmdline *cmdline, const PyPreConfig *preconfig) cmdline->dev_mode = 0; } + // warn_default_encoding + if (_Py_get_xoption(&cmdline->xoptions, L"warn_default_encoding") + || _Py_GetEnv(cmdline->use_environment, "PYTHONWARNDEFAULTENCODING")) + { + cmdline->warn_default_encoding = 1; + } + assert(cmdline->use_environment >= 0); assert(cmdline->isolated >= 0); assert(cmdline->dev_mode >= 0); + assert(cmdline->warn_default_encoding >= 0); return _PyStatus_OK(); } @@ -291,7 +298,17 @@ _PyPreConfig_InitCompatConfig(PyPreConfig *config) config->coerce_c_locale_warn = 0; config->dev_mode = -1; +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + /* bpo-40512: pymalloc is not compatible with subinterpreters, + force usage of libc malloc() which is thread-safe. */ +#ifdef Py_DEBUG + config->allocator = PYMEM_ALLOCATOR_MALLOC_DEBUG; +#else + config->allocator = PYMEM_ALLOCATOR_MALLOC; +#endif +#else config->allocator = PYMEM_ALLOCATOR_NOT_SET; +#endif #ifdef MS_WINDOWS config->legacy_windows_fs_encoding = -1; #endif @@ -819,13 +836,6 @@ _PyPreConfig_Read(PyPreConfig *config, const _PyArgv *args) int init_legacy_encoding = Py_LegacyWindowsFSEncodingFlag; #endif - if (args) { - status = _PyPreCmdline_SetArgv(&cmdline, args); - if (_PyStatus_EXCEPTION(status)) { - goto done; - } - } - int locale_coerced = 0; int loops = 0; @@ -836,7 +846,7 @@ _PyPreConfig_Read(PyPreConfig *config, const _PyArgv *args) loops++; if (loops == 3) { status = _PyStatus_ERR("Encoding changed twice while " - "reading the configuration"); + "reading the configuration"); goto done; } @@ -847,6 +857,15 @@ _PyPreConfig_Read(PyPreConfig *config, const _PyArgv *args) Py_LegacyWindowsFSEncodingFlag = config->legacy_windows_fs_encoding; #endif + if (args) { + // Set command line arguments at each iteration. If they are bytes + // strings, they are decoded from the new encoding. + status = _PyPreCmdline_SetArgv(&cmdline, args); + if (_PyStatus_EXCEPTION(status)) { + goto done; + } + } + status = preconfig_read(config, &cmdline); if (_PyStatus_EXCEPTION(status)) { goto done; @@ -886,7 +905,7 @@ _PyPreConfig_Read(PyPreConfig *config, const _PyArgv *args) } /* Reset the configuration before reading again the configuration, - just keep UTF-8 Mode value. */ + just keep UTF-8 Mode and coerce C locale value. */ int new_utf8_mode = config->utf8_mode; int new_coerce_c_locale = config->coerce_c_locale; preconfig_copy(config, &save_config); diff --git a/contrib/tools/python3/src/Python/pyarena.c b/contrib/tools/python3/src/Python/pyarena.c index aefb787e554..ead03370d15 100644 --- a/contrib/tools/python3/src/Python/pyarena.c +++ b/contrib/tools/python3/src/Python/pyarena.c @@ -1,4 +1,5 @@ #include "Python.h" +#include "pycore_pyarena.h" // PyArena /* A simple arena block structure. @@ -125,7 +126,7 @@ block_alloc(block *b, size_t size) } PyArena * -PyArena_New() +_PyArena_New(void) { PyArena* arena = (PyArena *)PyMem_Malloc(sizeof(PyArena)); if (!arena) @@ -154,7 +155,7 @@ PyArena_New() } void -PyArena_Free(PyArena *arena) +_PyArena_Free(PyArena *arena) { assert(arena); #if defined(Py_DEBUG) @@ -177,7 +178,7 @@ PyArena_Free(PyArena *arena) } void * -PyArena_Malloc(PyArena *arena, size_t size) +_PyArena_Malloc(PyArena *arena, size_t size) { void *p = block_alloc(arena->a_cur, size); if (!p) @@ -200,7 +201,7 @@ PyArena_Malloc(PyArena *arena, size_t size) } int -PyArena_AddPyObject(PyArena *arena, PyObject *obj) +_PyArena_AddPyObject(PyArena *arena, PyObject *obj) { int r = PyList_Append(arena->a_objects, obj); if (r >= 0) { diff --git a/contrib/tools/python3/src/Python/pyhash.c b/contrib/tools/python3/src/Python/pyhash.c index 3843079fbbc..f0c82356f1e 100644 --- a/contrib/tools/python3/src/Python/pyhash.c +++ b/contrib/tools/python3/src/Python/pyhash.c @@ -56,8 +56,12 @@ static Py_ssize_t hashstats[Py_HASH_STATS_MAX + 1] = {0}; If the result of the reduction is infinity (this is impossible for integers, floats and Decimals) then use the predefined hash value _PyHASH_INF for x >= 0, or -_PyHASH_INF for x < 0, instead. - _PyHASH_INF, -_PyHASH_INF and _PyHASH_NAN are also used for the - hashes of float and Decimal infinities and nans. + _PyHASH_INF and -_PyHASH_INF are also used for the + hashes of float and Decimal infinities. + + NaNs hash with a pointer hash. Having distinct hash values prevents + catastrophic pileups from distinct NaN instances which used to always + have the same hash value but would compare unequal. A selling point for the above strategy is that it makes it possible to compute hashes of decimal and binary floating-point numbers @@ -82,8 +86,10 @@ static Py_ssize_t hashstats[Py_HASH_STATS_MAX + 1] = {0}; */ +Py_hash_t _Py_HashPointer(const void *); + Py_hash_t -_Py_HashDouble(double v) +_Py_HashDouble(PyObject *inst, double v) { int e, sign; double m; @@ -93,7 +99,7 @@ _Py_HashDouble(double v) if (Py_IS_INFINITY(v)) return v > 0 ? _PyHASH_INF : -_PyHASH_INF; else - return _PyHASH_NAN; + return _Py_HashPointer(inst); } m = frexp(v, &e); @@ -200,18 +206,14 @@ void _PyHash_Fini(void) { #ifdef Py_HASH_STATS - int i; - Py_ssize_t total = 0; - const char *fmt = "%2i %8" PY_FORMAT_SIZE_T "d %8" PY_FORMAT_SIZE_T "d\n"; - fprintf(stderr, "len calls total\n"); - for (i = 1; i <= Py_HASH_STATS_MAX; i++) { + Py_ssize_t total = 0; + for (int i = 1; i <= Py_HASH_STATS_MAX; i++) { total += hashstats[i]; - fprintf(stderr, fmt, i, hashstats[i], total); + fprintf(stderr, "%2i %8zd %8zd\n", i, hashstats[i], total); } total += hashstats[0]; - fprintf(stderr, "> %8" PY_FORMAT_SIZE_T "d %8" PY_FORMAT_SIZE_T "d\n", - hashstats[0], total); + fprintf(stderr, "> %8zd %8zd\n", hashstats[0], total); #endif } diff --git a/contrib/tools/python3/src/Python/pylifecycle.c b/contrib/tools/python3/src/Python/pylifecycle.c index 7f591179ac4..0d534fcf685 100644 --- a/contrib/tools/python3/src/Python/pylifecycle.c +++ b/contrib/tools/python3/src/Python/pylifecycle.c @@ -2,13 +2,10 @@ #include "Python.h" -#include "Python-ast.h" -#undef Yield /* undefine macro conflicting with <winbase.h> */ - #include "pycore_ceval.h" // _PyEval_FiniGIL() #include "pycore_context.h" // _PyContext_Init() #include "pycore_fileutils.h" // _Py_ResetForceASCII() -#include "pycore_import.h" // _PyImport_Cleanup() +#include "pycore_import.h" // _PyImport_BootstrapImp() #include "pycore_initconfig.h" // _PyStatus_OK() #include "pycore_object.h" // _PyDebug_PrintTotalRefs() #include "pycore_pathconfig.h" // _PyConfig_WritePathConfig() @@ -18,9 +15,12 @@ #include "pycore_sysmodule.h" // _PySys_ClearAuditHooks() #include "pycore_traceback.h" // _Py_DumpTracebackThreads() -#include "grammar.h" // PyGrammar_RemoveAccelerators() #include <locale.h> // setlocale() +#if defined(__APPLE__) +#include <mach-o/loader.h> +#endif + #ifdef HAVE_SIGNAL_H # include <signal.h> // SIG_IGN #endif @@ -38,6 +38,8 @@ (PyObject_TypeCheck((op), &PyWindowsConsoleIO_Type)) #endif +#define PUTS(fd, str) _Py_write_noraise(fd, str, (int)strlen(str)) + _Py_IDENTIFIER(flush); _Py_IDENTIFIER(name); @@ -50,19 +52,40 @@ _Py_IDENTIFIER(threading); extern "C" { #endif -extern grammar _PyParser_Grammar; /* From graminit.c */ /* Forward declarations */ static PyStatus add_main_module(PyInterpreterState *interp); static PyStatus init_import_site(void); static PyStatus init_set_builtins_open(void); static PyStatus init_sys_streams(PyThreadState *tstate); -static void call_py_exitfuncs(PyThreadState *tstate); static void wait_for_thread_shutdown(PyThreadState *tstate); static void call_ll_exitfuncs(_PyRuntimeState *runtime); int _Py_UnhandledKeyboardInterrupt = 0; -_PyRuntimeState _PyRuntime = _PyRuntimeState_INIT; + +/* The following places the `_PyRuntime` structure in a location that can be + * found without any external information. This is meant to ease access to the + * interpreter state for various runtime debugging tools, but is *not* an + * officially supported feature */ + +#if defined(MS_WINDOWS) + +#pragma section("PyRuntime", read, write) +__declspec(allocate("PyRuntime")) + +#elif defined(__APPLE__) + +__attribute__(( + section(SEG_DATA ",PyRuntime") +)) + +#endif + +_PyRuntimeState _PyRuntime +#if defined(__linux__) && (defined(__GNUC__) || defined(__clang__)) +__attribute__ ((section (".PyRuntime"))) +#endif += _PyRuntimeState_INIT; static int runtime_initialized = 0; PyStatus @@ -99,14 +122,6 @@ _Py_IsFinalizing(void) int (*_PyOS_mystrnicmp_hack)(const char *, const char *, Py_ssize_t) = \ PyOS_mystrnicmp; /* Python/pystrcmp.o */ -/* PyModule_GetWarningsModule is no longer necessary as of 2.6 -since _warnings is builtin. This API should not be used. */ -PyObject * -PyModule_GetWarningsModule(void) -{ - return PyImport_ImportModule("warnings"); -} - /* APIs to access the initialization flags * @@ -137,59 +152,54 @@ Py_IsInitialized(void) having the lock, but you cannot use multiple threads.) */ - -static PyStatus +static int init_importlib(PyThreadState *tstate, PyObject *sysmod) { - PyObject *importlib; - PyObject *impmod; - PyObject *value; + assert(!_PyErr_Occurred(tstate)); + PyInterpreterState *interp = tstate->interp; int verbose = _PyInterpreterState_GetConfig(interp)->verbose; - /* Import _importlib through its frozen version, _frozen_importlib. */ - if (PyImport_ImportFrozenModule("_frozen_importlib") <= 0) { - return _PyStatus_ERR("can't import _frozen_importlib"); - } - else if (verbose) { + // Import _importlib through its frozen version, _frozen_importlib. + if (verbose) { PySys_FormatStderr("import _frozen_importlib # frozen\n"); } - importlib = PyImport_AddModule("_frozen_importlib"); + if (PyImport_ImportFrozenModule("_frozen_importlib") <= 0) { + return -1; + } + PyObject *importlib = PyImport_AddModule("_frozen_importlib"); // borrowed if (importlib == NULL) { - return _PyStatus_ERR("couldn't get _frozen_importlib from sys.modules"); + return -1; } - interp->importlib = importlib; - Py_INCREF(interp->importlib); - - interp->import_func = PyDict_GetItemString(interp->builtins, "__import__"); - if (interp->import_func == NULL) - return _PyStatus_ERR("__import__ not found"); - Py_INCREF(interp->import_func); + interp->importlib = Py_NewRef(importlib); - /* Import the _imp module */ - impmod = PyInit__imp(); - if (impmod == NULL) { - return _PyStatus_ERR("can't import _imp"); - } - else if (verbose) { + // Import the _imp module + if (verbose) { PySys_FormatStderr("import _imp # builtin\n"); } - if (_PyImport_SetModuleString("_imp", impmod) < 0) { - return _PyStatus_ERR("can't save _imp to sys.modules"); + PyObject *imp_mod = _PyImport_BootstrapImp(tstate); + if (imp_mod == NULL) { + return -1; + } + if (_PyImport_SetModuleString("_imp", imp_mod) < 0) { + Py_DECREF(imp_mod); + return -1; } - /* Install importlib as the implementation of import */ - value = PyObject_CallMethod(importlib, "_install", "OO", sysmod, impmod); + // Install importlib as the implementation of import + PyObject *value = PyObject_CallMethod(importlib, "_install", + "OO", sysmod, imp_mod); + Py_DECREF(imp_mod); if (value == NULL) { - _PyErr_Print(tstate); - return _PyStatus_ERR("importlib install failed"); + return -1; } Py_DECREF(value); - Py_DECREF(impmod); - return _PyStatus_OK(); + assert(!_PyErr_Occurred(tstate)); + return 0; } + static PyStatus init_importlib_external(PyThreadState *tstate) { @@ -438,6 +448,69 @@ _Py_SetLocaleFromEnv(int category) } +static int +interpreter_update_config(PyThreadState *tstate, int only_update_path_config) +{ + const PyConfig *config = &tstate->interp->config; + + if (!only_update_path_config) { + PyStatus status = _PyConfig_Write(config, tstate->interp->runtime); + if (_PyStatus_EXCEPTION(status)) { + _PyErr_SetFromPyStatus(status); + return -1; + } + } + + if (_Py_IsMainInterpreter(tstate->interp)) { + PyStatus status = _PyConfig_WritePathConfig(config); + if (_PyStatus_EXCEPTION(status)) { + _PyErr_SetFromPyStatus(status); + return -1; + } + } + + // Update the sys module for the new configuration + if (_PySys_UpdateConfig(tstate) < 0) { + return -1; + } + return 0; +} + + +int +_PyInterpreterState_SetConfig(const PyConfig *src_config) +{ + PyThreadState *tstate = PyThreadState_Get(); + int res = -1; + + PyConfig config; + PyConfig_InitPythonConfig(&config); + PyStatus status = _PyConfig_Copy(&config, src_config); + if (_PyStatus_EXCEPTION(status)) { + _PyErr_SetFromPyStatus(status); + goto done; + } + + status = PyConfig_Read(&config); + if (_PyStatus_EXCEPTION(status)) { + _PyErr_SetFromPyStatus(status); + goto done; + } + + status = _PyConfig_Copy(&tstate->interp->config, &config); + if (_PyStatus_EXCEPTION(status)) { + _PyErr_SetFromPyStatus(status); + goto done; + } + + res = interpreter_update_config(tstate, 0); + +done: + PyConfig_Clear(&config); + return res; +} + + /* Global initializations. Can be undone by Py_Finalize(). Don't call this twice without an intervening Py_Finalize() call. @@ -472,7 +545,7 @@ pyinit_core_reconfigure(_PyRuntimeState *runtime, return status; } - status = _PyInterpreterState_SetConfig(interp, config); + status = _PyConfig_Copy(&interp->config, config); if (_PyStatus_EXCEPTION(status)) { return status; } @@ -532,10 +605,10 @@ init_interp_create_gil(PyThreadState *tstate) /* finalize_interp_delete() comment explains why _PyEval_FiniGIL() is only called here. */ - _PyEval_FiniGIL(tstate); + _PyEval_FiniGIL(tstate->interp); /* Auto-thread-state API */ - status = _PyGILState_Init(tstate); + status = _PyGILState_SetTstate(tstate); if (_PyStatus_EXCEPTION(status)) { return status; } @@ -555,12 +628,19 @@ pycore_create_interpreter(_PyRuntimeState *runtime, const PyConfig *config, PyThreadState **tstate_p) { + /* Auto-thread-state API */ + PyStatus status = _PyGILState_Init(runtime); + if (_PyStatus_EXCEPTION(status)) { + return status; + } + PyInterpreterState *interp = PyInterpreterState_New(); if (interp == NULL) { return _PyStatus_ERR("can't make main interpreter"); } + assert(_Py_IsMainInterpreter(interp)); - PyStatus status = _PyInterpreterState_SetConfig(interp, config); + status = _PyConfig_Copy(&interp->config, config); if (_PyStatus_EXCEPTION(status)) { return status; } @@ -582,51 +662,75 @@ pycore_create_interpreter(_PyRuntimeState *runtime, static PyStatus -pycore_init_types(PyThreadState *tstate) +pycore_init_singletons(PyInterpreterState *interp) { PyStatus status; - int is_main_interp = _Py_IsMainInterpreter(tstate); - status = _PyGC_Init(tstate); + if (_PyLong_Init(interp) < 0) { + return _PyStatus_ERR("can't init longs"); + } + + if (_Py_IsMainInterpreter(interp)) { + _PyFloat_Init(); + } + + status = _PyBytes_Init(interp); + if (_PyStatus_EXCEPTION(status)) { + return status; + } + + status = _PyUnicode_Init(interp); if (_PyStatus_EXCEPTION(status)) { return status; } + status = _PyTuple_Init(interp); + if (_PyStatus_EXCEPTION(status)) { + return status; + } + + return _PyStatus_OK(); +} + + +static PyStatus +pycore_init_types(PyInterpreterState *interp) +{ + PyStatus status; + int is_main_interp = _Py_IsMainInterpreter(interp); + if (is_main_interp) { + if (_PyStructSequence_Init() < 0) { + return _PyStatus_ERR("can't initialize structseq"); + } + status = _PyTypes_Init(); if (_PyStatus_EXCEPTION(status)) { return status; } - } - - if (!_PyLong_Init(tstate)) { - return _PyStatus_ERR("can't init longs"); - } + if (_PyLong_InitTypes() < 0) { + return _PyStatus_ERR("can't init int type"); + } - if (is_main_interp) { - status = _PyUnicode_Init(); + status = _PyUnicode_InitTypes(); if (_PyStatus_EXCEPTION(status)) { return status; } } - status = _PyExc_Init(); - if (_PyStatus_EXCEPTION(status)) { - return status; - } - if (is_main_interp) { - if (!_PyFloat_Init()) { + if (_PyFloat_InitTypes() < 0) { return _PyStatus_ERR("can't init float"); } + } - if (_PyStructSequence_Init() < 0) { - return _PyStatus_ERR("can't initialize structseq"); - } + status = _PyExc_Init(interp); + if (_PyStatus_EXCEPTION(status)) { + return status; } - status = _PyErr_Init(); + status = _PyErr_InitTypes(); if (_PyStatus_EXCEPTION(status)) { return status; } @@ -644,14 +748,13 @@ pycore_init_types(PyThreadState *tstate) static PyStatus pycore_init_builtins(PyThreadState *tstate) { - assert(!_PyErr_Occurred(tstate)); + PyInterpreterState *interp = tstate->interp; - PyObject *bimod = _PyBuiltin_Init(tstate); + PyObject *bimod = _PyBuiltin_Init(interp); if (bimod == NULL) { goto error; } - PyInterpreterState *interp = tstate->interp; if (_PyImport_FixupBuiltin(bimod, "builtins", interp->modules) < 0) { goto error; } @@ -674,8 +777,15 @@ pycore_init_builtins(PyThreadState *tstate) } Py_DECREF(bimod); - assert(!_PyErr_Occurred(tstate)); + // Get the __import__ function + PyObject *import_func = _PyDict_GetItemStringWithError(interp->builtins, + "__import__"); + if (import_func == NULL) { + goto error; + } + interp->import_func = Py_NewRef(import_func); + assert(!_PyErr_Occurred(tstate)); return _PyStatus_OK(); error: @@ -685,54 +795,38 @@ error: static PyStatus -pycore_init_import_warnings(PyThreadState *tstate, PyObject *sysmod) +pycore_interp_init(PyThreadState *tstate) { - assert(!_PyErr_Occurred(tstate)); + PyInterpreterState *interp = tstate->interp; + PyStatus status; + PyObject *sysmod = NULL; - PyStatus status = _PyImportHooks_Init(tstate); + // Create singletons before the first PyType_Ready() call, since + // PyType_Ready() uses singletons like the Unicode empty string (tp_doc) + // and the empty tuple singletons (tp_bases). + status = pycore_init_singletons(interp); if (_PyStatus_EXCEPTION(status)) { return status; } - const PyConfig *config = _PyInterpreterState_GetConfig(tstate->interp); - if (_Py_IsMainInterpreter(tstate)) { - /* Initialize _warnings. */ - status = _PyWarnings_InitState(tstate); - if (_PyStatus_EXCEPTION(status)) { - return status; - } - - if (config->_install_importlib) { - status = _PyConfig_WritePathConfig(config); - if (_PyStatus_EXCEPTION(status)) { - return status; - } - } + // The GC must be initialized before the first GC collection. + status = _PyGC_Init(interp); + if (_PyStatus_EXCEPTION(status)) { + return status; } - /* This call sets up builtin and frozen import support */ - if (config->_install_importlib) { - status = init_importlib(tstate, sysmod); - if (_PyStatus_EXCEPTION(status)) { - return status; - } + status = pycore_init_types(interp); + if (_PyStatus_EXCEPTION(status)) { + goto done; } - assert(!_PyErr_Occurred(tstate)); - - return _PyStatus_OK(); -} - - -static PyStatus -pycore_interp_init(PyThreadState *tstate) -{ - PyStatus status; - PyObject *sysmod = NULL; + if (_PyWarnings_InitState(interp) < 0) { + return _PyStatus_ERR("can't initialize warnings"); + } - status = pycore_init_types(tstate); + status = _PyAtExit_Init(interp); if (_PyStatus_EXCEPTION(status)) { - goto done; + return status; } status = _PySys_Create(tstate, &sysmod); @@ -745,7 +839,13 @@ pycore_interp_init(PyThreadState *tstate) goto done; } - status = pycore_init_import_warnings(tstate, sysmod); + const PyConfig *config = _PyInterpreterState_GetConfig(interp); + if (config->_install_importlib) { + /* This call sets up builtin and frozen import support */ + if (init_importlib(tstate, sysmod) < 0) { + return _PyStatus_ERR("failed to initialize importlib"); + } + } done: /* sys.modules['sys'] contains a strong reference to the module */ @@ -919,14 +1019,16 @@ pyinit_core(_PyRuntimeState *runtime, } PyConfig config; - _PyConfig_InitCompatConfig(&config); + PyConfig_InitPythonConfig(&config); status = _PyConfig_Copy(&config, src_config); if (_PyStatus_EXCEPTION(status)) { goto done; } - status = PyConfig_Read(&config); + // Read the configuration, but don't compute the path configuration + // (it is computed in the main init). + status = _PyConfig_Read(&config, 0); if (_PyStatus_EXCEPTION(status)) { goto done; } @@ -951,19 +1053,10 @@ done: configuration. Example of bpo-34008: Py_Main() called after Py_Initialize(). */ static PyStatus -_Py_ReconfigureMainInterpreter(PyThreadState *tstate) +pyinit_main_reconfigure(PyThreadState *tstate) { - const PyConfig *config = _PyInterpreterState_GetConfig(tstate->interp); - - PyObject *argv = _PyWideStringList_AsList(&config->argv); - if (argv == NULL) { - return _PyStatus_NO_MEMORY(); \ - } - - int res = PyDict_SetItemString(tstate->interp->sysdict, "argv", argv); - Py_DECREF(argv); - if (res < 0) { - return _PyStatus_ERR("fail to set sys.argv"); + if (interpreter_update_config(tstate, 0) < 0) { + return _PyStatus_ERR("fail to reconfigure Python"); } return _PyStatus_OK(); } @@ -972,10 +1065,12 @@ _Py_ReconfigureMainInterpreter(PyThreadState *tstate) static PyStatus init_interp_main(PyThreadState *tstate) { + extern void _PyThread_debug_deprecation(void); + assert(!_PyErr_Occurred(tstate)); PyStatus status; - int is_main_interp = _Py_IsMainInterpreter(tstate); + int is_main_interp = _Py_IsMainInterpreter(tstate->interp); PyInterpreterState *interp = tstate->interp; const PyConfig *config = _PyInterpreterState_GetConfig(interp); @@ -991,14 +1086,14 @@ init_interp_main(PyThreadState *tstate) return _PyStatus_OK(); } - if (is_main_interp) { - if (_PyTime_Init() < 0) { - return _PyStatus_ERR("can't initialize time"); - } + // Compute the path configuration + status = _PyConfig_InitPathConfig(&interp->config, 1); + if (_PyStatus_EXCEPTION(status)) { + return status; } - if (_PySys_InitMain(tstate) < 0) { - return _PyStatus_ERR("can't finish initializing sys"); + if (interpreter_update_config(tstate, 1) < 0) { + return _PyStatus_ERR("failed to update the Python config"); } status = init_importlib_external(tstate); @@ -1073,6 +1168,9 @@ init_interp_main(PyThreadState *tstate) #endif } + // Warn about PYTHONTHREADDEBUG deprecation + _PyThread_debug_deprecation(); + assert(!_PyErr_Occurred(tstate)); return _PyStatus_OK(); @@ -1099,7 +1197,7 @@ pyinit_main(PyThreadState *tstate) } if (interp->runtime->initialized) { - return _Py_ReconfigureMainInterpreter(tstate); + return pyinit_main_reconfigure(tstate); } PyStatus status = init_interp_main(tstate); @@ -1111,19 +1209,6 @@ pyinit_main(PyThreadState *tstate) PyStatus -_Py_InitializeMain(void) -{ - PyStatus status = _PyRuntime_Initialize(); - if (_PyStatus_EXCEPTION(status)) { - return status; - } - _PyRuntimeState *runtime = &_PyRuntime; - PyThreadState *tstate = _PyRuntimeState_GetThreadState(runtime); - return pyinit_main(tstate); -} - - -PyStatus Py_InitializeFromConfig(const PyConfig *config) { if (config == NULL) { @@ -1190,6 +1275,305 @@ Py_Initialize(void) } +PyStatus +_Py_InitializeMain(void) +{ + PyStatus status = _PyRuntime_Initialize(); + if (_PyStatus_EXCEPTION(status)) { + return status; + } + _PyRuntimeState *runtime = &_PyRuntime; + PyThreadState *tstate = _PyRuntimeState_GetThreadState(runtime); + return pyinit_main(tstate); +} + + +static void +finalize_modules_delete_special(PyThreadState *tstate, int verbose) +{ + // List of names to clear in sys + static const char * const sys_deletes[] = { + "path", "argv", "ps1", "ps2", + "last_type", "last_value", "last_traceback", + "path_hooks", "path_importer_cache", "meta_path", + "__interactivehook__", + NULL + }; + + static const char * const sys_files[] = { + "stdin", "__stdin__", + "stdout", "__stdout__", + "stderr", "__stderr__", + NULL + }; + + PyInterpreterState *interp = tstate->interp; + if (verbose) { + PySys_WriteStderr("# clear builtins._\n"); + } + if (PyDict_SetItemString(interp->builtins, "_", Py_None) < 0) { + PyErr_WriteUnraisable(NULL); + } + + const char * const *p; + for (p = sys_deletes; *p != NULL; p++) { + if (verbose) { + PySys_WriteStderr("# clear sys.%s\n", *p); + } + if (PyDict_SetItemString(interp->sysdict, *p, Py_None) < 0) { + PyErr_WriteUnraisable(NULL); + } + } + for (p = sys_files; *p != NULL; p+=2) { + const char *name = p[0]; + const char *orig_name = p[1]; + if (verbose) { + PySys_WriteStderr("# restore sys.%s\n", name); + } + PyObject *value = _PyDict_GetItemStringWithError(interp->sysdict, + orig_name); + if (value == NULL) { + if (_PyErr_Occurred(tstate)) { + PyErr_WriteUnraisable(NULL); + } + value = Py_None; + } + if (PyDict_SetItemString(interp->sysdict, name, value) < 0) { + PyErr_WriteUnraisable(NULL); + } + } +} + + +static PyObject* +finalize_remove_modules(PyObject *modules, int verbose) +{ + PyObject *weaklist = PyList_New(0); + if (weaklist == NULL) { + PyErr_WriteUnraisable(NULL); + } + +#define STORE_MODULE_WEAKREF(name, mod) \ + if (weaklist != NULL) { \ + PyObject *wr = PyWeakref_NewRef(mod, NULL); \ + if (wr) { \ + PyObject *tup = PyTuple_Pack(2, name, wr); \ + if (!tup || PyList_Append(weaklist, tup) < 0) { \ + PyErr_WriteUnraisable(NULL); \ + } \ + Py_XDECREF(tup); \ + Py_DECREF(wr); \ + } \ + else { \ + PyErr_WriteUnraisable(NULL); \ + } \ + } + +#define CLEAR_MODULE(name, mod) \ + if (PyModule_Check(mod)) { \ + if (verbose && PyUnicode_Check(name)) { \ + PySys_FormatStderr("# cleanup[2] removing %U\n", name); \ + } \ + STORE_MODULE_WEAKREF(name, mod); \ + if (PyObject_SetItem(modules, name, Py_None) < 0) { \ + PyErr_WriteUnraisable(NULL); \ + } \ + } + + if (PyDict_CheckExact(modules)) { + Py_ssize_t pos = 0; + PyObject *key, *value; + while (PyDict_Next(modules, &pos, &key, &value)) { + CLEAR_MODULE(key, value); + } + } + else { + PyObject *iterator = PyObject_GetIter(modules); + if (iterator == NULL) { + PyErr_WriteUnraisable(NULL); + } + else { + PyObject *key; + while ((key = PyIter_Next(iterator))) { + PyObject *value = PyObject_GetItem(modules, key); + if (value == NULL) { + PyErr_WriteUnraisable(NULL); + continue; + } + CLEAR_MODULE(key, value); + Py_DECREF(value); + Py_DECREF(key); + } + if (PyErr_Occurred()) { + PyErr_WriteUnraisable(NULL); + } + Py_DECREF(iterator); + } + } +#undef CLEAR_MODULE +#undef STORE_MODULE_WEAKREF + + return weaklist; +} + + +static void +finalize_clear_modules_dict(PyObject *modules) +{ + if (PyDict_CheckExact(modules)) { + PyDict_Clear(modules); + } + else { + _Py_IDENTIFIER(clear); + if (_PyObject_CallMethodIdNoArgs(modules, &PyId_clear) == NULL) { + PyErr_WriteUnraisable(NULL); + } + } +} + + +static void +finalize_restore_builtins(PyThreadState *tstate) +{ + PyInterpreterState *interp = tstate->interp; + PyObject *dict = PyDict_Copy(interp->builtins); + if (dict == NULL) { + PyErr_WriteUnraisable(NULL); + } + PyDict_Clear(interp->builtins); + if (PyDict_Update(interp->builtins, interp->builtins_copy)) { + _PyErr_Clear(tstate); + } + Py_XDECREF(dict); +} + + +static void +finalize_modules_clear_weaklist(PyInterpreterState *interp, + PyObject *weaklist, int verbose) +{ + // First clear modules imported later + for (Py_ssize_t i = PyList_GET_SIZE(weaklist) - 1; i >= 0; i--) { + PyObject *tup = PyList_GET_ITEM(weaklist, i); + PyObject *name = PyTuple_GET_ITEM(tup, 0); + PyObject *mod = PyWeakref_GET_OBJECT(PyTuple_GET_ITEM(tup, 1)); + if (mod == Py_None) { + continue; + } + assert(PyModule_Check(mod)); + PyObject *dict = PyModule_GetDict(mod); + if (dict == interp->builtins || dict == interp->sysdict) { + continue; + } + Py_INCREF(mod); + if (verbose && PyUnicode_Check(name)) { + PySys_FormatStderr("# cleanup[3] wiping %U\n", name); + } + _PyModule_Clear(mod); + Py_DECREF(mod); + } +} + + +static void +finalize_clear_sys_builtins_dict(PyInterpreterState *interp, int verbose) +{ + // Clear sys dict + if (verbose) { + PySys_FormatStderr("# cleanup[3] wiping sys\n"); + } + _PyModule_ClearDict(interp->sysdict); + + // Clear builtins dict + if (verbose) { + PySys_FormatStderr("# cleanup[3] wiping builtins\n"); + } + _PyModule_ClearDict(interp->builtins); +} + + +/* Clear modules, as good as we can */ +static void +finalize_modules(PyThreadState *tstate) +{ + PyInterpreterState *interp = tstate->interp; + PyObject *modules = interp->modules; + if (modules == NULL) { + // Already done + return; + } + int verbose = _PyInterpreterState_GetConfig(interp)->verbose; + + // Delete some special builtins._ and sys attributes first. These are + // common places where user values hide and people complain when their + // destructors fail. Since the modules containing them are + // deleted *last* of all, they would come too late in the normal + // destruction order. Sigh. + // + // XXX Perhaps these precautions are obsolete. Who knows? + finalize_modules_delete_special(tstate, verbose); + + // Remove all modules from sys.modules, hoping that garbage collection + // can reclaim most of them: set all sys.modules values to None. + // + // We prepare a list which will receive (name, weakref) tuples of + // modules when they are removed from sys.modules. The name is used + // for diagnosis messages (in verbose mode), while the weakref helps + // detect those modules which have been held alive. + PyObject *weaklist = finalize_remove_modules(modules, verbose); + + // Clear the modules dict + finalize_clear_modules_dict(modules); + + // Restore the original builtins dict, to ensure that any + // user data gets cleared. + finalize_restore_builtins(tstate); + + // Collect garbage + _PyGC_CollectNoFail(tstate); + + // Dump GC stats before it's too late, since it uses the warnings + // machinery. + _PyGC_DumpShutdownStats(interp); + + if (weaklist != NULL) { + // Now, if there are any modules left alive, clear their globals to + // minimize potential leaks. All C extension modules actually end + // up here, since they are kept alive in the interpreter state. + // + // The special treatment of "builtins" here is because even + // when it's not referenced as a module, its dictionary is + // referenced by almost every module's __builtins__. Since + // deleting a module clears its dictionary (even if there are + // references left to it), we need to delete the "builtins" + // module last. Likewise, we don't delete sys until the very + // end because it is implicitly referenced (e.g. by print). + // + // Since dict is ordered in CPython 3.6+, modules are saved in + // importing order. First clear modules imported later. + finalize_modules_clear_weaklist(interp, weaklist, verbose); + Py_DECREF(weaklist); + } + + // Clear sys and builtins modules dict + finalize_clear_sys_builtins_dict(interp, verbose); + + // Clear module dict copies stored in the interpreter state: + // clear PyInterpreterState.modules_by_index and + // clear PyModuleDef.m_base.m_copy (of extensions not using the multi-phase + // initialization API) + _PyInterpreterState_ClearModules(interp); + + // Clear and delete the modules directory. Actual modules will + // still be there only if imported during the execution of some + // destructor. + Py_SETREF(interp->modules, NULL); + + // Collect garbage once more + _PyGC_CollectNoFail(tstate); +} + + /* Flush stdout and stderr */ static int @@ -1208,6 +1592,7 @@ file_is_closed(PyObject *fobj) return r > 0; } + static int flush_std_files(void) { @@ -1255,56 +1640,37 @@ flush_std_files(void) static void -finalize_interp_types(PyThreadState *tstate, int is_main_interp) +finalize_interp_types(PyInterpreterState *interp) { - if (is_main_interp) { - /* Sundry finalizers */ - _PyAST_Fini(); - _PyFrame_Fini(); - _PyTuple_Fini(); - _PyList_Fini(); - _PySet_Fini(); - _PyBytes_Fini(); - } - - _PyLong_Fini(tstate); - - if (is_main_interp) { - _PyFloat_Fini(); - _PyDict_Fini(); - _PySlice_Fini(); - } + _PyExc_Fini(interp); + _PyFrame_Fini(interp); + _PyAsyncGen_Fini(interp); + _PyContext_Fini(interp); + _PyType_Fini(interp); + // Call _PyUnicode_ClearInterned() before _PyDict_Fini() since it uses + // a dict internally. + _PyUnicode_ClearInterned(interp); - _PyWarnings_Fini(tstate->interp); + _PyDict_Fini(interp); + _PyList_Fini(interp); + _PyTuple_Fini(interp); - if (is_main_interp) { - _Py_HashRandomization_Fini(); - _PyArg_Fini(); - _PyAsyncGen_Fini(); - _PyContext_Fini(); - } + _PySlice_Fini(interp); - /* Cleanup Unicode implementation */ - _PyUnicode_Fini(tstate); - - if (is_main_interp) { - _Py_ClearFileSystemEncoding(); - } + _PyBytes_Fini(interp); + _PyUnicode_Fini(interp); + _PyFloat_Fini(interp); + _PyLong_Fini(interp); } static void finalize_interp_clear(PyThreadState *tstate) { - int is_main_interp = _Py_IsMainInterpreter(tstate); + int is_main_interp = _Py_IsMainInterpreter(tstate->interp); /* Clear interpreter state and all thread states */ - PyInterpreterState_Clear(tstate->interp); - - /* Trigger a GC collection on subinterpreters*/ - if (!is_main_interp) { - _PyGC_CollectNoFail(); - } + _PyInterpreterState_Clear(tstate); /* Clear all loghooks */ /* Both _PySys_Audit function and users still need PyObject, such as tuple. @@ -1313,30 +1679,22 @@ finalize_interp_clear(PyThreadState *tstate) _PySys_ClearAuditHooks(tstate); } - finalize_interp_types(tstate, is_main_interp); - if (is_main_interp) { - /* XXX Still allocated: - - various static ad-hoc pointers to interned strings - - int and float free list blocks - - whatever various modules and libraries allocate - */ - - PyGrammar_RemoveAccelerators(&_PyParser_Grammar); - - _PyExc_Fini(); + _Py_HashRandomization_Fini(); + _PyArg_Fini(); + _Py_ClearFileSystemEncoding(); } - _PyGC_Fini(tstate); + finalize_interp_types(tstate->interp); } static void -finalize_interp_delete(PyThreadState *tstate) +finalize_interp_delete(PyInterpreterState *interp) { - if (_Py_IsMainInterpreter(tstate)) { + if (_Py_IsMainInterpreter(interp)) { /* Cleanup auto-thread-state */ - _PyGILState_Fini(tstate); + _PyGILState_Fini(interp); } /* We can't call _PyEval_FiniGIL() here because destroying the GIL lock can @@ -1345,7 +1703,7 @@ finalize_interp_delete(PyThreadState *tstate) created GIL, which ensures that Py_Initialize / Py_FinalizeEx can be called multiple times. */ - PyInterpreterState_Delete(tstate->interp); + PyInterpreterState_Delete(interp); } @@ -1378,7 +1736,7 @@ Py_FinalizeEx(void) * the threads created via Threading. */ - call_py_exitfuncs(tstate); + _PyAtExit_Call(tstate->interp); /* Copy the core config, PyInterpreterState_Delete() free the core config memory */ @@ -1414,7 +1772,7 @@ Py_FinalizeEx(void) } /* Disable signal handling */ - PyOS_FiniInterrupts(); + _PySignal_Fini(); /* Collect garbage. This may call finalizers; it's nice to call these * before all modules are destroyed. @@ -1428,10 +1786,10 @@ Py_FinalizeEx(void) * XXX but I'm unclear on exactly how that one happens. In any case, * XXX I haven't seen a real-life report of either of these. */ - _PyGC_CollectIfEnabled(); + PyGC_Collect(); /* Destroy all modules */ - _PyImport_Cleanup(tstate); + finalize_modules(tstate); /* Print debug stats if any */ _PyEval_Fini(); @@ -1467,9 +1825,6 @@ Py_FinalizeEx(void) /* Destroy the database used by _PyImport_{Fixup,Find}Extension */ _PyImport_Fini(); - /* Cleanup typeobject.c's internal caches. */ - _PyType_Fini(); - /* unload faulthandler module */ _PyFaulthandler_Fini(); @@ -1494,7 +1849,7 @@ Py_FinalizeEx(void) #endif /* Py_TRACE_REFS */ finalize_interp_clear(tstate); - finalize_interp_delete(tstate); + finalize_interp_delete(tstate->interp); #ifdef Py_TRACE_REFS /* Display addresses (& refcnts) of all objects still alive. @@ -1573,17 +1928,20 @@ new_interpreter(PyThreadState **tstate_p, int isolated_subinterpreter) /* Copy the current interpreter config into the new interpreter */ const PyConfig *config; +#ifndef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS if (save_tstate != NULL) { config = _PyInterpreterState_GetConfig(save_tstate->interp); } else +#endif { /* No current thread state, copy from the main interpreter */ PyInterpreterState *main_interp = PyInterpreterState_Main(); config = _PyInterpreterState_GetConfig(main_interp); } - status = _PyInterpreterState_SetConfig(interp, config); + + status = _PyConfig_Copy(&interp->config, config); if (_PyStatus_EXCEPTION(status)) { goto error; } @@ -1666,15 +2024,16 @@ Py_EndInterpreter(PyThreadState *tstate) // Wrap up existing "threading"-module-created, non-daemon threads. wait_for_thread_shutdown(tstate); - call_py_exitfuncs(tstate); + _PyAtExit_Call(tstate->interp); if (tstate != interp->tstate_head || tstate->next != NULL) { Py_FatalError("not the last thread"); } - _PyImport_Cleanup(tstate); + finalize_modules(tstate); + finalize_interp_clear(tstate); - finalize_interp_delete(tstate); + finalize_interp_delete(tstate->interp); } /* Add the __main__ module */ @@ -1695,7 +2054,10 @@ add_main_module(PyInterpreterState *interp) } Py_DECREF(ann_dict); - if (PyDict_GetItemString(d, "__builtins__") == NULL) { + if (_PyDict_GetItemStringWithError(d, "__builtins__") == NULL) { + if (PyErr_Occurred()) { + return _PyStatus_ERR("Failed to test __main__.__builtins__"); + } PyObject *bimod = PyImport_ImportModule("builtins"); if (bimod == NULL) { return _PyStatus_ERR("Failed to retrieve builtins module"); @@ -1712,8 +2074,11 @@ add_main_module(PyInterpreterState *interp) * be set if __main__ gets further initialized later in the startup * process. */ - loader = PyDict_GetItemString(d, "__loader__"); + loader = _PyDict_GetItemStringWithError(d, "__loader__"); if (loader == NULL || loader == Py_None) { + if (PyErr_Occurred()) { + return _PyStatus_ERR("Failed to test __main__.__loader__"); + } PyObject *loader = PyObject_GetAttrString(interp->importlib, "BuiltinImporter"); if (loader == NULL) { @@ -1915,7 +2280,7 @@ error: return NULL; } -/* Set builtins.open to io.OpenWrapper */ +/* Set builtins.open to io.open */ static PyStatus init_set_builtins_open(void) { @@ -1931,7 +2296,7 @@ init_set_builtins_open(void) goto error; } - if (!(wrapper = PyObject_GetAttrString(iomod, "OpenWrapper"))) { + if (!(wrapper = PyObject_GetAttrString(iomod, "open"))) { goto error; } @@ -1953,12 +2318,11 @@ done: } -/* Initialize sys.stdin, stdout, stderr and builtins.open */ +/* Create sys.stdin, sys.stdout and sys.stderr */ static PyStatus init_sys_streams(PyThreadState *tstate) { PyObject *iomod = NULL; - PyObject *m; PyObject *std = NULL; int fd; PyObject * encoding_attr; @@ -1978,18 +2342,6 @@ init_sys_streams(PyThreadState *tstate) } #endif - /* Hack to avoid a nasty recursion issue when Python is invoked - in verbose mode: pre-import the Latin-1 and UTF-8 codecs */ - if ((m = PyImport_ImportModule("encodings.utf_8")) == NULL) { - goto error; - } - Py_DECREF(m); - - if (!(m = PyImport_ImportModule("encodings.latin_1"))) { - goto error; - } - Py_DECREF(m); - if (!(iomod = PyImport_ImportModule("io"))) { goto error; } @@ -2069,8 +2421,7 @@ static void _Py_FatalError_DumpTracebacks(int fd, PyInterpreterState *interp, PyThreadState *tstate) { - fputc('\n', stderr); - fflush(stderr); + PUTS(fd, "\n"); /* display the current Python stack */ _Py_DumpTracebackThreads(fd, interp, tstate); @@ -2172,30 +2523,31 @@ fatal_output_debug(const char *msg) static void -fatal_error_dump_runtime(FILE *stream, _PyRuntimeState *runtime) +fatal_error_dump_runtime(int fd, _PyRuntimeState *runtime) { - fprintf(stream, "Python runtime state: "); + PUTS(fd, "Python runtime state: "); PyThreadState *finalizing = _PyRuntimeState_GetFinalizing(runtime); if (finalizing) { - fprintf(stream, "finalizing (tstate=%p)", finalizing); + PUTS(fd, "finalizing (tstate=0x"); + _Py_DumpHexadecimal(fd, (uintptr_t)finalizing, sizeof(finalizing) * 2); + PUTS(fd, ")"); } else if (runtime->initialized) { - fprintf(stream, "initialized"); + PUTS(fd, "initialized"); } else if (runtime->core_initialized) { - fprintf(stream, "core initialized"); + PUTS(fd, "core initialized"); } else if (runtime->preinitialized) { - fprintf(stream, "preinitialized"); + PUTS(fd, "preinitialized"); } else if (runtime->preinitializing) { - fprintf(stream, "preinitializing"); + PUTS(fd, "preinitializing"); } else { - fprintf(stream, "unknown"); + PUTS(fd, "unknown"); } - fprintf(stream, "\n"); - fflush(stream); + PUTS(fd, "\n"); } @@ -2214,11 +2566,104 @@ fatal_error_exit(int status) } +// Dump the list of extension modules of sys.modules, excluding stdlib modules +// (sys.stdlib_module_names), into fd file descriptor. +// +// This function is called by a signal handler in faulthandler: avoid memory +// allocations and keep the implementation simple. For example, the list is not +// sorted on purpose. +void +_Py_DumpExtensionModules(int fd, PyInterpreterState *interp) +{ + if (interp == NULL) { + return; + } + PyObject *modules = interp->modules; + if (modules == NULL || !PyDict_Check(modules)) { + return; + } + + Py_ssize_t pos; + PyObject *key, *value; + + // Avoid PyDict_GetItemString() which calls PyUnicode_FromString(), + // memory cannot be allocated on the heap in a signal handler. + // Iterate on the dict instead. + PyObject *stdlib_module_names = NULL; + if (interp->sysdict != NULL) { + pos = 0; + while (PyDict_Next(interp->sysdict, &pos, &key, &value)) { + if (PyUnicode_Check(key) + && PyUnicode_CompareWithASCIIString(key, "stdlib_module_names") == 0) { + stdlib_module_names = value; + break; + } + } + } + // If we failed to get sys.stdlib_module_names or it's not a frozenset, + // don't exclude stdlib modules. + if (stdlib_module_names != NULL && !PyFrozenSet_Check(stdlib_module_names)) { + stdlib_module_names = NULL; + } + + // List extensions + int header = 1; + Py_ssize_t count = 0; + pos = 0; + while (PyDict_Next(modules, &pos, &key, &value)) { + if (!PyUnicode_Check(key)) { + continue; + } + if (!_PyModule_IsExtension(value)) { + continue; + } + // Use the module name from the sys.modules key, + // don't attempt to get the module object name. + if (stdlib_module_names != NULL) { + int is_stdlib_ext = 0; + + Py_ssize_t i = 0; + PyObject *item; + Py_hash_t hash; + while (_PySet_NextEntry(stdlib_module_names, &i, &item, &hash)) { + if (PyUnicode_Check(item) + && PyUnicode_Compare(key, item) == 0) + { + is_stdlib_ext = 1; + break; + } + } + if (is_stdlib_ext) { + // Ignore stdlib extension + continue; + } + } + + if (header) { + PUTS(fd, "\nExtension modules: "); + header = 0; + } + else { + PUTS(fd, ", "); + } + + _Py_DumpASCII(fd, key); + count++; + } + + if (count) { + PUTS(fd, " (total: "); + _Py_DumpDecimal(fd, count); + PUTS(fd, ")"); + PUTS(fd, "\n"); + } +} + + static void _Py_NO_RETURN -fatal_error(FILE *stream, int header, const char *prefix, const char *msg, +fatal_error(int fd, int header, const char *prefix, const char *msg, int status) { - const int fd = fileno(stream); static int reentrant = 0; if (reentrant) { @@ -2229,29 +2674,22 @@ fatal_error(FILE *stream, int header, const char *prefix, const char *msg, reentrant = 1; if (header) { - fprintf(stream, "Fatal Python error: "); + PUTS(fd, "Fatal Python error: "); if (prefix) { - fputs(prefix, stream); - fputs(": ", stream); + PUTS(fd, prefix); + PUTS(fd, ": "); } if (msg) { - fputs(msg, stream); + PUTS(fd, msg); } else { - fprintf(stream, "<message not set>"); + PUTS(fd, "<message not set>"); } - fputs("\n", stream); - fflush(stream); + PUTS(fd, "\n"); } _PyRuntimeState *runtime = &_PyRuntime; - fatal_error_dump_runtime(stream, runtime); - - PyThreadState *tstate = _PyRuntimeState_GetThreadState(runtime); - PyInterpreterState *interp = NULL; - if (tstate != NULL) { - interp = tstate->interp; - } + fatal_error_dump_runtime(fd, runtime); /* Check if the current thread has a Python thread state and holds the GIL. @@ -2261,8 +2699,17 @@ fatal_error(FILE *stream, int header, const char *prefix, const char *msg, tss_tstate != tstate if the current Python thread does not hold the GIL. */ + PyThreadState *tstate = _PyRuntimeState_GetThreadState(runtime); + PyInterpreterState *interp = NULL; PyThreadState *tss_tstate = PyGILState_GetThisThreadState(); + if (tstate != NULL) { + interp = tstate->interp; + } + else if (tss_tstate != NULL) { + interp = tss_tstate->interp; + } int has_tstate_and_gil = (tss_tstate != NULL && tss_tstate == tstate); + if (has_tstate_and_gil) { /* If an exception is set, print the exception with its traceback */ if (!_Py_FatalError_PrintExc(tss_tstate)) { @@ -2274,6 +2721,8 @@ fatal_error(FILE *stream, int header, const char *prefix, const char *msg, _Py_FatalError_DumpTracebacks(fd, interp, tss_tstate); } + _Py_DumpExtensionModules(fd, interp); + /* The main purpose of faulthandler is to display the traceback. This function already did its best to display a traceback. Disable faulthandler to prevent writing a second traceback @@ -2299,14 +2748,14 @@ fatal_error(FILE *stream, int header, const char *prefix, const char *msg, void _Py_NO_RETURN Py_FatalError(const char *msg) { - fatal_error(stderr, 1, NULL, msg, -1); + fatal_error(fileno(stderr), 1, NULL, msg, -1); } void _Py_NO_RETURN _Py_FatalErrorFunc(const char *func, const char *msg) { - fatal_error(stderr, 1, func, msg, -1); + fatal_error(fileno(stderr), 1, func, msg, -1); } @@ -2321,12 +2770,12 @@ _Py_FatalErrorFormat(const char *func, const char *format, ...) reentrant = 1; FILE *stream = stderr; - fprintf(stream, "Fatal Python error: "); + const int fd = fileno(stream); + PUTS(fd, "Fatal Python error: "); if (func) { - fputs(func, stream); - fputs(": ", stream); + PUTS(fd, func); + PUTS(fd, ": "); } - fflush(stream); va_list vargs; #ifdef HAVE_STDARG_PROTOTYPES @@ -2340,7 +2789,7 @@ _Py_FatalErrorFormat(const char *func, const char *format, ...) fputs("\n", stream); fflush(stream); - fatal_error(stream, 0, NULL, NULL, -1); + fatal_error(fd, 0, NULL, NULL, -1); } @@ -2351,37 +2800,13 @@ Py_ExitStatusException(PyStatus status) exit(status.exitcode); } else if (_PyStatus_IS_ERROR(status)) { - fatal_error(stderr, 1, status.func, status.err_msg, 1); + fatal_error(fileno(stderr), 1, status.func, status.err_msg, 1); } else { Py_FatalError("Py_ExitStatusException() must not be called on success"); } } -/* Clean up and exit */ - -/* For the atexit module. */ -void _Py_PyAtExit(void (*func)(PyObject *), PyObject *module) -{ - PyInterpreterState *is = _PyInterpreterState_GET(); - - /* Guard against API misuse (see bpo-17852) */ - assert(is->pyexitfunc == NULL || is->pyexitfunc == func); - - is->pyexitfunc = func; - is->pyexitmodule = module; -} - -static void -call_py_exitfuncs(PyThreadState *tstate) -{ - PyInterpreterState *interp = tstate->interp; - if (interp->pyexitfunc == NULL) - return; - - (*interp->pyexitfunc)(interp->pyexitmodule); - _PyErr_Clear(tstate); -} /* Wait until threading._shutdown completes, provided the threading module was imported in the first place. @@ -2446,29 +2871,6 @@ Py_Exit(int sts) } -/* Restore signals that the interpreter has called SIG_IGN on to SIG_DFL. - * - * All of the code in this function must only use async-signal-safe functions, - * listed at `man 7 signal` or - * http://www.opengroup.org/onlinepubs/009695399/functions/xsh_chap02_04.html. - * - * If this function is updated, update also _posix_spawn() of subprocess.py. - */ -void -_Py_RestoreSignals(void) -{ -#ifdef SIGPIPE - PyOS_setsig(SIGPIPE, SIG_DFL); -#endif -#ifdef SIGXFZ - PyOS_setsig(SIGXFZ, SIG_DFL); -#endif -#ifdef SIGXFSZ - PyOS_setsig(SIGXFSZ, SIG_DFL); -#endif -} - - /* * The file descriptor fd is considered ``interactive'' if either * a) isatty(fd) is TRUE, or @@ -2488,6 +2890,21 @@ Py_FdIsInteractive(FILE *fp, const char *filename) } +int +_Py_FdIsInteractive(FILE *fp, PyObject *filename) +{ + if (isatty((int)fileno(fp))) { + return 1; + } + if (!Py_InteractiveFlag) { + return 0; + } + return (filename == NULL) || + (PyUnicode_CompareWithASCIIString(filename, "<stdin>") == 0) || + (PyUnicode_CompareWithASCIIString(filename, "???") == 0); +} + + /* Wrappers around sigaction() or signal(). */ PyOS_sighandler_t @@ -2540,7 +2957,10 @@ PyOS_setsig(int sig, PyOS_sighandler_t handler) struct sigaction context, ocontext; context.sa_handler = handler; sigemptyset(&context.sa_mask); - context.sa_flags = 0; + /* Using SA_ONSTACK is friendlier to other C/C++/Golang-VM code that + * extension module or embedding code may use where tiny thread stacks + * are used. https://bugs.python.org/issue43390 */ + context.sa_flags = SA_ONSTACK; if (sigaction(sig, &context, &ocontext) == -1) return SIG_ERR; return ocontext.sa_handler; diff --git a/contrib/tools/python3/src/Python/pymath.c b/contrib/tools/python3/src/Python/pymath.c index a08a0e79615..24b804223ee 100644 --- a/contrib/tools/python3/src/Python/pymath.c +++ b/contrib/tools/python3/src/Python/pymath.c @@ -79,18 +79,3 @@ round(double x) return copysign(y, x); } #endif /* HAVE_ROUND */ - -static const unsigned int BitLengthTable[32] = { - 0, 1, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, - 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5 -}; - -unsigned int _Py_bit_length(unsigned long d) { - unsigned int d_bits = 0; - while (d >= 32) { - d_bits += 6; - d >>= 6; - } - d_bits += BitLengthTable[d]; - return d_bits; -} diff --git a/contrib/tools/python3/src/Python/pystate.c b/contrib/tools/python3/src/Python/pystate.c index c3520c336a7..df98eb11bb0 100644 --- a/contrib/tools/python3/src/Python/pystate.c +++ b/contrib/tools/python3/src/Python/pystate.c @@ -4,6 +4,7 @@ #include "Python.h" #include "pycore_ceval.h" #include "pycore_initconfig.h" +#include "pycore_object.h" // _PyType_InitCache() #include "pycore_pyerrors.h" #include "pycore_pylifecycle.h" #include "pycore_pymem.h" // _PyMem_SetDefaultAllocator() @@ -53,6 +54,9 @@ _PyRuntimeState_Init_impl(_PyRuntimeState *runtime) void *open_code_hook = runtime->open_code_hook; void *open_code_userdata = runtime->open_code_userdata; _Py_AuditHookEntry *audit_hook_head = runtime->audit_hook_head; + // bpo-42882: Preserve next_index value if Py_Initialize()/Py_Finalize() + // is called multiple times. + Py_ssize_t unicode_next_index = runtime->unicode_ids.next_index; memset(runtime, 0, sizeof(*runtime)); @@ -73,18 +77,24 @@ _PyRuntimeState_Init_impl(_PyRuntimeState *runtime) runtime->interpreters.mutex = PyThread_allocate_lock(); if (runtime->interpreters.mutex == NULL) { - return _PyStatus_ERR("Can't initialize threads for interpreter"); + return _PyStatus_NO_MEMORY(); } runtime->interpreters.next_id = -1; runtime->xidregistry.mutex = PyThread_allocate_lock(); if (runtime->xidregistry.mutex == NULL) { - return _PyStatus_ERR("Can't initialize threads for cross-interpreter data registry"); + return _PyStatus_NO_MEMORY(); } // Set it to the ID of the main thread of the main interpreter. runtime->main_thread = PyThread_get_thread_ident(); + runtime->unicode_ids.lock = PyThread_allocate_lock(); + if (runtime->unicode_ids.lock == NULL) { + return _PyStatus_NO_MEMORY(); + } + runtime->unicode_ids.next_index = unicode_next_index; + return _PyStatus_OK(); } @@ -108,26 +118,24 @@ _PyRuntimeState_Fini(_PyRuntimeState *runtime) /* Force the allocator used by _PyRuntimeState_Init(). */ PyMemAllocatorEx old_alloc; _PyMem_SetDefaultAllocator(PYMEM_DOMAIN_RAW, &old_alloc); - - if (runtime->interpreters.mutex != NULL) { - PyThread_free_lock(runtime->interpreters.mutex); - runtime->interpreters.mutex = NULL; +#define FREE_LOCK(LOCK) \ + if (LOCK != NULL) { \ + PyThread_free_lock(LOCK); \ + LOCK = NULL; \ } - if (runtime->xidregistry.mutex != NULL) { - PyThread_free_lock(runtime->xidregistry.mutex); - runtime->xidregistry.mutex = NULL; - } + FREE_LOCK(runtime->interpreters.mutex); + FREE_LOCK(runtime->xidregistry.mutex); + FREE_LOCK(runtime->unicode_ids.lock); +#undef FREE_LOCK PyMem_SetAllocator(PYMEM_DOMAIN_RAW, &old_alloc); } #ifdef HAVE_FORK /* This function is called from PyOS_AfterFork_Child to ensure that - * newly created child processes do not share locks with the parent. - */ - -void + newly created child processes do not share locks with the parent. */ +PyStatus _PyRuntimeState_ReInitThreads(_PyRuntimeState *runtime) { // This was initially set in _PyRuntimeState_Init(). @@ -138,26 +146,25 @@ _PyRuntimeState_ReInitThreads(_PyRuntimeState *runtime) PyMemAllocatorEx old_alloc; _PyMem_SetDefaultAllocator(PYMEM_DOMAIN_RAW, &old_alloc); - int interp_mutex = _PyThread_at_fork_reinit(&runtime->interpreters.mutex); - int xidregistry_mutex = _PyThread_at_fork_reinit(&runtime->xidregistry.mutex); + int reinit_interp = _PyThread_at_fork_reinit(&runtime->interpreters.mutex); + int reinit_xidregistry = _PyThread_at_fork_reinit(&runtime->xidregistry.mutex); + int reinit_unicode_ids = _PyThread_at_fork_reinit(&runtime->unicode_ids.lock); PyMem_SetAllocator(PYMEM_DOMAIN_RAW, &old_alloc); /* bpo-42540: id_mutex is freed by _PyInterpreterState_Delete, which does * not force the default allocator. */ - int main_interp_id_mutex = _PyThread_at_fork_reinit(&runtime->interpreters.main->id_mutex); + int reinit_main_id = _PyThread_at_fork_reinit(&runtime->interpreters.main->id_mutex); - if (interp_mutex < 0) { - Py_FatalError("Can't initialize lock for runtime interpreters"); - } - - if (main_interp_id_mutex < 0) { - Py_FatalError("Can't initialize ID lock for main interpreter"); - } + if (reinit_interp < 0 + || reinit_main_id < 0 + || reinit_xidregistry < 0 + || reinit_unicode_ids < 0) + { + return _PyStatus_ERR("Failed to reinitialize runtime locks"); - if (xidregistry_mutex < 0) { - Py_FatalError("Can't initialize lock for cross-interpreter data registry"); } + return _PyStatus_OK(); } #endif @@ -223,6 +230,7 @@ PyInterpreterState_New(void) _PyGC_InitState(&interp->gc); PyConfig_InitPythonConfig(&interp->config); + _PyType_InitCache(interp); interp->eval_frame = _PyEval_EvalFrameDefault; #ifdef HAVE_DLOPEN @@ -276,14 +284,11 @@ out_of_memory: } -void -PyInterpreterState_Clear(PyInterpreterState *interp) +static void +interpreter_clear(PyInterpreterState *interp, PyThreadState *tstate) { _PyRuntimeState *runtime = interp->runtime; - /* Use the current Python thread state to call audit hooks, - not the current Python thread state of 'interp'. */ - PyThreadState *tstate = _PyThreadState_GET(); if (_PySys_Audit(tstate, "cpython.PyInterpreterState_Clear", NULL) < 0) { _PyErr_Clear(tstate); } @@ -302,8 +307,6 @@ PyInterpreterState_Clear(PyInterpreterState *interp) Py_CLEAR(interp->codec_error_registry); Py_CLEAR(interp->modules); Py_CLEAR(interp->modules_by_index); - Py_CLEAR(interp->sysdict); - Py_CLEAR(interp->builtins); Py_CLEAR(interp->builtins_copy); Py_CLEAR(interp->importlib); Py_CLEAR(interp->import_func); @@ -313,15 +316,52 @@ PyInterpreterState_Clear(PyInterpreterState *interp) Py_CLEAR(interp->after_forkers_parent); Py_CLEAR(interp->after_forkers_child); #endif - if (_PyRuntimeState_GetFinalizing(runtime) == NULL) { - _PyWarnings_Fini(interp); - } + + _PyAST_Fini(interp); + _PyWarnings_Fini(interp); + _PyAtExit_Fini(interp); + + // All Python types must be destroyed before the last GC collection. Python + // types create a reference cycle to themselves in their in their + // PyTypeObject.tp_mro member (the tuple contains the type). + + /* Last garbage collection on this interpreter */ + _PyGC_CollectNoFail(tstate); + _PyGC_Fini(interp); + + /* We don't clear sysdict and builtins until the end of this function. + Because clearing other attributes can execute arbitrary Python code + which requires sysdict and builtins. */ + PyDict_Clear(interp->sysdict); + PyDict_Clear(interp->builtins); + Py_CLEAR(interp->sysdict); + Py_CLEAR(interp->builtins); + // XXX Once we have one allocator per interpreter (i.e. // per-interpreter GC) we must ensure that all of the interpreter's // objects have been cleaned up at the point. } +void +PyInterpreterState_Clear(PyInterpreterState *interp) +{ + // Use the current Python thread state to call audit hooks and to collect + // garbage. It can be different than the current Python thread state + // of 'interp'. + PyThreadState *current_tstate = _PyThreadState_GET(); + + interpreter_clear(interp, current_tstate); +} + + +void +_PyInterpreterState_Clear(PyThreadState *tstate) +{ + interpreter_clear(tstate->interp, tstate); +} + + static void zapthreads(PyInterpreterState *interp, int check_current) { @@ -376,11 +416,12 @@ PyInterpreterState_Delete(PyInterpreterState *interp) } +#ifdef HAVE_FORK /* * Delete all interpreter states except the main interpreter. If there * is a current interpreter state, it *must* be the main interpreter. */ -void +PyStatus _PyInterpreterState_DeleteExceptMain(_PyRuntimeState *runtime) { struct _gilstate_runtime_state *gilstate = &runtime->gilstate; @@ -388,7 +429,7 @@ _PyInterpreterState_DeleteExceptMain(_PyRuntimeState *runtime) PyThreadState *tstate = _PyThreadState_Swap(gilstate, NULL); if (tstate != NULL && tstate->interp != interpreters->main) { - Py_FatalError("not main interpreter"); + return _PyStatus_ERR("not main interpreter"); } HEAD_LOCK(runtime); @@ -414,10 +455,12 @@ _PyInterpreterState_DeleteExceptMain(_PyRuntimeState *runtime) HEAD_UNLOCK(runtime); if (interpreters->head == NULL) { - Py_FatalError("missing main interpreter"); + return _PyStatus_ERR("missing main interpreter"); } _PyThreadState_Swap(gilstate, tstate); + return _PyStatus_OK(); } +#endif PyInterpreterState * @@ -496,24 +539,25 @@ _PyInterpreterState_IDInitref(PyInterpreterState *interp) } -void +int _PyInterpreterState_IDIncref(PyInterpreterState *interp) { - if (interp->id_mutex == NULL) { - return; + if (_PyInterpreterState_IDInitref(interp) < 0) { + return -1; } + PyThread_acquire_lock(interp->id_mutex, WAIT_LOCK); interp->id_refcount += 1; PyThread_release_lock(interp->id_mutex); + return 0; } void _PyInterpreterState_IDDecref(PyInterpreterState *interp) { - if (interp->id_mutex == NULL) { - return; - } + assert(interp->id_mutex != NULL); + struct _gilstate_runtime_state *gilstate = &_PyRuntime.gilstate; PyThread_acquire_lock(interp->id_mutex, WAIT_LOCK); assert(interp->id_refcount != 0); @@ -579,11 +623,11 @@ new_threadstate(PyInterpreterState *interp, int init) tstate->frame = NULL; tstate->recursion_depth = 0; - tstate->overflowed = 0; - tstate->recursion_critical = 0; + tstate->recursion_headroom = 0; tstate->stackcheck_counter = 0; tstate->tracing = 0; - tstate->use_tracing = 0; + tstate->root_cframe.use_tracing = 0; + tstate->cframe = &tstate->root_cframe; tstate->gilstate_counter = 0; tstate->async_exc = NULL; tstate->thread_id = PyThread_get_thread_ident(); @@ -753,7 +797,7 @@ PyState_RemoveModule(struct PyModuleDef* def) return PyList_SetItem(interp->modules_by_index, index, Py_None); } -/* Used by PyImport_Cleanup() */ +// Used by finalize_modules() void _PyInterpreterState_ClearModules(PyInterpreterState *interp) { @@ -949,6 +993,14 @@ _PyThreadState_DeleteExcept(_PyRuntimeState *runtime, PyThreadState *tstate) } +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS +PyThreadState* +_PyThreadState_GetTSS(void) { + return PyThread_tss_get(&_PyRuntime.gilstate.autoTSSkey); +} +#endif + + PyThreadState * _PyThreadState_UncheckedGet(void) { @@ -968,7 +1020,11 @@ PyThreadState_Get(void) PyThreadState * _PyThreadState_Swap(struct _gilstate_runtime_state *gilstate, PyThreadState *newts) { +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + PyThreadState *oldts = _PyThreadState_GetTSS(); +#else PyThreadState *oldts = _PyRuntimeGILState_GetThreadState(gilstate); +#endif _PyRuntimeGILState_SetThreadState(gilstate, newts); /* It should not be possible for more than one thread state @@ -987,6 +1043,9 @@ _PyThreadState_Swap(struct _gilstate_runtime_state *gilstate, PyThreadState *new errno = err; } #endif +#ifdef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS + PyThread_tss_set(&gilstate->autoTSSkey, newts); +#endif return oldts; } @@ -1092,7 +1151,7 @@ PyThreadState_SetAsyncExc(unsigned long id, PyObject *exc) HEAD_UNLOCK(runtime); Py_XDECREF(old_exc); - _PyEval_SignalAsyncExc(tstate); + _PyEval_SignalAsyncExc(tstate->interp); return 1; } HEAD_UNLOCK(runtime); @@ -1185,6 +1244,69 @@ done: return result; } +PyObject * +_PyThread_CurrentExceptions(void) +{ + PyThreadState *tstate = _PyThreadState_GET(); + + _Py_EnsureTstateNotNULL(tstate); + + if (_PySys_Audit(tstate, "sys._current_exceptions", NULL) < 0) { + return NULL; + } + + PyObject *result = PyDict_New(); + if (result == NULL) { + return NULL; + } + + /* for i in all interpreters: + * for t in all of i's thread states: + * if t's frame isn't NULL, map t's id to its frame + * Because these lists can mutate even when the GIL is held, we + * need to grab head_mutex for the duration. + */ + _PyRuntimeState *runtime = tstate->interp->runtime; + HEAD_LOCK(runtime); + PyInterpreterState *i; + for (i = runtime->interpreters.head; i != NULL; i = i->next) { + PyThreadState *t; + for (t = i->tstate_head; t != NULL; t = t->next) { + _PyErr_StackItem *err_info = _PyErr_GetTopmostException(t); + if (err_info == NULL) { + continue; + } + PyObject *id = PyLong_FromUnsignedLong(t->thread_id); + if (id == NULL) { + goto fail; + } + PyObject *exc_info = PyTuple_Pack( + 3, + err_info->exc_type != NULL ? err_info->exc_type : Py_None, + err_info->exc_value != NULL ? err_info->exc_value : Py_None, + err_info->exc_traceback != NULL ? err_info->exc_traceback : Py_None); + if (exc_info == NULL) { + Py_DECREF(id); + goto fail; + } + int stat = PyDict_SetItem(result, id, exc_info); + Py_DECREF(id); + Py_DECREF(exc_info); + if (stat < 0) { + goto fail; + } + } + } + goto done; + +fail: + Py_CLEAR(result); + +done: + HEAD_UNLOCK(runtime); + return result; +} + /* Python "auto thread state" API. */ /* Keep this as a static, as it is not reliable! It can only @@ -1208,9 +1330,23 @@ PyThreadState_IsCurrent(PyThreadState *tstate) Py_Initialize/Py_FinalizeEx */ PyStatus -_PyGILState_Init(PyThreadState *tstate) +_PyGILState_Init(_PyRuntimeState *runtime) +{ + struct _gilstate_runtime_state *gilstate = &runtime->gilstate; + if (PyThread_tss_create(&gilstate->autoTSSkey) != 0) { + return _PyStatus_NO_MEMORY(); + } + // PyThreadState_New() calls _PyGILState_NoteThreadState() which does + // nothing before autoInterpreterState is set. + assert(gilstate->autoInterpreterState == NULL); + return _PyStatus_OK(); +} + + +PyStatus +_PyGILState_SetTstate(PyThreadState *tstate) { - if (!_Py_IsMainInterpreter(tstate)) { + if (!_Py_IsMainInterpreter(tstate->interp)) { /* Currently, PyGILState is shared by all interpreters. The main * interpreter is responsible to initialize it. */ return _PyStatus_OK(); @@ -1222,9 +1358,6 @@ _PyGILState_Init(PyThreadState *tstate) struct _gilstate_runtime_state *gilstate = &tstate->interp->runtime->gilstate; - if (PyThread_tss_create(&gilstate->autoTSSkey) != 0) { - return _PyStatus_NO_MEMORY(); - } gilstate->autoInterpreterState = tstate->interp; assert(PyThread_tss_get(&gilstate->autoTSSkey) == NULL); assert(tstate->gilstate_counter == 0); @@ -1240,18 +1373,19 @@ _PyGILState_GetInterpreterStateUnsafe(void) } void -_PyGILState_Fini(PyThreadState *tstate) +_PyGILState_Fini(PyInterpreterState *interp) { - struct _gilstate_runtime_state *gilstate = &tstate->interp->runtime->gilstate; + struct _gilstate_runtime_state *gilstate = &interp->runtime->gilstate; PyThread_tss_delete(&gilstate->autoTSSkey); gilstate->autoInterpreterState = NULL; } +#ifdef HAVE_FORK /* Reset the TSS key - called by PyOS_AfterFork_Child(). * This should not be necessary, but some - buggy - pthread implementations * don't reset TSS upon fork(), see issue #10517. */ -void +PyStatus _PyGILState_Reinit(_PyRuntimeState *runtime) { struct _gilstate_runtime_state *gilstate = &runtime->gilstate; @@ -1259,7 +1393,7 @@ _PyGILState_Reinit(_PyRuntimeState *runtime) PyThread_tss_delete(&gilstate->autoTSSkey); if (PyThread_tss_create(&gilstate->autoTSSkey) != 0) { - Py_FatalError("Could not allocate TSS entry"); + return _PyStatus_NO_MEMORY(); } /* If the thread had an associated auto thread state, reassociate it with @@ -1267,9 +1401,11 @@ _PyGILState_Reinit(_PyRuntimeState *runtime) if (tstate && PyThread_tss_set(&gilstate->autoTSSkey, (void *)tstate) != 0) { - Py_FatalError("Couldn't create autoTSSkey mapping"); + return _PyStatus_ERR("failed to set autoTSSkey"); } + return _PyStatus_OK(); } +#endif /* When a thread state is created for a thread by some mechanism other than PyGILState_Ensure, it's important that the GILState machinery knows about @@ -1356,7 +1492,9 @@ PyGILState_Ensure(void) /* Ensure that _PyEval_InitThreads() and _PyGILState_Init() have been called by Py_Initialize() */ +#ifndef EXPERIMENTAL_ISOLATED_SUBINTERPRETERS assert(_PyEval_ThreadsInitialized(runtime)); +#endif assert(gilstate->autoInterpreterState); PyThreadState *tcur = (PyThreadState *)PyThread_tss_get(&gilstate->autoTSSkey); @@ -1812,11 +1950,17 @@ _PyInterpreterState_GetConfig(PyInterpreterState *interp) } -PyStatus -_PyInterpreterState_SetConfig(PyInterpreterState *interp, - const PyConfig *config) +int +_PyInterpreterState_GetConfigCopy(PyConfig *config) { - return _PyConfig_Copy(&interp->config, config); + PyInterpreterState *interp = PyInterpreterState_Get(); + + PyStatus status = _PyConfig_Copy(config, &interp->config); + if (PyStatus_Exception(status)) { + _PyErr_SetFromPyStatus(status); + return -1; + } + return 0; } diff --git a/contrib/tools/python3/src/Python/pystrtod.c b/contrib/tools/python3/src/Python/pystrtod.c index 1c8202c7761..9145d4eba12 100644 --- a/contrib/tools/python3/src/Python/pystrtod.c +++ b/contrib/tools/python3/src/Python/pystrtod.c @@ -255,7 +255,7 @@ _PyOS_ascii_strtod(const char *nptr, char **endptr) char *copy, *c; /* Create a copy of the input, with the '.' converted to the locale-specific decimal point */ - copy = (char *)PyMem_MALLOC(end - digits_pos + + copy = (char *)PyMem_Malloc(end - digits_pos + 1 + decimal_point_len); if (copy == NULL) { *endptr = (char *)nptr; @@ -286,7 +286,7 @@ _PyOS_ascii_strtod(const char *nptr, char **endptr) (fail_pos - copy); } - PyMem_FREE(copy); + PyMem_Free(copy); } else { diff --git a/contrib/tools/python3/src/Python/pythonrun.c b/contrib/tools/python3/src/Python/pythonrun.c index 364101e99de..0f1794acec7 100644 --- a/contrib/tools/python3/src/Python/pythonrun.c +++ b/contrib/tools/python3/src/Python/pythonrun.c @@ -10,28 +10,22 @@ #include "Python.h" -#include "Python-ast.h" -#undef Yield /* undefine macro conflicting with <winbase.h> */ - +#include "pycore_ast.h" // PyAST_mod2obj +#include "pycore_compile.h" // _PyAST_Compile() #include "pycore_interp.h" // PyInterpreterState.importlib #include "pycore_object.h" // _PyDebug_PrintTotalRefs(), // _PyType_GetQualName() -#include "pycore_pyerrors.h" // _PyErr_Fetch +#include "pycore_parser.h" // _PyParser_ASTFromString() +#include "pycore_pyerrors.h" // _PyErr_Fetch, _Py_Offer_Suggestions #include "pycore_pylifecycle.h" // _Py_UnhandledKeyboardInterrupt #include "pycore_pystate.h" // _PyInterpreterState_GET() #include "pycore_sysmodule.h" // _PySys_Audit() -#include "node.h" // node #include "token.h" // INDENT -#include "parsetok.h" // perrdetail #include "errcode.h" // E_EOF #include "code.h" // PyCodeObject -#include "symtable.h" // PySymtable_BuildObject() -#include "ast.h" // PyAST_FromNodeObject() #include "marshal.h" // PyMarshal_ReadLongFromFile() -#include "pegen_interface.h" // PyPegen_ASTFrom* - #ifdef MS_WINDOWS # include "malloc.h" // alloca() #endif @@ -59,60 +53,81 @@ _Py_static_string(PyId_string, "<string>"); extern "C" { #endif -extern Py_EXPORTED_SYMBOL grammar _PyParser_Grammar; /* From graminit.c */ - /* Forward */ static void flush_io(void); static PyObject *run_mod(mod_ty, PyObject *, PyObject *, PyObject *, PyCompilerFlags *, PyArena *); static PyObject *run_pyc_file(FILE *, PyObject *, PyObject *, PyCompilerFlags *); -static void err_input(perrdetail *); -static void err_free(perrdetail *); static int PyRun_InteractiveOneObjectEx(FILE *, PyObject *, PyCompilerFlags *); static PyObject* pyrun_file(FILE *fp, PyObject *filename, int start, PyObject *globals, PyObject *locals, int closeit, PyCompilerFlags *flags); -/* Parse input from a file and execute it */ int -PyRun_AnyFileExFlags(FILE *fp, const char *filename, int closeit, +_PyRun_AnyFileObject(FILE *fp, PyObject *filename, int closeit, PyCompilerFlags *flags) { - if (filename == NULL) - filename = "???"; - if (Py_FdIsInteractive(fp, filename)) { - int err = PyRun_InteractiveLoopFlags(fp, filename, flags); - if (closeit) + int decref_filename = 0; + if (filename == NULL) { + filename = PyUnicode_FromString("???"); + if (filename == NULL) { + PyErr_Print(); + return -1; + } + decref_filename = 1; + } + + int res; + if (_Py_FdIsInteractive(fp, filename)) { + res = _PyRun_InteractiveLoopObject(fp, filename, flags); + if (closeit) { fclose(fp); - return err; + } } - else - return PyRun_SimpleFileExFlags(fp, filename, closeit, flags); + else { + res = _PyRun_SimpleFileObject(fp, filename, closeit, flags); + } + + if (decref_filename) { + Py_DECREF(filename); + } + return res; } + +/* Parse input from a file and execute it */ int -PyRun_InteractiveLoopFlags(FILE *fp, const char *filename_str, PyCompilerFlags *flags) +PyRun_AnyFileExFlags(FILE *fp, const char *filename, int closeit, + PyCompilerFlags *flags) { - PyObject *filename, *v; - int ret, err; - PyCompilerFlags local_flags = _PyCompilerFlags_INIT; - int nomem_count = 0; -#ifdef Py_REF_DEBUG - int show_ref_count = _Py_GetConfig()->show_ref_count; -#endif - - filename = PyUnicode_DecodeFSDefault(filename_str); - if (filename == NULL) { - PyErr_Print(); - return -1; + PyObject *filename_obj; + if (filename != NULL) { + filename_obj = PyUnicode_DecodeFSDefault(filename); + if (filename_obj == NULL) { + PyErr_Print(); + return -1; + } } + else { + filename_obj = NULL; + } + int res = _PyRun_AnyFileObject(fp, filename_obj, closeit, flags); + Py_XDECREF(filename_obj); + return res; +} + +int +_PyRun_InteractiveLoopObject(FILE *fp, PyObject *filename, PyCompilerFlags *flags) +{ + PyCompilerFlags local_flags = _PyCompilerFlags_INIT; if (flags == NULL) { flags = &local_flags; } - v = _PySys_GetObjectId(&PyId_ps1); + + PyObject *v = _PySys_GetObjectId(&PyId_ps1); if (v == NULL) { _PySys_SetObjectId(&PyId_ps1, v = PyUnicode_FromString(">>> ")); Py_XDECREF(v); @@ -122,7 +137,13 @@ PyRun_InteractiveLoopFlags(FILE *fp, const char *filename_str, PyCompilerFlags * _PySys_SetObjectId(&PyId_ps2, v = PyUnicode_FromString("... ")); Py_XDECREF(v); } - err = 0; + +#ifdef Py_REF_DEBUG + int show_ref_count = _Py_GetConfig()->show_ref_count; +#endif + int err = 0; + int ret; + int nomem_count = 0; do { ret = PyRun_InteractiveOneObjectEx(fp, filename, flags); if (ret == -1 && PyErr_Occurred()) { @@ -149,35 +170,25 @@ PyRun_InteractiveLoopFlags(FILE *fp, const char *filename_str, PyCompilerFlags * } #endif } while (ret != E_EOF); - Py_DECREF(filename); return err; } -/* compute parser flags based on compiler flags */ -static int PARSER_FLAGS(PyCompilerFlags *flags) + +int +PyRun_InteractiveLoopFlags(FILE *fp, const char *filename, PyCompilerFlags *flags) { - int parser_flags = 0; - if (!flags) - return 0; - if (flags->cf_flags & PyCF_DONT_IMPLY_DEDENT) - parser_flags |= PyPARSE_DONT_IMPLY_DEDENT; - if (flags->cf_flags & PyCF_IGNORE_COOKIE) - parser_flags |= PyPARSE_IGNORE_COOKIE; - if (flags->cf_flags & CO_FUTURE_BARRY_AS_BDFL) - parser_flags |= PyPARSE_BARRY_AS_BDFL; - if (flags->cf_flags & PyCF_TYPE_COMMENTS) - parser_flags |= PyPARSE_TYPE_COMMENTS; - return parser_flags; + PyObject *filename_obj = PyUnicode_DecodeFSDefault(filename); + if (filename_obj == NULL) { + PyErr_Print(); + return -1; + } + + int err = _PyRun_InteractiveLoopObject(fp, filename_obj, flags); + Py_DECREF(filename_obj); + return err; + } -#if 0 -/* Keep an example of flags with future keyword support. */ -#define PARSER_FLAGS(flags) \ - ((flags) ? ((((flags)->cf_flags & PyCF_DONT_IMPLY_DEDENT) ? \ - PyPARSE_DONT_IMPLY_DEDENT : 0) \ - | ((flags)->cf_flags & CO_FUTURE_WITH_STATEMENT ? \ - PyPARSE_WITH_IS_KEYWORD : 0)) : 0) -#endif /* A PyRun_InteractiveOneObject() auxiliary function that does not print the * error on failure. */ @@ -190,7 +201,6 @@ PyRun_InteractiveOneObjectEx(FILE *fp, PyObject *filename, PyArena *arena; const char *ps1 = "", *ps2 = "", *enc = NULL; int errcode = 0; - int use_peg = _PyInterpreterState_GET()->config._use_peg_parser; _Py_IDENTIFIER(encoding); _Py_IDENTIFIER(__main__); @@ -236,7 +246,7 @@ PyRun_InteractiveOneObjectEx(FILE *fp, PyObject *filename, } } } - arena = PyArena_New(); + arena = _PyArena_New(); if (arena == NULL) { Py_XDECREF(v); Py_XDECREF(w); @@ -244,21 +254,14 @@ PyRun_InteractiveOneObjectEx(FILE *fp, PyObject *filename, return -1; } - if (use_peg) { - mod = PyPegen_ASTFromFileObject(fp, filename, Py_single_input, - enc, ps1, ps2, flags, &errcode, arena); - } - else { - mod = PyParser_ASTFromFileObject(fp, filename, enc, - Py_single_input, ps1, ps2, - flags, &errcode, arena); - } + mod = _PyParser_ASTFromFile(fp, filename, enc, Py_single_input, + ps1, ps2, flags, &errcode, arena); Py_XDECREF(v); Py_XDECREF(w); Py_XDECREF(oenc); if (mod == NULL) { - PyArena_Free(arena); + _PyArena_Free(arena); if (errcode == E_EOF) { PyErr_Clear(); return E_EOF; @@ -267,12 +270,12 @@ PyRun_InteractiveOneObjectEx(FILE *fp, PyObject *filename, } m = PyImport_AddModuleObject(mod_name); if (m == NULL) { - PyArena_Free(arena); + _PyArena_Free(arena); return -1; } d = PyModule_GetDict(m); v = run_mod(mod, filename, d, d, flags, arena); - PyArena_Free(arena); + _PyArena_Free(arena); if (v == NULL) { return -1; } @@ -392,9 +395,9 @@ set_main_loader(PyObject *d, PyObject *filename, const char *loader_name) } -static int -pyrun_simple_file(FILE *fp, PyObject *filename, int closeit, - PyCompilerFlags *flags) +int +_PyRun_SimpleFileObject(FILE *fp, PyObject *filename, int closeit, + PyCompilerFlags *flags) { PyObject *m, *d, *v; int set_file_name = 0, ret = -1; @@ -404,7 +407,10 @@ pyrun_simple_file(FILE *fp, PyObject *filename, int closeit, return -1; Py_INCREF(m); d = PyModule_GetDict(m); - if (PyDict_GetItemString(d, "__file__") == NULL) { + if (_PyDict_GetItemStringWithError(d, "__file__") == NULL) { + if (PyErr_Occurred()) { + goto done; + } if (PyDict_SetItemString(d, "__file__", filename) < 0) { goto done; } @@ -480,7 +486,7 @@ PyRun_SimpleFileExFlags(FILE *fp, const char *filename, int closeit, if (filename_obj == NULL) { return -1; } - int res = pyrun_simple_file(fp, filename_obj, closeit, flags); + int res = _PyRun_SimpleFileObject(fp, filename_obj, closeit, flags); Py_DECREF(filename_obj); return res; } @@ -505,7 +511,9 @@ PyRun_SimpleStringFlags(const char *command, PyCompilerFlags *flags) static int parse_syntax_error(PyObject *err, PyObject **message, PyObject **filename, - Py_ssize_t *lineno, Py_ssize_t *offset, PyObject **text) + Py_ssize_t *lineno, Py_ssize_t *offset, + Py_ssize_t* end_lineno, Py_ssize_t* end_offset, + PyObject **text) { Py_ssize_t hold; PyObject *v; @@ -513,6 +521,8 @@ parse_syntax_error(PyObject *err, PyObject **message, PyObject **filename, _Py_IDENTIFIER(filename); _Py_IDENTIFIER(lineno); _Py_IDENTIFIER(offset); + _Py_IDENTIFIER(end_lineno); + _Py_IDENTIFIER(end_offset); _Py_IDENTIFIER(text); *message = NULL; @@ -560,6 +570,44 @@ parse_syntax_error(PyObject *err, PyObject **message, PyObject **filename, *offset = hold; } + if (Py_TYPE(err) == (PyTypeObject*)PyExc_SyntaxError) { + v = _PyObject_GetAttrId(err, &PyId_end_lineno); + if (!v) { + PyErr_Clear(); + *end_lineno = *lineno; + } + else if (v == Py_None) { + *end_lineno = *lineno; + Py_DECREF(v); + } else { + hold = PyLong_AsSsize_t(v); + Py_DECREF(v); + if (hold < 0 && PyErr_Occurred()) + goto finally; + *end_lineno = hold; + } + + v = _PyObject_GetAttrId(err, &PyId_end_offset); + if (!v) { + PyErr_Clear(); + *end_offset = -1; + } + else if (v == Py_None) { + *end_offset = -1; + Py_DECREF(v); + } else { + hold = PyLong_AsSsize_t(v); + Py_DECREF(v); + if (hold < 0 && PyErr_Occurred()) + goto finally; + *end_offset = hold; + } + } else { + // SyntaxError subclasses + *end_lineno = *lineno; + *end_offset = -1; + } + v = _PyObject_GetAttrId(err, &PyId_text); if (!v) goto finally; @@ -579,8 +627,9 @@ finally: } static void -print_error_text(PyObject *f, Py_ssize_t offset, PyObject *text_obj) +print_error_text(PyObject *f, Py_ssize_t offset, Py_ssize_t end_offset, PyObject *text_obj) { + size_t caret_repetitions = (end_offset > 0 && end_offset > offset) ? end_offset - offset : 1; /* Convert text to a char pointer; return if error */ const char *text = PyUnicode_AsUTF8(text_obj); if (text == NULL) @@ -640,7 +689,10 @@ print_error_text(PyObject *f, Py_ssize_t offset, PyObject *text_obj) while (--offset >= 0) { PyFile_WriteString(" ", f); } - PyFile_WriteString("^\n", f); + for (size_t caret_iter=0; caret_iter < caret_repetitions ; caret_iter++) { + PyFile_WriteString("^", f); + } + PyFile_WriteString("\n", f); } @@ -838,7 +890,7 @@ static void print_exception(PyObject *f, PyObject *value) { int err = 0; - PyObject *type, *tb; + PyObject *type, *tb, *tmp; _Py_IDENTIFIER(print_file_and_line); if (!PyExceptionInstance_Check(value)) { @@ -857,12 +909,15 @@ print_exception(PyObject *f, PyObject *value) if (tb && tb != Py_None) err = PyTraceBack_Print(tb, f); if (err == 0 && - _PyObject_HasAttrId(value, &PyId_print_file_and_line)) + (err = _PyObject_LookupAttrId(value, &PyId_print_file_and_line, &tmp)) > 0) { PyObject *message, *filename, *text; - Py_ssize_t lineno, offset; + Py_ssize_t lineno, offset, end_lineno, end_offset; + err = 0; + Py_DECREF(tmp); if (!parse_syntax_error(value, &message, &filename, - &lineno, &offset, &text)) + &lineno, &offset, + &end_lineno, &end_offset, &text)) PyErr_Clear(); else { PyObject *line; @@ -879,7 +934,21 @@ print_exception(PyObject *f, PyObject *value) } if (text != NULL) { - print_error_text(f, offset, text); + Py_ssize_t line_size; + const char* error_line = PyUnicode_AsUTF8AndSize(text, &line_size); + // If the location of the error spawn multiple lines, we want + // to just print the first one and highlight everything until + // the end of that one since we don't support multi-line error + // messages. + if (end_lineno > lineno) { + end_offset = (error_line != NULL) ? line_size : -1; + } + // Limit the amount of '^' that we can display to + // the size of the text in the source line. + if (error_line != NULL && end_offset > line_size + 1) { + end_offset = line_size + 1; + } + print_error_text(f, offset, end_offset, text); Py_DECREF(text); } @@ -947,6 +1016,18 @@ print_exception(PyObject *f, PyObject *value) if (err < 0) { PyErr_Clear(); } + PyObject* suggestions = _Py_Offer_Suggestions(value); + if (suggestions) { + // Add a trailer ". Did you mean: (...)?" + err = PyFile_WriteString(". Did you mean: '", f); + if (err == 0) { + err = PyFile_WriteObject(suggestions, f, Py_PRINT_RAW); + err += PyFile_WriteString("'?", f); + } + Py_DECREF(suggestions); + } else if (PyErr_Occurred()) { + PyErr_Clear(); + } err += PyFile_WriteString("\n", f); Py_XDECREF(tb); Py_DECREF(value); @@ -1087,26 +1168,20 @@ PyRun_StringFlags(const char *str, int start, PyObject *globals, mod_ty mod; PyArena *arena; PyObject *filename; - int use_peg = _PyInterpreterState_GET()->config._use_peg_parser; filename = _PyUnicode_FromId(&PyId_string); /* borrowed */ if (filename == NULL) return NULL; - arena = PyArena_New(); + arena = _PyArena_New(); if (arena == NULL) return NULL; - if (use_peg) { - mod = PyPegen_ASTFromStringObject(str, filename, start, flags, arena); - } - else { - mod = PyParser_ASTFromStringObject(str, filename, start, flags, arena); - } + mod = _PyParser_ASTFromString(str, filename, start, flags, arena); if (mod != NULL) ret = run_mod(mod, filename, globals, locals, flags, arena); - PyArena_Free(arena); + _PyArena_Free(arena); return ret; } @@ -1115,21 +1190,14 @@ static PyObject * pyrun_file(FILE *fp, PyObject *filename, int start, PyObject *globals, PyObject *locals, int closeit, PyCompilerFlags *flags) { - PyArena *arena = PyArena_New(); + PyArena *arena = _PyArena_New(); if (arena == NULL) { return NULL; } mod_ty mod; - int use_peg = _PyInterpreterState_GET()->config._use_peg_parser; - if (use_peg) { - mod = PyPegen_ASTFromFileObject(fp, filename, start, NULL, NULL, NULL, - flags, NULL, arena); - } - else { - mod = PyParser_ASTFromFileObject(fp, filename, NULL, start, 0, 0, - flags, NULL, arena); - } + mod = _PyParser_ASTFromFile(fp, filename, NULL, start, NULL, NULL, + flags, NULL, arena); if (closeit) { fclose(fp); @@ -1142,7 +1210,7 @@ pyrun_file(FILE *fp, PyObject *filename, int start, PyObject *globals, else { ret = NULL; } - PyArena_Free(arena); + _PyArena_Free(arena); return ret; } @@ -1211,9 +1279,11 @@ run_eval_code_obj(PyThreadState *tstate, PyCodeObject *co, PyObject *globals, Py _Py_UnhandledKeyboardInterrupt = 0; /* Set globals['__builtins__'] if it doesn't exist */ - if (globals != NULL && PyDict_GetItemString(globals, "__builtins__") == NULL) { - if (PyDict_SetItemString(globals, "__builtins__", - tstate->interp->builtins) < 0) { + if (globals != NULL && _PyDict_GetItemStringWithError(globals, "__builtins__") == NULL) { + if (PyErr_Occurred() || + PyDict_SetItemString(globals, "__builtins__", + tstate->interp->builtins) < 0) + { return NULL; } } @@ -1230,7 +1300,7 @@ run_mod(mod_ty mod, PyObject *filename, PyObject *globals, PyObject *locals, PyCompilerFlags *flags, PyArena *arena) { PyThreadState *tstate = _PyThreadState_GET(); - PyCodeObject *co = PyAST_CompileObject(mod, filename, flags, -1, arena); + PyCodeObject *co = _PyAST_Compile(mod, filename, flags, -1, arena); if (co == NULL) return NULL; @@ -1293,28 +1363,22 @@ Py_CompileStringObject(const char *str, PyObject *filename, int start, { PyCodeObject *co; mod_ty mod; - int use_peg = _PyInterpreterState_GET()->config._use_peg_parser; - PyArena *arena = PyArena_New(); + PyArena *arena = _PyArena_New(); if (arena == NULL) return NULL; - if (use_peg) { - mod = PyPegen_ASTFromStringObject(str, filename, start, flags, arena); - } - else { - mod = PyParser_ASTFromStringObject(str, filename, start, flags, arena); - } + mod = _PyParser_ASTFromString(str, filename, start, flags, arena); if (mod == NULL) { - PyArena_Free(arena); + _PyArena_Free(arena); return NULL; } if (flags && (flags->cf_flags & PyCF_ONLY_AST)) { PyObject *result = PyAST_mod2obj(mod); - PyArena_Free(arena); + _PyArena_Free(arena); return result; } - co = PyAST_CompileObject(mod, filename, flags, optimize, arena); - PyArena_Free(arena); + co = _PyAST_Compile(mod, filename, flags, optimize, arena); + _PyArena_Free(arena); return (PyObject *)co; } @@ -1331,14 +1395,6 @@ Py_CompileStringExFlags(const char *str, const char *filename_str, int start, return co; } -/* For use in Py_LIMITED_API */ -#undef Py_CompileString -PyObject * -PyCompileString(const char *str, const char *filename, int start) -{ - return Py_CompileStringFlags(str, filename, start, NULL); -} - const char * _Py_SourceAsString(PyObject *cmd, const char *funcname, const char *what, PyCompilerFlags *cf, PyObject **cmd_copy) { @@ -1388,339 +1444,6 @@ _Py_SourceAsString(PyObject *cmd, const char *funcname, const char *what, PyComp return str; } -struct symtable * -Py_SymtableStringObject(const char *str, PyObject *filename, int start) -{ - PyCompilerFlags flags = _PyCompilerFlags_INIT; - return _Py_SymtableStringObjectFlags(str, filename, start, &flags); -} - -struct symtable * -_Py_SymtableStringObjectFlags(const char *str, PyObject *filename, int start, PyCompilerFlags *flags) -{ - struct symtable *st; - mod_ty mod; - int use_peg = _PyInterpreterState_GET()->config._use_peg_parser; - PyArena *arena; - - arena = PyArena_New(); - if (arena == NULL) - return NULL; - - if (use_peg) { - mod = PyPegen_ASTFromStringObject(str, filename, start, flags, arena); - } - else { - mod = PyParser_ASTFromStringObject(str, filename, start, flags, arena); - } - if (mod == NULL) { - PyArena_Free(arena); - return NULL; - } - st = PySymtable_BuildObject(mod, filename, 0); - PyArena_Free(arena); - return st; -} - -struct symtable * -Py_SymtableString(const char *str, const char *filename_str, int start) -{ - PyObject *filename; - struct symtable *st; - - filename = PyUnicode_DecodeFSDefault(filename_str); - if (filename == NULL) - return NULL; - st = Py_SymtableStringObject(str, filename, start); - Py_DECREF(filename); - return st; -} - -/* Preferred access to parser is through AST. */ -mod_ty -PyParser_ASTFromStringObject(const char *s, PyObject *filename, int start, - PyCompilerFlags *flags, PyArena *arena) -{ - mod_ty mod; - PyCompilerFlags localflags = _PyCompilerFlags_INIT; - perrdetail err; - int iflags = PARSER_FLAGS(flags); - if (flags && (flags->cf_flags & PyCF_ONLY_AST) && flags->cf_feature_version < 7) - iflags |= PyPARSE_ASYNC_HACKS; - - node *n = PyParser_ParseStringObject(s, filename, - &_PyParser_Grammar, start, &err, - &iflags); - if (flags == NULL) { - flags = &localflags; - } - if (n) { - flags->cf_flags |= iflags & PyCF_MASK; - mod = PyAST_FromNodeObject(n, flags, filename, arena); - PyNode_Free(n); - } - else { - err_input(&err); - mod = NULL; - } - err_free(&err); - return mod; -} - -mod_ty -PyParser_ASTFromString(const char *s, const char *filename_str, int start, - PyCompilerFlags *flags, PyArena *arena) -{ - PyObject *filename; - mod_ty mod; - filename = PyUnicode_DecodeFSDefault(filename_str); - if (filename == NULL) - return NULL; - mod = PyParser_ASTFromStringObject(s, filename, start, flags, arena); - Py_DECREF(filename); - return mod; -} - -mod_ty -PyParser_ASTFromFileObject(FILE *fp, PyObject *filename, const char* enc, - int start, const char *ps1, - const char *ps2, PyCompilerFlags *flags, int *errcode, - PyArena *arena) -{ - mod_ty mod; - PyCompilerFlags localflags = _PyCompilerFlags_INIT; - perrdetail err; - int iflags = PARSER_FLAGS(flags); - - node *n = PyParser_ParseFileObject(fp, filename, enc, - &_PyParser_Grammar, - start, ps1, ps2, &err, &iflags); - if (flags == NULL) { - flags = &localflags; - } - if (n) { - flags->cf_flags |= iflags & PyCF_MASK; - mod = PyAST_FromNodeObject(n, flags, filename, arena); - PyNode_Free(n); - } - else { - err_input(&err); - if (errcode) - *errcode = err.error; - mod = NULL; - } - err_free(&err); - return mod; -} - -mod_ty -PyParser_ASTFromFile(FILE *fp, const char *filename_str, const char* enc, - int start, const char *ps1, - const char *ps2, PyCompilerFlags *flags, int *errcode, - PyArena *arena) -{ - mod_ty mod; - PyObject *filename; - filename = PyUnicode_DecodeFSDefault(filename_str); - if (filename == NULL) - return NULL; - mod = PyParser_ASTFromFileObject(fp, filename, enc, start, ps1, ps2, - flags, errcode, arena); - Py_DECREF(filename); - return mod; -} - -/* Simplified interface to parsefile -- return node or set exception */ - -node * -PyParser_SimpleParseFileFlags(FILE *fp, const char *filename, int start, int flags) -{ - perrdetail err; - node *n = PyParser_ParseFileFlags(fp, filename, NULL, - &_PyParser_Grammar, - start, NULL, NULL, &err, flags); - if (n == NULL) - err_input(&err); - err_free(&err); - - return n; -} - -/* Simplified interface to parsestring -- return node or set exception */ - -node * -PyParser_SimpleParseStringFlags(const char *str, int start, int flags) -{ - perrdetail err; - node *n = PyParser_ParseStringFlags(str, &_PyParser_Grammar, - start, &err, flags); - if (n == NULL) - err_input(&err); - err_free(&err); - return n; -} - -node * -PyParser_SimpleParseStringFlagsFilename(const char *str, const char *filename, - int start, int flags) -{ - perrdetail err; - node *n = PyParser_ParseStringFlagsFilename(str, filename, - &_PyParser_Grammar, start, &err, flags); - if (n == NULL) - err_input(&err); - err_free(&err); - return n; -} - -/* May want to move a more generalized form of this to parsetok.c or - even parser modules. */ - -void -PyParser_ClearError(perrdetail *err) -{ - err_free(err); -} - -void -PyParser_SetError(perrdetail *err) -{ - err_input(err); -} - -static void -err_free(perrdetail *err) -{ - Py_CLEAR(err->filename); -} - -/* Set the error appropriate to the given input error code (see errcode.h) */ - -static void -err_input(perrdetail *err) -{ - PyObject *v, *w, *errtype, *errtext; - PyObject *msg_obj = NULL; - const char *msg = NULL; - int offset = err->offset; - - errtype = PyExc_SyntaxError; - switch (err->error) { - case E_ERROR: - goto cleanup; - case E_SYNTAX: - errtype = PyExc_IndentationError; - if (err->expected == INDENT) - msg = "expected an indented block"; - else if (err->token == INDENT) - msg = "unexpected indent"; - else if (err->token == DEDENT) - msg = "unexpected unindent"; - else if (err->expected == NOTEQUAL) { - errtype = PyExc_SyntaxError; - msg = "with Barry as BDFL, use '<>' instead of '!='"; - } - else { - errtype = PyExc_SyntaxError; - msg = "invalid syntax"; - } - break; - case E_TOKEN: - msg = "invalid token"; - break; - case E_EOFS: - msg = "EOF while scanning triple-quoted string literal"; - break; - case E_EOLS: - msg = "EOL while scanning string literal"; - break; - case E_INTR: - if (!PyErr_Occurred()) - PyErr_SetNone(PyExc_KeyboardInterrupt); - goto cleanup; - case E_NOMEM: - PyErr_NoMemory(); - goto cleanup; - case E_EOF: - msg = "unexpected EOF while parsing"; - break; - case E_TABSPACE: - errtype = PyExc_TabError; - msg = "inconsistent use of tabs and spaces in indentation"; - break; - case E_OVERFLOW: - msg = "expression too long"; - break; - case E_DEDENT: - errtype = PyExc_IndentationError; - msg = "unindent does not match any outer indentation level"; - break; - case E_TOODEEP: - errtype = PyExc_IndentationError; - msg = "too many levels of indentation"; - break; - case E_DECODE: { - PyObject *type, *value, *tb; - PyErr_Fetch(&type, &value, &tb); - msg = "unknown decode error"; - if (value != NULL) - msg_obj = PyObject_Str(value); - Py_XDECREF(type); - Py_XDECREF(value); - Py_XDECREF(tb); - break; - } - case E_LINECONT: - msg = "unexpected character after line continuation character"; - break; - - case E_BADSINGLE: - msg = "multiple statements found while compiling a single statement"; - break; - default: - fprintf(stderr, "error=%d\n", err->error); - msg = "unknown parsing error"; - break; - } - /* err->text may not be UTF-8 in case of decoding errors. - Explicitly convert to an object. */ - if (!err->text) { - errtext = Py_None; - Py_INCREF(Py_None); - } else { - errtext = PyUnicode_DecodeUTF8(err->text, err->offset, - "replace"); - if (errtext != NULL) { - Py_ssize_t len = strlen(err->text); - offset = (int)PyUnicode_GET_LENGTH(errtext); - if (len != err->offset) { - Py_DECREF(errtext); - errtext = PyUnicode_DecodeUTF8(err->text, len, - "replace"); - } - } - } - v = Py_BuildValue("(OiiN)", err->filename, - err->lineno, offset, errtext); - if (v != NULL) { - if (msg_obj) - w = Py_BuildValue("(OO)", msg_obj, v); - else - w = Py_BuildValue("(sO)", msg, v); - } else - w = NULL; - Py_XDECREF(v); - PyErr_SetObject(errtype, w); - Py_XDECREF(w); -cleanup: - Py_XDECREF(msg_obj); - if (err->text != NULL) { - PyObject_FREE(err->text); - err->text = NULL; - } -} - - #if defined(USE_STACKCHECK) #if defined(WIN32) && defined(_MSC_VER) @@ -1760,20 +1483,6 @@ PyOS_CheckStack(void) /* Deprecated C API functions still provided for binary compatibility */ -#undef PyParser_SimpleParseFile -PyAPI_FUNC(node *) -PyParser_SimpleParseFile(FILE *fp, const char *filename, int start) -{ - return PyParser_SimpleParseFileFlags(fp, filename, start, 0); -} - -#undef PyParser_SimpleParseString -PyAPI_FUNC(node *) -PyParser_SimpleParseString(const char *str, int start) -{ - return PyParser_SimpleParseStringFlags(str, start, 0); -} - #undef PyRun_AnyFile PyAPI_FUNC(int) PyRun_AnyFile(FILE *fp, const char *name) diff --git a/contrib/tools/python3/src/Python/pytime.c b/contrib/tools/python3/src/Python/pytime.c index a9af7572431..1ef99aee748 100644 --- a/contrib/tools/python3/src/Python/pytime.c +++ b/contrib/tools/python3/src/Python/pytime.c @@ -304,8 +304,8 @@ pytime_fromtimespec(_PyTime_t *tp, struct timespec *ts, int raise) if (_PyTime_check_mul_overflow(t, SEC_TO_NS)) { if (raise) { _PyTime_overflow(); + res = -1; } - res = -1; t = (t > 0) ? _PyTime_MAX : _PyTime_MIN; } else { @@ -318,8 +318,8 @@ pytime_fromtimespec(_PyTime_t *tp, struct timespec *ts, int raise) if (t > _PyTime_MAX - nsec) { if (raise) { _PyTime_overflow(); + res = -1; } - res = -1; t = _PyTime_MAX; } else { @@ -350,8 +350,8 @@ pytime_fromtimeval(_PyTime_t *tp, struct timeval *tv, int raise) if (_PyTime_check_mul_overflow(t, SEC_TO_NS)) { if (raise) { _PyTime_overflow(); + res = -1; } - res = -1; t = (t > 0) ? _PyTime_MAX : _PyTime_MIN; } else { @@ -364,8 +364,8 @@ pytime_fromtimeval(_PyTime_t *tp, struct timeval *tv, int raise) if (t > _PyTime_MAX - usec) { if (raise) { _PyTime_overflow(); + res = -1; } - res = -1; t = _PyTime_MAX; } else { @@ -656,7 +656,7 @@ _PyTime_AsTimespec(_PyTime_t t, struct timespec *ts) #endif static int -pygettimeofday(_PyTime_t *tp, _Py_clock_info_t *info, int raise) +py_get_system_clock(_PyTime_t *tp, _Py_clock_info_t *info, int raise) { #ifdef MS_WINDOWS FILETIME system_time; @@ -769,9 +769,10 @@ _PyTime_t _PyTime_GetSystemClock(void) { _PyTime_t t; - if (pygettimeofday(&t, NULL, 0) < 0) { - /* should not happen, _PyTime_Init() checked the clock at startup */ - Py_FatalError("pygettimeofday() failed"); + if (py_get_system_clock(&t, NULL, 0) < 0) { + // If clock_gettime(CLOCK_REALTIME) or gettimeofday() fails: + // silently ignore the failure and return 0. + t = 0; } return t; } @@ -779,11 +780,61 @@ _PyTime_GetSystemClock(void) int _PyTime_GetSystemClockWithInfo(_PyTime_t *t, _Py_clock_info_t *info) { - return pygettimeofday(t, info, 1); + return py_get_system_clock(t, info, 1); } +#if __APPLE__ static int -pymonotonic(_PyTime_t *tp, _Py_clock_info_t *info, int raise) +py_mach_timebase_info(_PyTime_t *pnumer, _PyTime_t *pdenom, int raise) +{ + static mach_timebase_info_data_t timebase; + /* According to the Technical Q&A QA1398, mach_timebase_info() cannot + fail: https://developer.apple.com/library/mac/#qa/qa1398/ */ + (void)mach_timebase_info(&timebase); + + /* Sanity check: should never occur in practice */ + if (timebase.numer < 1 || timebase.denom < 1) { + if (raise) { + PyErr_SetString(PyExc_RuntimeError, + "invalid mach_timebase_info"); + } + return -1; + } + + /* Check that timebase.numer and timebase.denom can be casted to + _PyTime_t. In practice, timebase uses uint32_t, so casting cannot + overflow. At the end, only make sure that the type is uint32_t + (_PyTime_t is 64-bit long). */ + Py_BUILD_ASSERT(sizeof(timebase.numer) < sizeof(_PyTime_t)); + Py_BUILD_ASSERT(sizeof(timebase.denom) < sizeof(_PyTime_t)); + + /* Make sure that (ticks * timebase.numer) cannot overflow in + _PyTime_MulDiv(), with ticks < timebase.denom. + + Known time bases: + + * always (1, 1) on Intel + * (1000000000, 33333335) or (1000000000, 25000000) on PowerPC + + None of these time bases can overflow with 64-bit _PyTime_t, but + check for overflow, just in case. */ + if ((_PyTime_t)timebase.numer > _PyTime_MAX / (_PyTime_t)timebase.denom) { + if (raise) { + PyErr_SetString(PyExc_OverflowError, + "mach_timebase_info is too large"); + } + return -1; + } + + *pnumer = (_PyTime_t)timebase.numer; + *pdenom = (_PyTime_t)timebase.denom; + return 0; +} +#endif + + +static int +py_get_monotonic_clock(_PyTime_t *tp, _Py_clock_info_t *info, int raise) { #if defined(MS_WINDOWS) ULONGLONG ticks; @@ -800,10 +851,12 @@ pymonotonic(_PyTime_t *tp, _Py_clock_info_t *info, int raise) _PyTime_overflow(); return -1; } - /* Hello, time traveler! */ - Py_FatalError("pymonotonic: integer overflow"); + // Truncate to _PyTime_MAX silently. + *tp = _PyTime_MAX; + } + else { + *tp = t * MS_TO_NS; } - *tp = t * MS_TO_NS; if (info) { DWORD timeAdjustment, timeIncrement; @@ -821,62 +874,23 @@ pymonotonic(_PyTime_t *tp, _Py_clock_info_t *info, int raise) } #elif defined(__APPLE__) - static mach_timebase_info_data_t timebase; - static uint64_t t0 = 0; - uint64_t ticks; - - if (timebase.denom == 0) { - /* According to the Technical Q&A QA1398, mach_timebase_info() cannot - fail: https://developer.apple.com/library/mac/#qa/qa1398/ */ - (void)mach_timebase_info(&timebase); - - /* Sanity check: should never occur in practice */ - if (timebase.numer < 1 || timebase.denom < 1) { - PyErr_SetString(PyExc_RuntimeError, - "invalid mach_timebase_info"); - return -1; - } - - /* Check that timebase.numer and timebase.denom can be casted to - _PyTime_t. In practice, timebase uses uint32_t, so casting cannot - overflow. At the end, only make sure that the type is uint32_t - (_PyTime_t is 64-bit long). */ - assert(sizeof(timebase.numer) < sizeof(_PyTime_t)); - assert(sizeof(timebase.denom) < sizeof(_PyTime_t)); - - /* Make sure that (ticks * timebase.numer) cannot overflow in - _PyTime_MulDiv(), with ticks < timebase.denom. - - Known time bases: - - * always (1, 1) on Intel - * (1000000000, 33333335) or (1000000000, 25000000) on PowerPC - - None of these time bases can overflow with 64-bit _PyTime_t, but - check for overflow, just in case. */ - if ((_PyTime_t)timebase.numer > _PyTime_MAX / (_PyTime_t)timebase.denom) { - PyErr_SetString(PyExc_OverflowError, - "mach_timebase_info is too large"); + static _PyTime_t timebase_numer = 0; + static _PyTime_t timebase_denom = 0; + if (timebase_denom == 0) { + if (py_mach_timebase_info(&timebase_numer, &timebase_denom, raise) < 0) { return -1; } - - t0 = mach_absolute_time(); } if (info) { info->implementation = "mach_absolute_time()"; - info->resolution = (double)timebase.numer / (double)timebase.denom * 1e-9; + info->resolution = (double)timebase_numer / (double)timebase_denom * 1e-9; info->monotonic = 1; info->adjustable = 0; } - ticks = mach_absolute_time(); - /* Use a "time zero" to reduce precision loss when converting time - to floatting point number, as in time.monotonic(). */ - ticks -= t0; - *tp = _PyTime_MulDiv(ticks, - (_PyTime_t)timebase.numer, - (_PyTime_t)timebase.denom); + uint64_t ticks = mach_absolute_time(); + *tp = _PyTime_MulDiv((_PyTime_t)ticks, timebase_numer, timebase_denom); #elif defined(__hpux) hrtime_t time; @@ -940,10 +954,10 @@ _PyTime_t _PyTime_GetMonotonicClock(void) { _PyTime_t t; - if (pymonotonic(&t, NULL, 0) < 0) { - /* should not happen, _PyTime_Init() checked that monotonic clock at - startup */ - Py_FatalError("pymonotonic() failed"); + if (py_get_monotonic_clock(&t, NULL, 0) < 0) { + // If mach_timebase_info(), clock_gettime() or gethrtime() fails: + // silently ignore the failure and return 0. + t = 0; } return t; } @@ -951,56 +965,69 @@ _PyTime_GetMonotonicClock(void) int _PyTime_GetMonotonicClockWithInfo(_PyTime_t *tp, _Py_clock_info_t *info) { - return pymonotonic(tp, info, 1); + return py_get_monotonic_clock(tp, info, 1); } #ifdef MS_WINDOWS static int -win_perf_counter(_PyTime_t *tp, _Py_clock_info_t *info) +win_perf_counter_frequency(LONGLONG *pfrequency, int raise) { - static LONGLONG frequency = 0; - static LONGLONG t0 = 0; - LARGE_INTEGER now; - LONGLONG ticksll; - _PyTime_t ticks; + LONGLONG frequency; - if (frequency == 0) { - LARGE_INTEGER freq; - if (!QueryPerformanceFrequency(&freq)) { + LARGE_INTEGER freq; + if (!QueryPerformanceFrequency(&freq)) { + if (raise) { PyErr_SetFromWindowsErr(0); - return -1; } - frequency = freq.QuadPart; + return -1; + } + frequency = freq.QuadPart; - /* Sanity check: should never occur in practice */ - if (frequency < 1) { + /* Sanity check: should never occur in practice */ + if (frequency < 1) { + if (raise) { PyErr_SetString(PyExc_RuntimeError, "invalid QueryPerformanceFrequency"); - return -1; } + return -1; + } - /* Check that frequency can be casted to _PyTime_t. + /* Check that frequency can be casted to _PyTime_t. - Make also sure that (ticks * SEC_TO_NS) cannot overflow in - _PyTime_MulDiv(), with ticks < frequency. + Make also sure that (ticks * SEC_TO_NS) cannot overflow in + _PyTime_MulDiv(), with ticks < frequency. - Known QueryPerformanceFrequency() values: + Known QueryPerformanceFrequency() values: - * 10,000,000 (10 MHz): 100 ns resolution - * 3,579,545 Hz (3.6 MHz): 279 ns resolution + * 10,000,000 (10 MHz): 100 ns resolution + * 3,579,545 Hz (3.6 MHz): 279 ns resolution - None of these frequencies can overflow with 64-bit _PyTime_t, but - check for overflow, just in case. */ - if (frequency > _PyTime_MAX - || frequency > (LONGLONG)_PyTime_MAX / (LONGLONG)SEC_TO_NS) { + None of these frequencies can overflow with 64-bit _PyTime_t, but + check for overflow, just in case. */ + if (frequency > _PyTime_MAX + || frequency > (LONGLONG)_PyTime_MAX / (LONGLONG)SEC_TO_NS) + { + if (raise) { PyErr_SetString(PyExc_OverflowError, "QueryPerformanceFrequency is too large"); - return -1; } + return -1; + } - QueryPerformanceCounter(&now); - t0 = now.QuadPart; + *pfrequency = frequency; + return 0; +} + + +static int +py_get_win_perf_counter(_PyTime_t *tp, _Py_clock_info_t *info, int raise) +{ + static LONGLONG frequency = 0; + if (frequency == 0) { + if (win_perf_counter_frequency(&frequency, raise) < 0) { + return -1; + } } if (info) { @@ -1010,15 +1037,13 @@ win_perf_counter(_PyTime_t *tp, _Py_clock_info_t *info) info->adjustable = 0; } + LARGE_INTEGER now; QueryPerformanceCounter(&now); - ticksll = now.QuadPart; - - /* Use a "time zero" to reduce precision loss when converting time - to floatting point number, as in time.perf_counter(). */ - ticksll -= t0; + LONGLONG ticksll = now.QuadPart; /* Make sure that casting LONGLONG to _PyTime_t cannot overflow, both types are signed */ + _PyTime_t ticks; Py_BUILD_ASSERT(sizeof(ticksll) <= sizeof(ticks)); ticks = (_PyTime_t)ticksll; @@ -1032,7 +1057,7 @@ int _PyTime_GetPerfCounterWithInfo(_PyTime_t *t, _Py_clock_info_t *info) { #ifdef MS_WINDOWS - return win_perf_counter(t, info); + return py_get_win_perf_counter(t, info, 1); #else return _PyTime_GetMonotonicClockWithInfo(t, info); #endif @@ -1043,33 +1068,22 @@ _PyTime_t _PyTime_GetPerfCounter(void) { _PyTime_t t; - if (_PyTime_GetPerfCounterWithInfo(&t, NULL)) { - Py_FatalError("_PyTime_GetPerfCounterWithInfo() failed"); + int res; +#ifdef MS_WINDOWS + res = py_get_win_perf_counter(&t, NULL, 0); +#else + res = py_get_monotonic_clock(&t, NULL, 0); +#endif + if (res < 0) { + // If win_perf_counter_frequency() or py_get_monotonic_clock() fails: + // silently ignore the failure and return 0. + t = 0; } return t; } int -_PyTime_Init(void) -{ - /* check that time.time(), time.monotonic() and time.perf_counter() clocks - are working properly to not have to check for exceptions at runtime. If - a clock works once, it cannot fail in next calls. */ - _PyTime_t t; - if (_PyTime_GetSystemClockWithInfo(&t, NULL) < 0) { - return -1; - } - if (_PyTime_GetMonotonicClockWithInfo(&t, NULL) < 0) { - return -1; - } - if (_PyTime_GetPerfCounterWithInfo(&t, NULL) < 0) { - return -1; - } - return 0; -} - -int _PyTime_localtime(time_t t, struct tm *tm) { #ifdef MS_WINDOWS diff --git a/contrib/tools/python3/src/Python/stdlib_module_names.h b/contrib/tools/python3/src/Python/stdlib_module_names.h new file mode 100644 index 00000000000..50cf340e543 --- /dev/null +++ b/contrib/tools/python3/src/Python/stdlib_module_names.h @@ -0,0 +1,308 @@ +// Auto-generated by Tools/scripts/generate_stdlib_module_names.py. +// List used to create sys.stdlib_module_names. + +static const char* _Py_stdlib_module_names[] = { +"__future__", +"_abc", +"_aix_support", +"_ast", +"_asyncio", +"_bisect", +"_blake2", +"_bootsubprocess", +"_bz2", +"_codecs", +"_codecs_cn", +"_codecs_hk", +"_codecs_iso2022", +"_codecs_jp", +"_codecs_kr", +"_codecs_tw", +"_collections", +"_collections_abc", +"_compat_pickle", +"_compression", +"_contextvars", +"_crypt", +"_csv", +"_ctypes", +"_curses", +"_curses_panel", +"_datetime", +"_dbm", +"_decimal", +"_elementtree", +"_frozen_importlib", +"_frozen_importlib_external", +"_functools", +"_gdbm", +"_hashlib", +"_heapq", +"_imp", +"_io", +"_json", +"_locale", +"_lsprof", +"_lzma", +"_markupbase", +"_md5", +"_msi", +"_multibytecodec", +"_multiprocessing", +"_opcode", +"_operator", +"_osx_support", +"_overlapped", +"_pickle", +"_posixshmem", +"_posixsubprocess", +"_py_abc", +"_pydecimal", +"_pyio", +"_queue", +"_random", +"_scproxy", +"_sha1", +"_sha256", +"_sha3", +"_sha512", +"_signal", +"_sitebuiltins", +"_socket", +"_sqlite3", +"_sre", +"_ssl", +"_stat", +"_statistics", +"_string", +"_strptime", +"_struct", +"_symtable", +"_thread", +"_threading_local", +"_tkinter", +"_tracemalloc", +"_uuid", +"_warnings", +"_weakref", +"_weakrefset", +"_winapi", +"_zoneinfo", +"abc", +"aifc", +"antigravity", +"argparse", +"array", +"ast", +"asynchat", +"asyncio", +"asyncore", +"atexit", +"audioop", +"base64", +"bdb", +"binascii", +"binhex", +"bisect", +"builtins", +"bz2", +"cProfile", +"calendar", +"cgi", +"cgitb", +"chunk", +"cmath", +"cmd", +"code", +"codecs", +"codeop", +"collections", +"colorsys", +"compileall", +"concurrent", +"configparser", +"contextlib", +"contextvars", +"copy", +"copyreg", +"crypt", +"csv", +"ctypes", +"curses", +"dataclasses", +"datetime", +"dbm", +"decimal", +"difflib", +"dis", +"distutils", +"doctest", +"email", +"encodings", +"ensurepip", +"enum", +"errno", +"faulthandler", +"fcntl", +"filecmp", +"fileinput", +"fnmatch", +"fractions", +"ftplib", +"functools", +"gc", +"genericpath", +"getopt", +"getpass", +"gettext", +"glob", +"graphlib", +"grp", +"gzip", +"hashlib", +"heapq", +"hmac", +"html", +"http", +"idlelib", +"imaplib", +"imghdr", +"imp", +"importlib", +"inspect", +"io", +"ipaddress", +"itertools", +"json", +"keyword", +"lib2to3", +"linecache", +"locale", +"logging", +"lzma", +"mailbox", +"mailcap", +"marshal", +"math", +"mimetypes", +"mmap", +"modulefinder", +"msilib", +"msvcrt", +"multiprocessing", +"netrc", +"nis", +"nntplib", +"nt", +"ntpath", +"nturl2path", +"numbers", +"opcode", +"operator", +"optparse", +"os", +"ossaudiodev", +"pathlib", +"pdb", +"pickle", +"pickletools", +"pipes", +"pkgutil", +"platform", +"plistlib", +"poplib", +"posix", +"posixpath", +"pprint", +"profile", +"pstats", +"pty", +"pwd", +"py_compile", +"pyclbr", +"pydoc", +"pydoc_data", +"pyexpat", +"queue", +"quopri", +"random", +"re", +"readline", +"reprlib", +"resource", +"rlcompleter", +"runpy", +"sched", +"secrets", +"select", +"selectors", +"shelve", +"shlex", +"shutil", +"signal", +"site", +"smtpd", +"smtplib", +"sndhdr", +"socket", +"socketserver", +"spwd", +"sqlite3", +"sre_compile", +"sre_constants", +"sre_parse", +"ssl", +"stat", +"statistics", +"string", +"stringprep", +"struct", +"subprocess", +"sunau", +"symtable", +"sys", +"sysconfig", +"syslog", +"tabnanny", +"tarfile", +"telnetlib", +"tempfile", +"termios", +"textwrap", +"this", +"threading", +"time", +"timeit", +"tkinter", +"token", +"tokenize", +"trace", +"traceback", +"tracemalloc", +"tty", +"turtle", +"turtledemo", +"types", +"typing", +"unicodedata", +"unittest", +"urllib", +"uu", +"uuid", +"venv", +"warnings", +"wave", +"weakref", +"webbrowser", +"winreg", +"winsound", +"wsgiref", +"xdrlib", +"xml", +"xmlrpc", +"zipapp", +"zipfile", +"zipimport", +"zlib", +"zoneinfo", +}; diff --git a/contrib/tools/python3/src/Python/structmember.c b/contrib/tools/python3/src/Python/structmember.c index ba88e15f938..c7e318811d8 100644 --- a/contrib/tools/python3/src/Python/structmember.c +++ b/contrib/tools/python3/src/Python/structmember.c @@ -5,11 +5,11 @@ #include "structmember.h" // PyMemberDef PyObject * -PyMember_GetOne(const char *addr, PyMemberDef *l) +PyMember_GetOne(const char *obj_addr, PyMemberDef *l) { PyObject *v; - addr += l->offset; + const char* addr = obj_addr + l->offset; switch (l->type) { case T_BOOL: v = PyBool_FromLong(*(char*)addr); @@ -69,8 +69,13 @@ PyMember_GetOne(const char *addr, PyMemberDef *l) break; case T_OBJECT_EX: v = *(PyObject **)addr; - if (v == NULL) - PyErr_SetString(PyExc_AttributeError, l->name); + if (v == NULL) { + PyObject *obj = (PyObject *)obj_addr; + PyTypeObject *tp = Py_TYPE(obj); + PyErr_Format(PyExc_AttributeError, + "'%.200s' object has no attribute '%s'", + tp->tp_name, l->name); + } Py_XINCREF(v); break; case T_LONGLONG: diff --git a/contrib/tools/python3/src/Python/suggestions.c b/contrib/tools/python3/src/Python/suggestions.c new file mode 100644 index 00000000000..4e2f9055779 --- /dev/null +++ b/contrib/tools/python3/src/Python/suggestions.c @@ -0,0 +1,289 @@ +#include "Python.h" +#include "frameobject.h" + +#include "pycore_pyerrors.h" + +#define MAX_CANDIDATE_ITEMS 750 +#define MAX_STRING_SIZE 40 + +#define MOVE_COST 2 +#define CASE_COST 1 + +#define LEAST_FIVE_BITS(n) ((n) & 31) + +static inline int +substitution_cost(char a, char b) +{ + if (LEAST_FIVE_BITS(a) != LEAST_FIVE_BITS(b)) { + // Not the same, not a case flip. + return MOVE_COST; + } + if (a == b) { + return 0; + } + if ('A' <= a && a <= 'Z') { + a += ('a' - 'A'); + } + if ('A' <= b && b <= 'Z') { + b += ('a' - 'A'); + } + if (a == b) { + return CASE_COST; + } + return MOVE_COST; +} + +/* Calculate the Levenshtein distance between string1 and string2 */ +static Py_ssize_t +levenshtein_distance(const char *a, size_t a_size, + const char *b, size_t b_size, + size_t max_cost) +{ + static size_t buffer[MAX_STRING_SIZE]; + + // Both strings are the same (by identity) + if (a == b) { + return 0; + } + + // Trim away common affixes. + while (a_size && b_size && a[0] == b[0]) { + a++; a_size--; + b++; b_size--; + } + while (a_size && b_size && a[a_size-1] == b[b_size-1]) { + a_size--; + b_size--; + } + if (a_size == 0 || b_size == 0) { + return (a_size + b_size) * MOVE_COST; + } + if (a_size > MAX_STRING_SIZE || b_size > MAX_STRING_SIZE) { + return max_cost + 1; + } + + // Prefer shorter buffer + if (b_size < a_size) { + const char *t = a; a = b; b = t; + size_t t_size = a_size; a_size = b_size; b_size = t_size; + } + + // quick fail when a match is impossible. + if ((b_size - a_size) * MOVE_COST > max_cost) { + return max_cost + 1; + } + + // Instead of producing the whole traditional len(a)-by-len(b) + // matrix, we can update just one row in place. + // Initialize the buffer row + for (size_t i = 0; i < a_size; i++) { + // cost from b[:0] to a[:i+1] + buffer[i] = (i + 1) * MOVE_COST; + } + + size_t result = 0; + for (size_t b_index = 0; b_index < b_size; b_index++) { + char code = b[b_index]; + // cost(b[:b_index], a[:0]) == b_index * MOVE_COST + size_t distance = result = b_index * MOVE_COST; + size_t minimum = SIZE_MAX; + for (size_t index = 0; index < a_size; index++) { + + // cost(b[:b_index+1], a[:index+1]) = min( + // // 1) substitute + // cost(b[:b_index], a[:index]) + // + substitution_cost(b[b_index], a[index]), + // // 2) delete from b + // cost(b[:b_index], a[:index+1]) + MOVE_COST, + // // 3) delete from a + // cost(b[:b_index+1], a[index]) + MOVE_COST + // ) + + // 1) Previous distance in this row is cost(b[:b_index], a[:index]) + size_t substitute = distance + substitution_cost(code, a[index]); + // 2) cost(b[:b_index], a[:index+1]) from previous row + distance = buffer[index]; + // 3) existing result is cost(b[:b_index+1], a[index]) + + size_t insert_delete = Py_MIN(result, distance) + MOVE_COST; + result = Py_MIN(insert_delete, substitute); + + // cost(b[:b_index+1], a[:index+1]) + buffer[index] = result; + if (result < minimum) { + minimum = result; + } + } + if (minimum > max_cost) { + // Everything in this row is too big, so bail early. + return max_cost + 1; + } + } + return result; +} + +static inline PyObject * +calculate_suggestions(PyObject *dir, + PyObject *name) +{ + assert(!PyErr_Occurred()); + assert(PyList_CheckExact(dir)); + + Py_ssize_t dir_size = PyList_GET_SIZE(dir); + if (dir_size >= MAX_CANDIDATE_ITEMS) { + return NULL; + } + + Py_ssize_t suggestion_distance = PY_SSIZE_T_MAX; + PyObject *suggestion = NULL; + Py_ssize_t name_size; + const char *name_str = PyUnicode_AsUTF8AndSize(name, &name_size); + if (name_str == NULL) { + return NULL; + } + + for (int i = 0; i < dir_size; ++i) { + PyObject *item = PyList_GET_ITEM(dir, i); + Py_ssize_t item_size; + const char *item_str = PyUnicode_AsUTF8AndSize(item, &item_size); + if (item_str == NULL) { + return NULL; + } + if (PyUnicode_CompareWithASCIIString(name, item_str) == 0) { + continue; + } + // No more than 1/3 of the involved characters should need changed. + Py_ssize_t max_distance = (name_size + item_size + 3) * MOVE_COST / 6; + // Don't take matches we've already beaten. + max_distance = Py_MIN(max_distance, suggestion_distance - 1); + Py_ssize_t current_distance = + levenshtein_distance(name_str, name_size, + item_str, item_size, max_distance); + if (current_distance > max_distance) { + continue; + } + if (!suggestion || current_distance < suggestion_distance) { + suggestion = item; + suggestion_distance = current_distance; + } + } + Py_XINCREF(suggestion); + return suggestion; +} + +static PyObject * +offer_suggestions_for_attribute_error(PyAttributeErrorObject *exc) +{ + PyObject *name = exc->name; // borrowed reference + PyObject *obj = exc->obj; // borrowed reference + + // Abort if we don't have an attribute name or we have an invalid one + if (name == NULL || obj == NULL || !PyUnicode_CheckExact(name)) { + return NULL; + } + + PyObject *dir = PyObject_Dir(obj); + if (dir == NULL) { + return NULL; + } + + PyObject *suggestions = calculate_suggestions(dir, name); + Py_DECREF(dir); + return suggestions; +} + + +static PyObject * +offer_suggestions_for_name_error(PyNameErrorObject *exc) +{ + PyObject *name = exc->name; // borrowed reference + PyTracebackObject *traceback = (PyTracebackObject *) exc->traceback; // borrowed reference + // Abort if we don't have a variable name or we have an invalid one + // or if we don't have a traceback to work with + if (name == NULL || !PyUnicode_CheckExact(name) || + traceback == NULL || !Py_IS_TYPE(traceback, &PyTraceBack_Type) + ) { + return NULL; + } + + // Move to the traceback of the exception + while (1) { + PyTracebackObject *next = traceback->tb_next; + if (next == NULL || !Py_IS_TYPE(next, &PyTraceBack_Type)) { + break; + } + else { + traceback = next; + } + } + + PyFrameObject *frame = traceback->tb_frame; + assert(frame != NULL); + PyCodeObject *code = frame->f_code; + assert(code != NULL && code->co_varnames != NULL); + PyObject *dir = PySequence_List(code->co_varnames); + if (dir == NULL) { + return NULL; + } + + PyObject *suggestions = calculate_suggestions(dir, name); + Py_DECREF(dir); + if (suggestions != NULL) { + return suggestions; + } + + dir = PySequence_List(frame->f_globals); + if (dir == NULL) { + return NULL; + } + suggestions = calculate_suggestions(dir, name); + Py_DECREF(dir); + if (suggestions != NULL) { + return suggestions; + } + + dir = PySequence_List(frame->f_builtins); + if (dir == NULL) { + return NULL; + } + suggestions = calculate_suggestions(dir, name); + Py_DECREF(dir); + + return suggestions; +} + +// Offer suggestions for a given exception. Returns a python string object containing the +// suggestions. This function returns NULL if no suggestion was found or if an exception happened, +// users must call PyErr_Occurred() to disambiguate. +PyObject * +_Py_Offer_Suggestions(PyObject *exception) +{ + PyObject *result = NULL; + assert(!PyErr_Occurred()); + if (Py_IS_TYPE(exception, (PyTypeObject*)PyExc_AttributeError)) { + result = offer_suggestions_for_attribute_error((PyAttributeErrorObject *) exception); + } else if (Py_IS_TYPE(exception, (PyTypeObject*)PyExc_NameError)) { + result = offer_suggestions_for_name_error((PyNameErrorObject *) exception); + } + return result; +} + +Py_ssize_t +_Py_UTF8_Edit_Cost(PyObject *a, PyObject *b, Py_ssize_t max_cost) +{ + assert(PyUnicode_Check(a) && PyUnicode_Check(b)); + Py_ssize_t size_a, size_b; + const char *utf8_a = PyUnicode_AsUTF8AndSize(a, &size_a); + if (utf8_a == NULL) { + return -1; + } + const char *utf8_b = PyUnicode_AsUTF8AndSize(b, &size_b); + if (utf8_b == NULL) { + return -1; + } + if (max_cost == -1) { + max_cost = MOVE_COST * Py_MAX(size_a, size_b); + } + return levenshtein_distance(utf8_a, size_a, utf8_b, size_b, max_cost); +} + diff --git a/contrib/tools/python3/src/Python/symtable.c b/contrib/tools/python3/src/Python/symtable.c index d192f31deef..07f9d1132c7 100644 --- a/contrib/tools/python3/src/Python/symtable.c +++ b/contrib/tools/python3/src/Python/symtable.c @@ -1,7 +1,9 @@ #include "Python.h" -#include "pycore_pystate.h" // _PyThreadState_GET() -#include "symtable.h" -#undef Yield /* undefine macro conflicting with <winbase.h> */ +#include "pycore_ast.h" // identifier, stmt_ty +#include "pycore_compile.h" // _Py_Mangle(), _PyFuture_FromAST() +#include "pycore_parser.h" // _PyParser_ASTFromString() +#include "pycore_pystate.h" // _PyThreadState_GET() +#include "pycore_symtable.h" // PySTEntryObject #include "structmember.h" // PyMemberDef /* error strings used for warnings */ @@ -43,9 +45,20 @@ #define NAMED_EXPR_COMP_ITER_EXPR \ "assignment expression cannot be used in a comprehension iterable expression" +#define ANNOTATION_NOT_ALLOWED \ +"'%s' can not be used within an annotation" + + +#define LOCATION(x) \ + (x)->lineno, (x)->col_offset, (x)->end_lineno, (x)->end_col_offset + +#define ST_LOCATION(x) \ + (x)->ste_lineno, (x)->ste_col_offset, (x)->ste_end_lineno, (x)->ste_end_col_offset + static PySTEntryObject * ste_new(struct symtable *st, identifier name, _Py_block_ty block, - void *key, int lineno, int col_offset) + void *key, int lineno, int col_offset, + int end_lineno, int end_col_offset) { PySTEntryObject *ste = NULL; PyObject *k = NULL; @@ -79,6 +92,8 @@ ste_new(struct symtable *st, identifier name, _Py_block_ty block, ste->ste_opt_col_offset = 0; ste->ste_lineno = lineno; ste->ste_col_offset = col_offset; + ste->ste_end_lineno = end_lineno; + ste->ste_end_col_offset = end_col_offset; if (st->st_cur != NULL && (st->st_cur->ste_nested || @@ -87,7 +102,7 @@ ste_new(struct symtable *st, identifier name, _Py_block_ty block, ste->ste_child_free = 0; ste->ste_generator = 0; ste->ste_coroutine = 0; - ste->ste_comprehension = 0; + ste->ste_comprehension = NoComprehension; ste->ste_returns_value = 0; ste->ste_needs_class_closure = 0; ste->ste_comp_iter_target = 0; @@ -128,7 +143,7 @@ ste_dealloc(PySTEntryObject *ste) Py_XDECREF(ste->ste_varnames); Py_XDECREF(ste->ste_children); Py_XDECREF(ste->ste_directives); - PyObject_Del(ste); + PyObject_Free(ste); } #define OFF(x) offsetof(PySTEntryObject, x) @@ -188,8 +203,9 @@ PyTypeObject PySTEntry_Type = { static int symtable_analyze(struct symtable *st); static int symtable_enter_block(struct symtable *st, identifier name, - _Py_block_ty block, void *ast, int lineno, - int col_offset); + _Py_block_ty block, void *ast, + int lineno, int col_offset, + int end_lineno, int end_col_offset); static int symtable_exit_block(struct symtable *st); static int symtable_visit_stmt(struct symtable *st, stmt_ty s); static int symtable_visit_expr(struct symtable *st, expr_ty s); @@ -202,16 +218,21 @@ static int symtable_visit_excepthandler(struct symtable *st, excepthandler_ty); static int symtable_visit_alias(struct symtable *st, alias_ty); static int symtable_visit_comprehension(struct symtable *st, comprehension_ty); static int symtable_visit_keyword(struct symtable *st, keyword_ty); -static int symtable_visit_params(struct symtable *st, asdl_seq *args); -static int symtable_visit_argannotations(struct symtable *st, asdl_seq *args); +static int symtable_visit_params(struct symtable *st, asdl_arg_seq *args); +static int symtable_visit_annotation(struct symtable *st, expr_ty annotation); +static int symtable_visit_argannotations(struct symtable *st, asdl_arg_seq *args); static int symtable_implicit_arg(struct symtable *st, int pos); -static int symtable_visit_annotations(struct symtable *st, arguments_ty, expr_ty); +static int symtable_visit_annotations(struct symtable *st, stmt_ty, arguments_ty, expr_ty); static int symtable_visit_withitem(struct symtable *st, withitem_ty item); +static int symtable_visit_match_case(struct symtable *st, match_case_ty m); +static int symtable_visit_pattern(struct symtable *st, pattern_ty s); +static int symtable_raise_if_annotation_block(struct symtable *st, const char *, expr_ty); +static int symtable_raise_if_comprehension_block(struct symtable *st, expr_ty); static identifier top = NULL, lambda = NULL, genexpr = NULL, listcomp = NULL, setcomp = NULL, dictcomp = NULL, - __class__ = NULL; + __class__ = NULL, _annotation = NULL; #define GET_IDENTIFIER(VAR) \ ((VAR) ? (VAR) : ((VAR) = PyUnicode_InternFromString(# VAR))) @@ -241,7 +262,7 @@ symtable_new(void) st->st_private = NULL; return st; fail: - PySymtable_Free(st); + _PySymtable_Free(st); return NULL; } @@ -258,10 +279,10 @@ symtable_new(void) #define COMPILER_STACK_FRAME_SCALE 3 struct symtable * -PySymtable_BuildObject(mod_ty mod, PyObject *filename, PyFutureFeatures *future) +_PySymtable_Build(mod_ty mod, PyObject *filename, PyFutureFeatures *future) { struct symtable *st = symtable_new(); - asdl_seq *seq; + asdl_stmt_seq *seq; int i; PyThreadState *tstate; int recursion_limit = Py_GetRecursionLimit(); @@ -270,7 +291,7 @@ PySymtable_BuildObject(mod_ty mod, PyObject *filename, PyFutureFeatures *future) if (st == NULL) return NULL; if (filename == NULL) { - PySymtable_Free(st); + _PySymtable_Free(st); return NULL; } Py_INCREF(filename); @@ -280,7 +301,7 @@ PySymtable_BuildObject(mod_ty mod, PyObject *filename, PyFutureFeatures *future) /* Setup recursion depth check counters */ tstate = _PyThreadState_GET(); if (!tstate) { - PySymtable_Free(st); + _PySymtable_Free(st); return NULL; } /* Be careful here to prevent overflow. */ @@ -292,8 +313,8 @@ PySymtable_BuildObject(mod_ty mod, PyObject *filename, PyFutureFeatures *future) /* Make the initial symbol information gathering pass */ if (!GET_IDENTIFIER(top) || - !symtable_enter_block(st, top, ModuleBlock, (void *)mod, 0, 0)) { - PySymtable_Free(st); + !symtable_enter_block(st, top, ModuleBlock, (void *)mod, 0, 0, 0, 0)) { + _PySymtable_Free(st); return NULL; } @@ -323,7 +344,7 @@ PySymtable_BuildObject(mod_ty mod, PyObject *filename, PyFutureFeatures *future) goto error; } if (!symtable_exit_block(st)) { - PySymtable_Free(st); + _PySymtable_Free(st); return NULL; } /* Check that the recursion depth counting balanced correctly */ @@ -331,35 +352,23 @@ PySymtable_BuildObject(mod_ty mod, PyObject *filename, PyFutureFeatures *future) PyErr_Format(PyExc_SystemError, "symtable analysis recursion depth mismatch (before=%d, after=%d)", starting_recursion_depth, st->recursion_depth); - PySymtable_Free(st); + _PySymtable_Free(st); return NULL; } /* Make the second symbol analysis pass */ if (symtable_analyze(st)) return st; - PySymtable_Free(st); + _PySymtable_Free(st); return NULL; error: (void) symtable_exit_block(st); - PySymtable_Free(st); + _PySymtable_Free(st); return NULL; } -struct symtable * -PySymtable_Build(mod_ty mod, const char *filename_str, PyFutureFeatures *future) -{ - PyObject *filename; - struct symtable *st; - filename = PyUnicode_DecodeFSDefault(filename_str); - if (filename == NULL) - return NULL; - st = PySymtable_BuildObject(mod, filename, future); - Py_DECREF(filename); - return st; -} void -PySymtable_Free(struct symtable *st) +_PySymtable_Free(struct symtable *st) { Py_XDECREF(st->st_filename); Py_XDECREF(st->st_blocks); @@ -392,7 +401,7 @@ PySymtable_Lookup(struct symtable *st, void *key) static long _PyST_GetSymbol(PySTEntryObject *ste, PyObject *name) { - PyObject *v = PyDict_GetItem(ste->ste_symbols, name); + PyObject *v = PyDict_GetItemWithError(ste->ste_symbols, name); if (!v) return 0; assert(PyLong_Check(v)); @@ -400,7 +409,7 @@ _PyST_GetSymbol(PySTEntryObject *ste, PyObject *name) } int -PyST_GetScope(PySTEntryObject *ste, PyObject *name) +_PyST_GetScope(PySTEntryObject *ste, PyObject *name) { long symbol = _PyST_GetSymbol(ste, name); return (symbol >> SCOPE_OFFSET) & SCOPE_MASK; @@ -417,9 +426,11 @@ error_at_directive(PySTEntryObject *ste, PyObject *name) assert(PyTuple_CheckExact(data)); assert(PyUnicode_CheckExact(PyTuple_GET_ITEM(data, 0))); if (PyUnicode_Compare(PyTuple_GET_ITEM(data, 0), name) == 0) { - PyErr_SyntaxLocationObject(ste->ste_table->st_filename, - PyLong_AsLong(PyTuple_GET_ITEM(data, 1)), - PyLong_AsLong(PyTuple_GET_ITEM(data, 2)) + 1); + PyErr_RangedSyntaxLocationObject(ste->ste_table->st_filename, + PyLong_AsLong(PyTuple_GET_ITEM(data, 1)), + PyLong_AsLong(PyTuple_GET_ITEM(data, 2)) + 1, + PyLong_AsLong(PyTuple_GET_ITEM(data, 3)), + PyLong_AsLong(PyTuple_GET_ITEM(data, 4)) + 1); return 0; } @@ -634,7 +645,7 @@ update_symbols(PyObject *symbols, PyObject *scopes, long scope, flags; assert(PyLong_Check(v)); flags = PyLong_AS_LONG(v); - v_scope = PyDict_GetItem(scopes, name); + v_scope = PyDict_GetItemWithError(scopes, name); assert(v_scope && PyLong_Check(v_scope)); scope = PyLong_AS_LONG(v_scope); flags |= (scope << SCOPE_OFFSET); @@ -966,11 +977,12 @@ symtable_exit_block(struct symtable *st) static int symtable_enter_block(struct symtable *st, identifier name, _Py_block_ty block, - void *ast, int lineno, int col_offset) + void *ast, int lineno, int col_offset, + int end_lineno, int end_col_offset) { PySTEntryObject *prev = NULL, *ste; - ste = ste_new(st, name, block, ast, lineno, col_offset); + ste = ste_new(st, name, block, ast, lineno, col_offset, end_lineno, end_col_offset); if (ste == NULL) return 0; if (PyList_Append(st->st_stack, (PyObject *)ste) < 0) { @@ -988,8 +1000,17 @@ symtable_enter_block(struct symtable *st, identifier name, _Py_block_ty block, /* The entry is owned by the stack. Borrow it for st_cur. */ Py_DECREF(ste); st->st_cur = ste; + + /* Annotation blocks shouldn't have any affect on the symbol table since in + * the compilation stage, they will all be transformed to strings. They are + * only created if future 'annotations' feature is activated. */ + if (block == AnnotationBlock) { + return 1; + } + if (block == ModuleBlock) st->st_global = st->st_cur->ste_symbols; + if (prev) { if (PyList_Append(prev->ste_children, (PyObject *)ste) < 0) { return 0; @@ -1010,7 +1031,8 @@ symtable_lookup(struct symtable *st, PyObject *name) } static int -symtable_add_def_helper(struct symtable *st, PyObject *name, int flag, struct _symtable_entry *ste) +symtable_add_def_helper(struct symtable *st, PyObject *name, int flag, struct _symtable_entry *ste, + int lineno, int col_offset, int end_lineno, int end_col_offset) { PyObject *o; PyObject *dict; @@ -1026,9 +1048,9 @@ symtable_add_def_helper(struct symtable *st, PyObject *name, int flag, struct _s if ((flag & DEF_PARAM) && (val & DEF_PARAM)) { /* Is it better to use 'mangled' or 'name' here? */ PyErr_Format(PyExc_SyntaxError, DUPLICATE_ARGUMENT, name); - PyErr_SyntaxLocationObject(st->st_filename, - ste->ste_lineno, - ste->ste_col_offset + 1); + PyErr_RangedSyntaxLocationObject(st->st_filename, + lineno, col_offset + 1, + end_lineno, end_col_offset + 1); goto error; } val |= flag; @@ -1048,9 +1070,9 @@ symtable_add_def_helper(struct symtable *st, PyObject *name, int flag, struct _s if (val & (DEF_GLOBAL | DEF_NONLOCAL)) { PyErr_Format(PyExc_SyntaxError, NAMED_EXPR_COMP_INNER_LOOP_CONFLICT, name); - PyErr_SyntaxLocationObject(st->st_filename, - ste->ste_lineno, - ste->ste_col_offset + 1); + PyErr_RangedSyntaxLocationObject(st->st_filename, + lineno, col_offset + 1, + end_lineno, end_col_offset + 1); goto error; } val |= DEF_COMP_ITER; @@ -1071,9 +1093,12 @@ symtable_add_def_helper(struct symtable *st, PyObject *name, int flag, struct _s /* XXX need to update DEF_GLOBAL for other flags too; perhaps only DEF_FREE_GLOBAL */ val = flag; - if ((o = PyDict_GetItem(st->st_global, mangled))) { + if ((o = PyDict_GetItemWithError(st->st_global, mangled))) { val |= PyLong_AS_LONG(o); } + else if (PyErr_Occurred()) { + goto error; + } o = PyLong_FromLong(val); if (o == NULL) goto error; @@ -1092,8 +1117,11 @@ error: } static int -symtable_add_def(struct symtable *st, PyObject *name, int flag) { - return symtable_add_def_helper(st, name, flag, st->st_cur); +symtable_add_def(struct symtable *st, PyObject *name, int flag, + int lineno, int col_offset, int end_lineno, int end_col_offset) +{ + return symtable_add_def_helper(st, name, flag, st->st_cur, + lineno, col_offset, end_lineno, end_col_offset); } /* VISIT, VISIT_SEQ and VIST_SEQ_TAIL take an ASDL type as their second argument. @@ -1116,7 +1144,7 @@ symtable_add_def(struct symtable *st, PyObject *name, int flag) { #define VISIT_SEQ(ST, TYPE, SEQ) { \ int i; \ - asdl_seq *seq = (SEQ); /* avoid variable capture */ \ + asdl_ ## TYPE ## _seq *seq = (SEQ); /* avoid variable capture */ \ for (i = 0; i < asdl_seq_LEN(seq); i++) { \ TYPE ## _ty elt = (TYPE ## _ty)asdl_seq_GET(seq, i); \ if (!symtable_visit_ ## TYPE((ST), elt)) \ @@ -1126,7 +1154,7 @@ symtable_add_def(struct symtable *st, PyObject *name, int flag) { #define VISIT_SEQ_TAIL(ST, TYPE, SEQ, START) { \ int i; \ - asdl_seq *seq = (SEQ); /* avoid variable capture */ \ + asdl_ ## TYPE ## _seq *seq = (SEQ); /* avoid variable capture */ \ for (i = (START); i < asdl_seq_LEN(seq); i++) { \ TYPE ## _ty elt = (TYPE ## _ty)asdl_seq_GET(seq, i); \ if (!symtable_visit_ ## TYPE((ST), elt)) \ @@ -1136,7 +1164,7 @@ symtable_add_def(struct symtable *st, PyObject *name, int flag) { #define VISIT_SEQ_WITH_NULL(ST, TYPE, SEQ) { \ int i = 0; \ - asdl_seq *seq = (SEQ); /* avoid variable capture */ \ + asdl_ ## TYPE ## _seq *seq = (SEQ); /* avoid variable capture */ \ for (i = 0; i < asdl_seq_LEN(seq); i++) { \ TYPE ## _ty elt = (TYPE ## _ty)asdl_seq_GET(seq, i); \ if (!elt) continue; /* can be NULL */ \ @@ -1146,7 +1174,8 @@ symtable_add_def(struct symtable *st, PyObject *name, int flag) { } static int -symtable_record_directive(struct symtable *st, identifier name, int lineno, int col_offset) +symtable_record_directive(struct symtable *st, identifier name, int lineno, + int col_offset, int end_lineno, int end_col_offset) { PyObject *data, *mangled; int res; @@ -1158,7 +1187,7 @@ symtable_record_directive(struct symtable *st, identifier name, int lineno, int mangled = _Py_Mangle(st->st_private, name); if (!mangled) return 0; - data = Py_BuildValue("(Nii)", mangled, lineno, col_offset); + data = Py_BuildValue("(Niiii)", mangled, lineno, col_offset, end_lineno, end_col_offset); if (!data) return 0; res = PyList_Append(st->st_cur->ste_directives, data); @@ -1177,20 +1206,20 @@ symtable_visit_stmt(struct symtable *st, stmt_ty s) } switch (s->kind) { case FunctionDef_kind: - if (!symtable_add_def(st, s->v.FunctionDef.name, DEF_LOCAL)) + if (!symtable_add_def(st, s->v.FunctionDef.name, DEF_LOCAL, LOCATION(s))) VISIT_QUIT(st, 0); if (s->v.FunctionDef.args->defaults) VISIT_SEQ(st, expr, s->v.FunctionDef.args->defaults); if (s->v.FunctionDef.args->kw_defaults) VISIT_SEQ_WITH_NULL(st, expr, s->v.FunctionDef.args->kw_defaults); - if (!symtable_visit_annotations(st, s->v.FunctionDef.args, + if (!symtable_visit_annotations(st, s, s->v.FunctionDef.args, s->v.FunctionDef.returns)) VISIT_QUIT(st, 0); if (s->v.FunctionDef.decorator_list) VISIT_SEQ(st, expr, s->v.FunctionDef.decorator_list); if (!symtable_enter_block(st, s->v.FunctionDef.name, - FunctionBlock, (void *)s, s->lineno, - s->col_offset)) + FunctionBlock, (void *)s, + LOCATION(s))) VISIT_QUIT(st, 0); VISIT(st, arguments, s->v.FunctionDef.args); VISIT_SEQ(st, stmt, s->v.FunctionDef.body); @@ -1199,14 +1228,15 @@ symtable_visit_stmt(struct symtable *st, stmt_ty s) break; case ClassDef_kind: { PyObject *tmp; - if (!symtable_add_def(st, s->v.ClassDef.name, DEF_LOCAL)) + if (!symtable_add_def(st, s->v.ClassDef.name, DEF_LOCAL, LOCATION(s))) VISIT_QUIT(st, 0); VISIT_SEQ(st, expr, s->v.ClassDef.bases); VISIT_SEQ(st, keyword, s->v.ClassDef.keywords); if (s->v.ClassDef.decorator_list) VISIT_SEQ(st, expr, s->v.ClassDef.decorator_list); if (!symtable_enter_block(st, s->v.ClassDef.name, ClassBlock, - (void *)s, s->lineno, s->col_offset)) + (void *)s, s->lineno, s->col_offset, + s->end_lineno, s->end_col_offset)) VISIT_QUIT(st, 0); tmp = st->st_private; st->st_private = s->v.ClassDef.name; @@ -1242,19 +1272,21 @@ symtable_visit_stmt(struct symtable *st, stmt_ty s) PyErr_Format(PyExc_SyntaxError, cur & DEF_GLOBAL ? GLOBAL_ANNOT : NONLOCAL_ANNOT, e_name->v.Name.id); - PyErr_SyntaxLocationObject(st->st_filename, - s->lineno, - s->col_offset + 1); + PyErr_RangedSyntaxLocationObject(st->st_filename, + s->lineno, + s->col_offset + 1, + s->end_lineno, + s->end_col_offset + 1); VISIT_QUIT(st, 0); } if (s->v.AnnAssign.simple && !symtable_add_def(st, e_name->v.Name.id, - DEF_ANNOT | DEF_LOCAL)) { + DEF_ANNOT | DEF_LOCAL, LOCATION(e_name))) { VISIT_QUIT(st, 0); } else { if (s->v.AnnAssign.value - && !symtable_add_def(st, e_name->v.Name.id, DEF_LOCAL)) { + && !symtable_add_def(st, e_name->v.Name.id, DEF_LOCAL, LOCATION(e_name))) { VISIT_QUIT(st, 0); } } @@ -1262,7 +1294,10 @@ symtable_visit_stmt(struct symtable *st, stmt_ty s) else { VISIT(st, expr, s->v.AnnAssign.target); } - VISIT(st, expr, s->v.AnnAssign.annotation); + if (!symtable_visit_annotation(st, s->v.AnnAssign.annotation)) { + VISIT_QUIT(st, 0); + } + if (s->v.AnnAssign.value) { VISIT(st, expr, s->v.AnnAssign.value); } @@ -1291,6 +1326,10 @@ symtable_visit_stmt(struct symtable *st, stmt_ty s) if (s->v.If.orelse) VISIT_SEQ(st, stmt, s->v.If.orelse); break; + case Match_kind: + VISIT(st, expr, s->v.Match.subject); + VISIT_SEQ(st, match_case, s->v.Match.cases); + break; case Raise_kind: if (s->v.Raise.exc) { VISIT(st, expr, s->v.Raise.exc); @@ -1318,7 +1357,7 @@ symtable_visit_stmt(struct symtable *st, stmt_ty s) break; case Global_kind: { int i; - asdl_seq *seq = s->v.Global.names; + asdl_identifier_seq *seq = s->v.Global.names; for (i = 0; i < asdl_seq_LEN(seq); i++) { identifier name = (identifier)asdl_seq_GET(seq, i); long cur = symtable_lookup(st, name); @@ -1337,21 +1376,24 @@ symtable_visit_stmt(struct symtable *st, stmt_ty s) } PyErr_Format(PyExc_SyntaxError, msg, name); - PyErr_SyntaxLocationObject(st->st_filename, - s->lineno, - s->col_offset + 1); + PyErr_RangedSyntaxLocationObject(st->st_filename, + s->lineno, + s->col_offset + 1, + s->end_lineno, + s->end_col_offset + 1); VISIT_QUIT(st, 0); } - if (!symtable_add_def(st, name, DEF_GLOBAL)) + if (!symtable_add_def(st, name, DEF_GLOBAL, LOCATION(s))) VISIT_QUIT(st, 0); - if (!symtable_record_directive(st, name, s->lineno, s->col_offset)) + if (!symtable_record_directive(st, name, s->lineno, s->col_offset, + s->end_lineno, s->end_col_offset)) VISIT_QUIT(st, 0); } break; } case Nonlocal_kind: { int i; - asdl_seq *seq = s->v.Nonlocal.names; + asdl_identifier_seq *seq = s->v.Nonlocal.names; for (i = 0; i < asdl_seq_LEN(seq); i++) { identifier name = (identifier)asdl_seq_GET(seq, i); long cur = symtable_lookup(st, name); @@ -1369,14 +1411,17 @@ symtable_visit_stmt(struct symtable *st, stmt_ty s) msg = NONLOCAL_AFTER_ASSIGN; } PyErr_Format(PyExc_SyntaxError, msg, name); - PyErr_SyntaxLocationObject(st->st_filename, - s->lineno, - s->col_offset + 1); + PyErr_RangedSyntaxLocationObject(st->st_filename, + s->lineno, + s->col_offset + 1, + s->end_lineno, + s->end_col_offset + 1); VISIT_QUIT(st, 0); } - if (!symtable_add_def(st, name, DEF_NONLOCAL)) + if (!symtable_add_def(st, name, DEF_NONLOCAL, LOCATION(s))) VISIT_QUIT(st, 0); - if (!symtable_record_directive(st, name, s->lineno, s->col_offset)) + if (!symtable_record_directive(st, name, s->lineno, s->col_offset, + s->end_lineno, s->end_col_offset)) VISIT_QUIT(st, 0); } break; @@ -1394,21 +1439,22 @@ symtable_visit_stmt(struct symtable *st, stmt_ty s) VISIT_SEQ(st, stmt, s->v.With.body); break; case AsyncFunctionDef_kind: - if (!symtable_add_def(st, s->v.AsyncFunctionDef.name, DEF_LOCAL)) + if (!symtable_add_def(st, s->v.AsyncFunctionDef.name, DEF_LOCAL, LOCATION(s))) VISIT_QUIT(st, 0); if (s->v.AsyncFunctionDef.args->defaults) VISIT_SEQ(st, expr, s->v.AsyncFunctionDef.args->defaults); if (s->v.AsyncFunctionDef.args->kw_defaults) VISIT_SEQ_WITH_NULL(st, expr, s->v.AsyncFunctionDef.args->kw_defaults); - if (!symtable_visit_annotations(st, s->v.AsyncFunctionDef.args, + if (!symtable_visit_annotations(st, s, s->v.AsyncFunctionDef.args, s->v.AsyncFunctionDef.returns)) VISIT_QUIT(st, 0); if (s->v.AsyncFunctionDef.decorator_list) VISIT_SEQ(st, expr, s->v.AsyncFunctionDef.decorator_list); if (!symtable_enter_block(st, s->v.AsyncFunctionDef.name, - FunctionBlock, (void *)s, s->lineno, - s->col_offset)) + FunctionBlock, (void *)s, + s->lineno, s->col_offset, + s->end_lineno, s->end_col_offset)) VISIT_QUIT(st, 0); st->st_cur->ste_coroutine = 1; VISIT(st, arguments, s->v.AsyncFunctionDef.args); @@ -1454,9 +1500,11 @@ symtable_extend_namedexpr_scope(struct symtable *st, expr_ty e) long target_in_scope = _PyST_GetSymbol(ste, target_name); if (target_in_scope & DEF_COMP_ITER) { PyErr_Format(PyExc_SyntaxError, NAMED_EXPR_COMP_CONFLICT, target_name); - PyErr_SyntaxLocationObject(st->st_filename, - e->lineno, - e->col_offset); + PyErr_RangedSyntaxLocationObject(st->st_filename, + e->lineno, + e->col_offset + 1, + e->end_lineno, + e->end_col_offset + 1); VISIT_QUIT(st, 0); } continue; @@ -1466,32 +1514,34 @@ symtable_extend_namedexpr_scope(struct symtable *st, expr_ty e) if (ste->ste_type == FunctionBlock) { long target_in_scope = _PyST_GetSymbol(ste, target_name); if (target_in_scope & DEF_GLOBAL) { - if (!symtable_add_def(st, target_name, DEF_GLOBAL)) + if (!symtable_add_def(st, target_name, DEF_GLOBAL, LOCATION(e))) VISIT_QUIT(st, 0); } else { - if (!symtable_add_def(st, target_name, DEF_NONLOCAL)) + if (!symtable_add_def(st, target_name, DEF_NONLOCAL, LOCATION(e))) VISIT_QUIT(st, 0); } - if (!symtable_record_directive(st, target_name, e->lineno, e->col_offset)) + if (!symtable_record_directive(st, target_name, LOCATION(e))) VISIT_QUIT(st, 0); - return symtable_add_def_helper(st, target_name, DEF_LOCAL, ste); + return symtable_add_def_helper(st, target_name, DEF_LOCAL, ste, LOCATION(e)); } /* If we find a ModuleBlock entry, add as GLOBAL */ if (ste->ste_type == ModuleBlock) { - if (!symtable_add_def(st, target_name, DEF_GLOBAL)) + if (!symtable_add_def(st, target_name, DEF_GLOBAL, LOCATION(e))) VISIT_QUIT(st, 0); - if (!symtable_record_directive(st, target_name, e->lineno, e->col_offset)) + if (!symtable_record_directive(st, target_name, LOCATION(e))) VISIT_QUIT(st, 0); - return symtable_add_def_helper(st, target_name, DEF_GLOBAL, ste); + return symtable_add_def_helper(st, target_name, DEF_GLOBAL, ste, LOCATION(e)); } /* Disallow usage in ClassBlock */ if (ste->ste_type == ClassBlock) { PyErr_Format(PyExc_SyntaxError, NAMED_EXPR_COMP_IN_CLASS); - PyErr_SyntaxLocationObject(st->st_filename, - e->lineno, - e->col_offset); + PyErr_RangedSyntaxLocationObject(st->st_filename, + e->lineno, + e->col_offset + 1, + e->end_lineno, + e->end_col_offset + 1); VISIT_QUIT(st, 0); } } @@ -1509,9 +1559,11 @@ symtable_handle_namedexpr(struct symtable *st, expr_ty e) if (st->st_cur->ste_comp_iter_expr > 0) { /* Assignment isn't allowed in a comprehension iterable expression */ PyErr_Format(PyExc_SyntaxError, NAMED_EXPR_COMP_ITER_EXPR); - PyErr_SyntaxLocationObject(st->st_filename, - e->lineno, - e->col_offset); + PyErr_RangedSyntaxLocationObject(st->st_filename, + e->lineno, + e->col_offset + 1, + e->end_lineno, + e->end_col_offset + 1); return 0; } if (st->st_cur->ste_comprehension) { @@ -1534,6 +1586,9 @@ symtable_visit_expr(struct symtable *st, expr_ty e) } switch (e->kind) { case NamedExpr_kind: + if (!symtable_raise_if_annotation_block(st, "named expression", e)) { + VISIT_QUIT(st, 0); + } if(!symtable_handle_namedexpr(st, e)) VISIT_QUIT(st, 0); break; @@ -1555,8 +1610,9 @@ symtable_visit_expr(struct symtable *st, expr_ty e) if (e->v.Lambda.args->kw_defaults) VISIT_SEQ_WITH_NULL(st, expr, e->v.Lambda.args->kw_defaults); if (!symtable_enter_block(st, lambda, - FunctionBlock, (void *)e, e->lineno, - e->col_offset)) + FunctionBlock, (void *)e, + e->lineno, e->col_offset, + e->end_lineno, e->end_col_offset)) VISIT_QUIT(st, 0); VISIT(st, arguments, e->v.Lambda.args); VISIT(st, expr, e->v.Lambda.body); @@ -1593,15 +1649,30 @@ symtable_visit_expr(struct symtable *st, expr_ty e) VISIT_QUIT(st, 0); break; case Yield_kind: + if (!symtable_raise_if_annotation_block(st, "yield expression", e)) { + VISIT_QUIT(st, 0); + } if (e->v.Yield.value) VISIT(st, expr, e->v.Yield.value); st->st_cur->ste_generator = 1; + if (st->st_cur->ste_comprehension) { + return symtable_raise_if_comprehension_block(st, e); + } break; case YieldFrom_kind: + if (!symtable_raise_if_annotation_block(st, "yield expression", e)) { + VISIT_QUIT(st, 0); + } VISIT(st, expr, e->v.YieldFrom.value); st->st_cur->ste_generator = 1; + if (st->st_cur->ste_comprehension) { + return symtable_raise_if_comprehension_block(st, e); + } break; case Await_kind: + if (!symtable_raise_if_annotation_block(st, "await expression", e)) { + VISIT_QUIT(st, 0); + } VISIT(st, expr, e->v.Await.value); st->st_cur->ste_coroutine = 1; break; @@ -1646,14 +1717,14 @@ symtable_visit_expr(struct symtable *st, expr_ty e) break; case Name_kind: if (!symtable_add_def(st, e->v.Name.id, - e->v.Name.ctx == Load ? USE : DEF_LOCAL)) + e->v.Name.ctx == Load ? USE : DEF_LOCAL, LOCATION(e))) VISIT_QUIT(st, 0); /* Special-case super: it counts as a use of __class__ */ if (e->v.Name.ctx == Load && st->st_cur->ste_type == FunctionBlock && _PyUnicode_EqualToASCIIString(e->v.Name.id, "super")) { if (!GET_IDENTIFIER(__class__) || - !symtable_add_def(st, __class__, USE)) + !symtable_add_def(st, __class__, USE, LOCATION(e))) VISIT_QUIT(st, 0); } break; @@ -1669,12 +1740,62 @@ symtable_visit_expr(struct symtable *st, expr_ty e) } static int +symtable_visit_pattern(struct symtable *st, pattern_ty p) +{ + if (++st->recursion_depth > st->recursion_limit) { + PyErr_SetString(PyExc_RecursionError, + "maximum recursion depth exceeded during compilation"); + VISIT_QUIT(st, 0); + } + switch (p->kind) { + case MatchValue_kind: + VISIT(st, expr, p->v.MatchValue.value); + break; + case MatchSingleton_kind: + /* Nothing to do here. */ + break; + case MatchSequence_kind: + VISIT_SEQ(st, pattern, p->v.MatchSequence.patterns); + break; + case MatchStar_kind: + if (p->v.MatchStar.name) { + symtable_add_def(st, p->v.MatchStar.name, DEF_LOCAL, LOCATION(p)); + } + break; + case MatchMapping_kind: + VISIT_SEQ(st, expr, p->v.MatchMapping.keys); + VISIT_SEQ(st, pattern, p->v.MatchMapping.patterns); + if (p->v.MatchMapping.rest) { + symtable_add_def(st, p->v.MatchMapping.rest, DEF_LOCAL, LOCATION(p)); + } + break; + case MatchClass_kind: + VISIT(st, expr, p->v.MatchClass.cls); + VISIT_SEQ(st, pattern, p->v.MatchClass.patterns); + VISIT_SEQ(st, pattern, p->v.MatchClass.kwd_patterns); + break; + case MatchAs_kind: + if (p->v.MatchAs.pattern) { + VISIT(st, pattern, p->v.MatchAs.pattern); + } + if (p->v.MatchAs.name) { + symtable_add_def(st, p->v.MatchAs.name, DEF_LOCAL, LOCATION(p)); + } + break; + case MatchOr_kind: + VISIT_SEQ(st, pattern, p->v.MatchOr.patterns); + break; + } + VISIT_QUIT(st, 1); +} + +static int symtable_implicit_arg(struct symtable *st, int pos) { PyObject *id = PyUnicode_FromFormat(".%d", pos); if (id == NULL) return 0; - if (!symtable_add_def(st, id, DEF_PARAM)) { + if (!symtable_add_def(st, id, DEF_PARAM, ST_LOCATION(st->st_cur))) { Py_DECREF(id); return 0; } @@ -1683,7 +1804,7 @@ symtable_implicit_arg(struct symtable *st, int pos) } static int -symtable_visit_params(struct symtable *st, asdl_seq *args) +symtable_visit_params(struct symtable *st, asdl_arg_seq *args) { int i; @@ -1692,7 +1813,7 @@ symtable_visit_params(struct symtable *st, asdl_seq *args) for (i = 0; i < asdl_seq_LEN(args); i++) { arg_ty arg = (arg_ty)asdl_seq_GET(args, i); - if (!symtable_add_def(st, arg->arg, DEF_PARAM)) + if (!symtable_add_def(st, arg->arg, DEF_PARAM, LOCATION(arg))) return 0; } @@ -1700,7 +1821,25 @@ symtable_visit_params(struct symtable *st, asdl_seq *args) } static int -symtable_visit_argannotations(struct symtable *st, asdl_seq *args) +symtable_visit_annotation(struct symtable *st, expr_ty annotation) +{ + int future_annotations = st->st_future->ff_features & CO_FUTURE_ANNOTATIONS; + if (future_annotations && + !symtable_enter_block(st, GET_IDENTIFIER(_annotation), AnnotationBlock, + (void *)annotation, annotation->lineno, + annotation->col_offset, annotation->end_lineno, + annotation->end_col_offset)) { + VISIT_QUIT(st, 0); + } + VISIT(st, expr, annotation); + if (future_annotations && !symtable_exit_block(st)) { + VISIT_QUIT(st, 0); + } + return 1; +} + +static int +symtable_visit_argannotations(struct symtable *st, asdl_arg_seq *args) { int i; @@ -1717,8 +1856,15 @@ symtable_visit_argannotations(struct symtable *st, asdl_seq *args) } static int -symtable_visit_annotations(struct symtable *st, arguments_ty a, expr_ty returns) +symtable_visit_annotations(struct symtable *st, stmt_ty o, arguments_ty a, expr_ty returns) { + int future_annotations = st->st_future->ff_features & CO_FUTURE_ANNOTATIONS; + if (future_annotations && + !symtable_enter_block(st, GET_IDENTIFIER(_annotation), AnnotationBlock, + (void *)o, o->lineno, o->col_offset, o->end_lineno, + o->end_col_offset)) { + VISIT_QUIT(st, 0); + } if (a->posonlyargs && !symtable_visit_argannotations(st, a->posonlyargs)) return 0; if (a->args && !symtable_visit_argannotations(st, a->args)) @@ -1729,8 +1875,12 @@ symtable_visit_annotations(struct symtable *st, arguments_ty a, expr_ty returns) VISIT(st, expr, a->kwarg->annotation); if (a->kwonlyargs && !symtable_visit_argannotations(st, a->kwonlyargs)) return 0; - if (returns) - VISIT(st, expr, returns); + if (future_annotations && !symtable_exit_block(st)) { + VISIT_QUIT(st, 0); + } + if (returns && !symtable_visit_annotation(st, returns)) { + VISIT_QUIT(st, 0); + } return 1; } @@ -1747,12 +1897,12 @@ symtable_visit_arguments(struct symtable *st, arguments_ty a) if (a->kwonlyargs && !symtable_visit_params(st, a->kwonlyargs)) return 0; if (a->vararg) { - if (!symtable_add_def(st, a->vararg->arg, DEF_PARAM)) + if (!symtable_add_def(st, a->vararg->arg, DEF_PARAM, LOCATION(a->vararg))) return 0; st->st_cur->ste_varargs = 1; } if (a->kwarg) { - if (!symtable_add_def(st, a->kwarg->arg, DEF_PARAM)) + if (!symtable_add_def(st, a->kwarg->arg, DEF_PARAM, LOCATION(a->kwarg))) return 0; st->st_cur->ste_varkeywords = 1; } @@ -1766,7 +1916,7 @@ symtable_visit_excepthandler(struct symtable *st, excepthandler_ty eh) if (eh->v.ExceptHandler.type) VISIT(st, expr, eh->v.ExceptHandler.type); if (eh->v.ExceptHandler.name) - if (!symtable_add_def(st, eh->v.ExceptHandler.name, DEF_LOCAL)) + if (!symtable_add_def(st, eh->v.ExceptHandler.name, DEF_LOCAL, LOCATION(eh))) return 0; VISIT_SEQ(st, stmt, eh->v.ExceptHandler.body); return 1; @@ -1782,6 +1932,16 @@ symtable_visit_withitem(struct symtable *st, withitem_ty item) return 1; } +static int +symtable_visit_match_case(struct symtable *st, match_case_ty m) +{ + VISIT(st, pattern, m->pattern); + if (m->guard) { + VISIT(st, expr, m->guard); + } + VISIT_SEQ(st, stmt, m->body); + return 1; +} static int symtable_visit_alias(struct symtable *st, alias_ty a) @@ -1804,16 +1964,20 @@ symtable_visit_alias(struct symtable *st, alias_ty a) Py_INCREF(store_name); } if (!_PyUnicode_EqualToASCIIString(name, "*")) { - int r = symtable_add_def(st, store_name, DEF_IMPORT); + int r = symtable_add_def(st, store_name, DEF_IMPORT, LOCATION(a)); Py_DECREF(store_name); return r; } else { if (st->st_cur->ste_type != ModuleBlock) { - int lineno = st->st_cur->ste_lineno; - int col_offset = st->st_cur->ste_col_offset; + int lineno = a->lineno; + int col_offset = a->col_offset; + int end_lineno = a->end_lineno; + int end_col_offset = a->end_col_offset; PyErr_SetString(PyExc_SyntaxError, IMPORT_STAR_WARNING); - PyErr_SyntaxLocationObject(st->st_filename, lineno, col_offset + 1); + PyErr_RangedSyntaxLocationObject(st->st_filename, + lineno, col_offset + 1, + end_lineno, end_col_offset + 1); Py_DECREF(store_name); return 0; } @@ -1850,7 +2014,7 @@ symtable_visit_keyword(struct symtable *st, keyword_ty k) static int symtable_handle_comprehension(struct symtable *st, expr_ty e, - identifier scope_name, asdl_seq *generators, + identifier scope_name, asdl_comprehension_seq *generators, expr_ty elt, expr_ty value) { int is_generator = (e->kind == GeneratorExp_kind); @@ -1863,13 +2027,27 @@ symtable_handle_comprehension(struct symtable *st, expr_ty e, /* Create comprehension scope for the rest */ if (!scope_name || !symtable_enter_block(st, scope_name, FunctionBlock, (void *)e, - e->lineno, e->col_offset)) { + e->lineno, e->col_offset, + e->end_lineno, e->end_col_offset)) { return 0; } + switch(e->kind) { + case ListComp_kind: + st->st_cur->ste_comprehension = ListComprehension; + break; + case SetComp_kind: + st->st_cur->ste_comprehension = SetComprehension; + break; + case DictComp_kind: + st->st_cur->ste_comprehension = DictComprehension; + break; + default: + st->st_cur->ste_comprehension = GeneratorExpression; + break; + } if (outermost->is_async) { st->st_cur->ste_coroutine = 1; } - st->st_cur->ste_comprehension = 1; /* Outermost iter is received as an argument */ if (!symtable_implicit_arg(st, 0)) { @@ -1886,18 +2064,6 @@ symtable_handle_comprehension(struct symtable *st, expr_ty e, if (value) VISIT(st, expr, value); VISIT(st, expr, elt); - if (st->st_cur->ste_generator) { - PyErr_SetString(PyExc_SyntaxError, - (e->kind == ListComp_kind) ? "'yield' inside list comprehension" : - (e->kind == SetComp_kind) ? "'yield' inside set comprehension" : - (e->kind == DictComp_kind) ? "'yield' inside dict comprehension" : - "'yield' inside generator expression"); - PyErr_SyntaxLocationObject(st->st_filename, - st->st_cur->ste_lineno, - st->st_cur->ste_col_offset + 1); - symtable_exit_block(st); - return 0; - } st->st_cur->ste_generator = is_generator; return symtable_exit_block(st); } @@ -1934,3 +2100,62 @@ symtable_visit_dictcomp(struct symtable *st, expr_ty e) e->v.DictComp.key, e->v.DictComp.value); } + +static int +symtable_raise_if_annotation_block(struct symtable *st, const char *name, expr_ty e) +{ + if (st->st_cur->ste_type != AnnotationBlock) { + return 1; + } + + PyErr_Format(PyExc_SyntaxError, ANNOTATION_NOT_ALLOWED, name); + PyErr_RangedSyntaxLocationObject(st->st_filename, + e->lineno, + e->col_offset + 1, + e->end_lineno, + e->end_col_offset + 1); + return 0; +} + +static int +symtable_raise_if_comprehension_block(struct symtable *st, expr_ty e) { + _Py_comprehension_ty type = st->st_cur->ste_comprehension; + PyErr_SetString(PyExc_SyntaxError, + (type == ListComprehension) ? "'yield' inside list comprehension" : + (type == SetComprehension) ? "'yield' inside set comprehension" : + (type == DictComprehension) ? "'yield' inside dict comprehension" : + "'yield' inside generator expression"); + PyErr_RangedSyntaxLocationObject(st->st_filename, + e->lineno, e->col_offset + 1, + e->end_lineno, e->end_col_offset + 1); + VISIT_QUIT(st, 0); +} + +struct symtable * +_Py_SymtableStringObjectFlags(const char *str, PyObject *filename, + int start, PyCompilerFlags *flags) +{ + struct symtable *st; + mod_ty mod; + PyArena *arena; + + arena = _PyArena_New(); + if (arena == NULL) + return NULL; + + mod = _PyParser_ASTFromString(str, filename, start, flags, arena); + if (mod == NULL) { + _PyArena_Free(arena); + return NULL; + } + PyFutureFeatures *future = _PyFuture_FromAST(mod, filename); + if (future == NULL) { + _PyArena_Free(arena); + return NULL; + } + future->ff_features |= flags->cf_flags; + st = _PySymtable_Build(mod, filename, future); + PyObject_Free((void *)future); + _PyArena_Free(arena); + return st; +} diff --git a/contrib/tools/python3/src/Python/sysmodule.c b/contrib/tools/python3/src/Python/sysmodule.c index 33eb848fac3..1a96c50d250 100644 --- a/contrib/tools/python3/src/Python/sysmodule.c +++ b/contrib/tools/python3/src/Python/sysmodule.c @@ -15,20 +15,22 @@ Data members: */ #include "Python.h" -#include "code.h" -#include "frameobject.h" // PyFrame_GetBack() -#include "pycore_ceval.h" -#include "pycore_initconfig.h" -#include "pycore_object.h" -#include "pycore_pathconfig.h" -#include "pycore_pyerrors.h" -#include "pycore_pylifecycle.h" +#include "pycore_ceval.h" // _Py_RecursionLimitLowerWaterMark() +#include "pycore_initconfig.h" // _PyStatus_EXCEPTION() +#include "pycore_object.h" // _PyObject_IS_GC() +#include "pycore_pathconfig.h" // _PyPathConfig_ComputeSysPath0() +#include "pycore_pyerrors.h" // _PyErr_Fetch() +#include "pycore_pylifecycle.h" // _PyErr_WriteUnraisableDefaultHook() #include "pycore_pymem.h" // _PyMem_SetDefaultAllocator() #include "pycore_pystate.h" // _PyThreadState_GET() -#include "pycore_tupleobject.h" +#include "pycore_tuple.h" // _PyTuple_FromArray() +#include "pycore_structseq.h" // PyStructSequence_InitType() +#include "code.h" +#include "frameobject.h" // PyFrame_GetBack() #include "pydtrace.h" #include "osdefs.h" // DELIM +#include "stdlib_module_names.h" // _Py_stdlib_module_names #include <locale.h> #ifdef MS_WINDOWS @@ -68,7 +70,13 @@ sys_get_object_id(PyThreadState *tstate, _Py_Identifier *key) if (sd == NULL) { return NULL; } - return _PyDict_GetItemId(sd, key); + PyObject *exc_type, *exc_value, *exc_tb; + _PyErr_Fetch(tstate, &exc_type, &exc_value, &exc_tb); + PyObject *value = _PyDict_GetItemIdWithError(sd, key); + /* XXX Suppress a new exception if it was raised and restore + * the old one. */ + _PyErr_Restore(tstate, exc_type, exc_value, exc_tb); + return value; } PyObject * @@ -78,77 +86,91 @@ _PySys_GetObjectId(_Py_Identifier *key) return sys_get_object_id(tstate, key); } +static PyObject * +_PySys_GetObject(PyInterpreterState *interp, const char *name) +{ + PyObject *sysdict = interp->sysdict; + if (sysdict == NULL) { + return NULL; + } + return _PyDict_GetItemStringWithError(sysdict, name); +} + PyObject * PySys_GetObject(const char *name) { PyThreadState *tstate = _PyThreadState_GET(); - PyObject *sd = tstate->interp->sysdict; - if (sd == NULL) { - return NULL; - } - return PyDict_GetItemString(sd, name); + + PyObject *exc_type, *exc_value, *exc_tb; + _PyErr_Fetch(tstate, &exc_type, &exc_value, &exc_tb); + PyObject *value = _PySys_GetObject(tstate->interp, name); + /* XXX Suppress a new exception if it was raised and restore + * the old one. */ + _PyErr_Restore(tstate, exc_type, exc_value, exc_tb); + return value; } static int -sys_set_object_id(PyThreadState *tstate, _Py_Identifier *key, PyObject *v) +sys_set_object(PyInterpreterState *interp, PyObject *key, PyObject *v) { - PyObject *sd = tstate->interp->sysdict; + if (key == NULL) { + return -1; + } + PyObject *sd = interp->sysdict; if (v == NULL) { - if (_PyDict_GetItemId(sd, key) == NULL) { - return 0; - } - else { - return _PyDict_DelItemId(sd, key); + v = _PyDict_Pop(sd, key, Py_None); + if (v == NULL) { + return -1; } + Py_DECREF(v); + return 0; } else { - return _PyDict_SetItemId(sd, key, v); + return PyDict_SetItem(sd, key, v); } } +static int +sys_set_object_id(PyInterpreterState *interp, _Py_Identifier *key, PyObject *v) +{ + return sys_set_object(interp, _PyUnicode_FromId(key), v); +} + int _PySys_SetObjectId(_Py_Identifier *key, PyObject *v) { - PyThreadState *tstate = _PyThreadState_GET(); - return sys_set_object_id(tstate, key, v); + PyInterpreterState *interp = _PyInterpreterState_GET(); + return sys_set_object_id(interp, key, v); } static int -sys_set_object(PyThreadState *tstate, const char *name, PyObject *v) +sys_set_object_str(PyInterpreterState *interp, const char *name, PyObject *v) { - PyObject *sd = tstate->interp->sysdict; - if (v == NULL) { - if (PyDict_GetItemString(sd, name) == NULL) { - return 0; - } - else { - return PyDict_DelItemString(sd, name); - } - } - else { - return PyDict_SetItemString(sd, name, v); - } + PyObject *key = v ? PyUnicode_InternFromString(name) + : PyUnicode_FromString(name); + int r = sys_set_object(interp, key, v); + Py_XDECREF(key); + return r; } int PySys_SetObject(const char *name, PyObject *v) { - PyThreadState *tstate = _PyThreadState_GET(); - return sys_set_object(tstate, name, v); + PyInterpreterState *interp = _PyInterpreterState_GET(); + return sys_set_object_str(interp, name, v); } static int -should_audit(PyInterpreterState *is) +should_audit(PyInterpreterState *interp) { - /* tstate->interp cannot be NULL, but test it just in case - for extra safety */ - assert(is != NULL); - if (!is) { + /* interp must not be NULL, but test it just in case for extra safety */ + assert(interp != NULL); + if (!interp) { return 0; } - return (is->runtime->audit_hook_head - || is->audit_hooks + return (interp->runtime->audit_hook_head + || interp->audit_hooks || PyDTrace_AUDIT_ENABLED()); } @@ -231,7 +253,7 @@ sys_audit_tstate(PyThreadState *ts, const char *event, /* Disallow tracing in hooks unless explicitly enabled */ ts->tracing++; - ts->use_tracing = 0; + ts->cframe->use_tracing = 0; while ((hook = PyIter_Next(hooks)) != NULL) { _Py_IDENTIFIER(__cantrace__); PyObject *o; @@ -244,14 +266,14 @@ sys_audit_tstate(PyThreadState *ts, const char *event, break; } if (canTrace) { - ts->use_tracing = (ts->c_tracefunc || ts->c_profilefunc); + ts->cframe->use_tracing = (ts->c_tracefunc || ts->c_profilefunc); ts->tracing--; } PyObject* args[2] = {eventName, eventArgs}; o = _PyObject_FastCallTstate(ts, hook, args, 2); if (canTrace) { ts->tracing++; - ts->use_tracing = 0; + ts->cframe->use_tracing = 0; } if (!o) { break; @@ -259,7 +281,7 @@ sys_audit_tstate(PyThreadState *ts, const char *event, Py_DECREF(o); Py_CLEAR(hook); } - ts->use_tracing = (ts->c_tracefunc || ts->c_profilefunc); + ts->cframe->use_tracing = (ts->c_tracefunc || ts->c_profilefunc); ts->tracing--; if (_PyErr_Occurred(ts)) { goto exit; @@ -433,15 +455,15 @@ sys_addaudithook_impl(PyObject *module, PyObject *hook) return NULL; } - PyInterpreterState *is = tstate->interp; - if (is->audit_hooks == NULL) { - is->audit_hooks = PyList_New(0); - if (is->audit_hooks == NULL) { + PyInterpreterState *interp = tstate->interp; + if (interp->audit_hooks == NULL) { + interp->audit_hooks = PyList_New(0); + if (interp->audit_hooks == NULL) { return NULL; } } - if (PyList_Append(is->audit_hooks, hook) < 0) { + if (PyList_Append(interp->audit_hooks, hook) < 0) { return NULL; } @@ -816,8 +838,7 @@ sys_exit_impl(PyObject *module, PyObject *status) /*[clinic end generated code: output=13870986c1ab2ec0 input=b86ca9497baa94f2]*/ { /* Raise SystemExit so callers may catch it or clean up. */ - PyThreadState *tstate = _PyThreadState_GET(); - _PyErr_SetObject(tstate, PyExc_SystemExit, status); + PyErr_SetObject(PyExc_SystemExit, status); return NULL; } @@ -883,15 +904,14 @@ static PyObject * sys_intern_impl(PyObject *module, PyObject *s) /*[clinic end generated code: output=be680c24f5c9e5d6 input=849483c006924e2f]*/ { - PyThreadState *tstate = _PyThreadState_GET(); if (PyUnicode_CheckExact(s)) { Py_INCREF(s); PyUnicode_InternInPlace(&s); return s; } else { - _PyErr_Format(tstate, PyExc_TypeError, - "can't intern %.400s", Py_TYPE(s)->tp_name); + PyErr_Format(PyExc_TypeError, + "can't intern %.400s", Py_TYPE(s)->tp_name); return NULL; } } @@ -1119,10 +1139,9 @@ static PyObject * sys_setswitchinterval_impl(PyObject *module, double interval) /*[clinic end generated code: output=65a19629e5153983 input=561b477134df91d9]*/ { - PyThreadState *tstate = _PyThreadState_GET(); if (interval <= 0.0) { - _PyErr_SetString(tstate, PyExc_ValueError, - "switch interval must be strictly positive"); + PyErr_SetString(PyExc_ValueError, + "switch interval must be strictly positive"); return NULL; } _PyEval_SetSwitchInterval((unsigned long) (1e6 * interval)); @@ -1255,7 +1274,6 @@ sys_set_asyncgen_hooks(PyObject *self, PyObject *args, PyObject *kw) static char *keywords[] = {"firstiter", "finalizer", NULL}; PyObject *firstiter = NULL; PyObject *finalizer = NULL; - PyThreadState *tstate = _PyThreadState_GET(); if (!PyArg_ParseTupleAndKeywords( args, kw, "|OO", keywords, @@ -1265,9 +1283,9 @@ sys_set_asyncgen_hooks(PyObject *self, PyObject *args, PyObject *kw) if (finalizer && finalizer != Py_None) { if (!PyCallable_Check(finalizer)) { - _PyErr_Format(tstate, PyExc_TypeError, - "callable finalizer expected, got %.50s", - Py_TYPE(finalizer)->tp_name); + PyErr_Format(PyExc_TypeError, + "callable finalizer expected, got %.50s", + Py_TYPE(finalizer)->tp_name); return NULL; } if (_PyEval_SetAsyncGenFinalizer(finalizer) < 0) { @@ -1280,9 +1298,9 @@ sys_set_asyncgen_hooks(PyObject *self, PyObject *args, PyObject *kw) if (firstiter && firstiter != Py_None) { if (!PyCallable_Check(firstiter)) { - _PyErr_Format(tstate, PyExc_TypeError, - "callable firstiter expected, got %.50s", - Py_TYPE(firstiter)->tp_name); + PyErr_Format(PyExc_TypeError, + "callable firstiter expected, got %.50s", + Py_TYPE(firstiter)->tp_name); return NULL; } if (_PyEval_SetAsyncGenFirstiter(firstiter) < 0) { @@ -1388,7 +1406,7 @@ get_hash_info(PyThreadState *tstate) PyStructSequence_SET_ITEM(hash_info, field++, PyLong_FromLong(_PyHASH_INF)); PyStructSequence_SET_ITEM(hash_info, field++, - PyLong_FromLong(_PyHASH_NAN)); + PyLong_FromLong(0)); // This is no longer used PyStructSequence_SET_ITEM(hash_info, field++, PyLong_FromLong(_PyHASH_IMAG)); PyStructSequence_SET_ITEM(hash_info, field++, @@ -1483,7 +1501,6 @@ sys_getwindowsversion_impl(PyObject *module) wchar_t kernel32_path[MAX_PATH]; LPVOID verblock; DWORD verblock_size; - PyThreadState *tstate = _PyThreadState_GET(); ver.dwOSVersionInfoSize = sizeof(ver); if (!GetVersionExW((OSVERSIONINFOW*) &ver)) @@ -1534,11 +1551,10 @@ sys_getwindowsversion_impl(PyObject *module) realBuild )); - if (_PyErr_Occurred(tstate)) { + if (PyErr_Occurred()) { Py_DECREF(version); return NULL; } - return version; } @@ -1591,8 +1607,8 @@ static PyObject * sys_setdlopenflags_impl(PyObject *module, int new_val) /*[clinic end generated code: output=ec918b7fe0a37281 input=4c838211e857a77f]*/ { - PyThreadState *tstate = _PyThreadState_GET(); - tstate->interp->dlopenflags = new_val; + PyInterpreterState *interp = _PyInterpreterState_GET(); + interp->dlopenflags = new_val; Py_RETURN_NONE; } @@ -1609,8 +1625,8 @@ static PyObject * sys_getdlopenflags_impl(PyObject *module) /*[clinic end generated code: output=e92cd1bc5005da6e input=dc4ea0899c53b4b6]*/ { - PyThreadState *tstate = _PyThreadState_GET(); - return PyLong_FromLong(tstate->interp->dlopenflags); + PyInterpreterState *interp = _PyInterpreterState_GET(); + return PyLong_FromLong(interp->dlopenflags); } #endif /* HAVE_DLOPEN */ @@ -1822,6 +1838,21 @@ sys__current_frames_impl(PyObject *module) } /*[clinic input] +sys._current_exceptions + +Return a dict mapping each thread's identifier to its current raised exception. + +This function should be used for specialized purposes only. +[clinic start generated code]*/ + +static PyObject * +sys__current_exceptions_impl(PyObject *module) +/*[clinic end generated code: output=2ccfd838c746f0ba input=0e91818fbf2edc1f]*/ +{ + return _PyThread_CurrentExceptions(); +} + +/*[clinic input] sys.call_tracing func: object @@ -1871,12 +1902,12 @@ sys__debugmallocstats_impl(PyObject *module) } #ifdef Py_TRACE_REFS -/* Defined in objects.c because it uses static globals if that file */ +/* Defined in objects.c because it uses static globals in that file */ extern PyObject *_Py_GetObjects(PyObject *, PyObject *); #endif #ifdef DYNAMIC_EXECUTION_PROFILE -/* Defined in ceval.c because it uses static globals if that file */ +/* Defined in ceval.c because it uses static globals in that file */ extern PyObject *_Py_GetDXProfile(PyObject *, PyObject *); #endif @@ -1928,6 +1959,20 @@ sys_getandroidapilevel_impl(PyObject *module) #endif /* ANDROID_API_LEVEL */ +/*[clinic input] +sys._deactivate_opcache + +Deactivate the opcode cache permanently +[clinic start generated code]*/ + +static PyObject * +sys__deactivate_opcache_impl(PyObject *module) +/*[clinic end generated code: output=00e20982bd012122 input=501eac146735ccf9]*/ +{ + _PyEval_DeactivateOpCache(); + Py_RETURN_NONE; +} + static PyMethodDef sys_methods[] = { /* Might as well keep this in alphabetic order */ @@ -1937,6 +1982,7 @@ static PyMethodDef sys_methods[] = { METH_FASTCALL | METH_KEYWORDS, breakpointhook_doc}, SYS__CLEAR_TYPE_CACHE_METHODDEF SYS__CURRENT_FRAMES_METHODDEF + SYS__CURRENT_EXCEPTIONS_METHODDEF SYS_DISPLAYHOOK_METHODDEF SYS_EXC_INFO_METHODDEF SYS_EXCEPTHOOK_METHODDEF @@ -1980,36 +2026,67 @@ static PyMethodDef sys_methods[] = { SYS_GET_ASYNCGEN_HOOKS_METHODDEF SYS_GETANDROIDAPILEVEL_METHODDEF SYS_UNRAISABLEHOOK_METHODDEF + SYS__DEACTIVATE_OPCACHE_METHODDEF {NULL, NULL} /* sentinel */ }; + static PyObject * list_builtin_module_names(void) { PyObject *list = PyList_New(0); - int i; - if (list == NULL) + if (list == NULL) { return NULL; - for (i = 0; PyImport_Inittab[i].name != NULL; i++) { - PyObject *name = PyUnicode_FromString( - PyImport_Inittab[i].name); - if (name == NULL) - break; - PyList_Append(list, name); + } + for (Py_ssize_t i = 0; PyImport_Inittab[i].name != NULL; i++) { + PyObject *name = PyUnicode_FromString(PyImport_Inittab[i].name); + if (name == NULL) { + goto error; + } + if (PyList_Append(list, name) < 0) { + Py_DECREF(name); + goto error; + } Py_DECREF(name); } if (PyList_Sort(list) != 0) { - Py_DECREF(list); - list = NULL; + goto error; + } + PyObject *tuple = PyList_AsTuple(list); + Py_DECREF(list); + return tuple; + +error: + Py_DECREF(list); + return NULL; +} + + +static PyObject * +list_stdlib_module_names(void) +{ + Py_ssize_t len = Py_ARRAY_LENGTH(_Py_stdlib_module_names); + PyObject *names = PyTuple_New(len); + if (names == NULL) { + return NULL; } - if (list) { - PyObject *v = PyList_AsTuple(list); - Py_DECREF(list); - list = v; + + for (Py_ssize_t i = 0; i < len; i++) { + PyObject *name = PyUnicode_FromString(_Py_stdlib_module_names[i]); + if (name == NULL) { + Py_DECREF(names); + return NULL; + } + PyTuple_SET_ITEM(names, i, name); } - return list; + + PyObject *set = PyObject_CallFunction((PyObject *)&PyFrozenSet_Type, + "(O)", names); + Py_DECREF(names); + return set; } + /* Pre-initialization support for sys.warnoptions and sys._xoptions * * Modern internal code paths: @@ -2155,7 +2232,7 @@ get_warnoptions(PyThreadState *tstate) if (warnoptions == NULL) { return NULL; } - if (sys_set_object_id(tstate, &PyId_warnoptions, warnoptions)) { + if (sys_set_object_id(tstate->interp, &PyId_warnoptions, warnoptions)) { Py_DECREF(warnoptions); return NULL; } @@ -2248,7 +2325,7 @@ get_xoptions(PyThreadState *tstate) if (xoptions == NULL) { return NULL; } - if (sys_set_object_id(tstate, &PyId__xoptions, xoptions)) { + if (sys_set_object_id(tstate->interp, &PyId__xoptions, xoptions)) { Py_DECREF(xoptions); return NULL; } @@ -2432,14 +2509,13 @@ static PyStructSequence_Field flags_fields[] = { {"no_site", "-S"}, {"ignore_environment", "-E"}, {"verbose", "-v"}, - /* {"unbuffered", "-u"}, */ - /* {"skip_first", "-x"}, */ {"bytes_warning", "-b"}, {"quiet", "-q"}, {"hash_randomization", "-R"}, {"isolated", "-I"}, {"dev_mode", "-X dev"}, {"utf8_mode", "-X utf8"}, + {"warn_default_encoding", "-X warn_default_encoding"}, {0} }; @@ -2447,24 +2523,29 @@ static PyStructSequence_Desc flags_desc = { "sys.flags", /* name */ flags__doc__, /* doc */ flags_fields, /* fields */ - 15 + 16 }; -static PyObject* -make_flags(PyThreadState *tstate) +static int +set_flags_from_config(PyInterpreterState *interp, PyObject *flags) { - PyInterpreterState *interp = tstate->interp; const PyPreConfig *preconfig = &interp->runtime->preconfig; const PyConfig *config = _PyInterpreterState_GetConfig(interp); - PyObject *seq = PyStructSequence_New(&FlagsType); - if (seq == NULL) { - return NULL; - } - - int pos = 0; -#define SetFlag(flag) \ - PyStructSequence_SET_ITEM(seq, pos++, PyLong_FromLong(flag)) + // _PySys_UpdateConfig() modifies sys.flags in-place: + // Py_XDECREF() is needed in this case. + Py_ssize_t pos = 0; +#define SetFlagObj(expr) \ + do { \ + PyObject *value = (expr); \ + if (value == NULL) { \ + return -1; \ + } \ + Py_XDECREF(PyStructSequence_GET_ITEM(flags, pos)); \ + PyStructSequence_SET_ITEM(flags, pos, value); \ + pos++; \ + } while (0) +#define SetFlag(expr) SetFlagObj(PyLong_FromLong(expr)) SetFlag(config->parser_debug); SetFlag(config->inspect); @@ -2475,23 +2556,35 @@ make_flags(PyThreadState *tstate) SetFlag(!config->site_import); SetFlag(!config->use_environment); SetFlag(config->verbose); - /* SetFlag(saw_unbuffered_flag); */ - /* SetFlag(skipfirstline); */ SetFlag(config->bytes_warning); SetFlag(config->quiet); SetFlag(config->use_hash_seed == 0 || config->hash_seed != 0); SetFlag(config->isolated); - PyStructSequence_SET_ITEM(seq, pos++, PyBool_FromLong(config->dev_mode)); + SetFlagObj(PyBool_FromLong(config->dev_mode)); SetFlag(preconfig->utf8_mode); + SetFlag(config->warn_default_encoding); +#undef SetFlagObj #undef SetFlag + return 0; +} - if (_PyErr_Occurred(tstate)) { - Py_DECREF(seq); + +static PyObject* +make_flags(PyInterpreterState *interp) +{ + PyObject *flags = PyStructSequence_New(&FlagsType); + if (flags == NULL) { + return NULL; + } + + if (set_flags_from_config(interp, flags) < 0) { + Py_DECREF(flags); return NULL; } - return seq; + return flags; } + PyDoc_STRVAR(version_info__doc__, "sys.version_info\n\ \n\ @@ -2647,18 +2740,7 @@ static struct PyModuleDef sysmodule = { }; /* Updating the sys namespace, returning NULL pointer on error */ -#define SET_SYS_FROM_STRING_BORROW(key, value) \ - do { \ - PyObject *v = (value); \ - if (v == NULL) { \ - goto err_occurred; \ - } \ - res = PyDict_SetItemString(sysdict, key, v); \ - if (res < 0) { \ - goto err_occurred; \ - } \ - } while (0) -#define SET_SYS_FROM_STRING(key, value) \ +#define SET_SYS(key, value) \ do { \ PyObject *v = (value); \ if (v == NULL) { \ @@ -2671,6 +2753,9 @@ static struct PyModuleDef sysmodule = { } \ } while (0) +#define SET_SYS_FROM_STRING(key, value) \ + SET_SYS(key, PyUnicode_FromString(value)) + static PyStatus _PySys_InitCore(PyThreadState *tstate, PyObject *sysdict) { @@ -2679,123 +2764,93 @@ _PySys_InitCore(PyThreadState *tstate, PyObject *sysdict) /* stdin/stdout/stderr are set in pylifecycle.c */ - SET_SYS_FROM_STRING_BORROW("__displayhook__", - PyDict_GetItemString(sysdict, "displayhook")); - SET_SYS_FROM_STRING_BORROW("__excepthook__", - PyDict_GetItemString(sysdict, "excepthook")); - SET_SYS_FROM_STRING_BORROW( - "__breakpointhook__", - PyDict_GetItemString(sysdict, "breakpointhook")); - SET_SYS_FROM_STRING_BORROW("__unraisablehook__", - PyDict_GetItemString(sysdict, "unraisablehook")); - - SET_SYS_FROM_STRING("version", - PyUnicode_FromString(Py_GetVersion())); - SET_SYS_FROM_STRING("hexversion", - PyLong_FromLong(PY_VERSION_HEX)); - SET_SYS_FROM_STRING("_git", - Py_BuildValue("(szz)", "CPython", _Py_gitidentifier(), - _Py_gitversion())); - SET_SYS_FROM_STRING("_framework", PyUnicode_FromString(_PYTHONFRAMEWORK)); - SET_SYS_FROM_STRING("api_version", - PyLong_FromLong(PYTHON_API_VERSION)); - SET_SYS_FROM_STRING("copyright", - PyUnicode_FromString(Py_GetCopyright())); - SET_SYS_FROM_STRING("platform", - PyUnicode_FromString(Py_GetPlatform())); - SET_SYS_FROM_STRING("maxsize", - PyLong_FromSsize_t(PY_SSIZE_T_MAX)); - SET_SYS_FROM_STRING("float_info", - PyFloat_GetInfo()); - SET_SYS_FROM_STRING("int_info", - PyLong_GetInfo()); +#define COPY_SYS_ATTR(tokey, fromkey) \ + SET_SYS(tokey, PyMapping_GetItemString(sysdict, fromkey)) + + COPY_SYS_ATTR("__displayhook__", "displayhook"); + COPY_SYS_ATTR("__excepthook__", "excepthook"); + COPY_SYS_ATTR("__breakpointhook__", "breakpointhook"); + COPY_SYS_ATTR("__unraisablehook__", "unraisablehook"); + +#undef COPY_SYS_ATTR + + SET_SYS_FROM_STRING("version", Py_GetVersion()); + SET_SYS("hexversion", PyLong_FromLong(PY_VERSION_HEX)); + SET_SYS("_git", Py_BuildValue("(szz)", "CPython", _Py_gitidentifier(), + _Py_gitversion())); + SET_SYS_FROM_STRING("_framework", _PYTHONFRAMEWORK); + SET_SYS("api_version", PyLong_FromLong(PYTHON_API_VERSION)); + SET_SYS_FROM_STRING("copyright", Py_GetCopyright()); + SET_SYS_FROM_STRING("platform", Py_GetPlatform()); + SET_SYS("maxsize", PyLong_FromSsize_t(PY_SSIZE_T_MAX)); + SET_SYS("float_info", PyFloat_GetInfo()); + SET_SYS("int_info", PyLong_GetInfo()); /* initialize hash_info */ if (Hash_InfoType.tp_name == NULL) { if (PyStructSequence_InitType2(&Hash_InfoType, &hash_info_desc) < 0) { goto type_init_failed; } } - SET_SYS_FROM_STRING("hash_info", - get_hash_info(tstate)); - SET_SYS_FROM_STRING("maxunicode", - PyLong_FromLong(0x10FFFF)); - SET_SYS_FROM_STRING("builtin_module_names", - list_builtin_module_names()); + SET_SYS("hash_info", get_hash_info(tstate)); + SET_SYS("maxunicode", PyLong_FromLong(0x10FFFF)); + SET_SYS("builtin_module_names", list_builtin_module_names()); + SET_SYS("stdlib_module_names", list_stdlib_module_names()); #if PY_BIG_ENDIAN - SET_SYS_FROM_STRING("byteorder", - PyUnicode_FromString("big")); + SET_SYS_FROM_STRING("byteorder", "big"); #else - SET_SYS_FROM_STRING("byteorder", - PyUnicode_FromString("little")); + SET_SYS_FROM_STRING("byteorder", "little"); #endif #ifdef MS_COREDLL - SET_SYS_FROM_STRING("dllhandle", - PyLong_FromVoidPtr(PyWin_DLLhModule)); - SET_SYS_FROM_STRING("winver", - PyUnicode_FromString(PyWin_DLLVersionString)); + SET_SYS("dllhandle", PyLong_FromVoidPtr(PyWin_DLLhModule)); + SET_SYS_FROM_STRING("winver", PyWin_DLLVersionString); #endif #ifdef ABIFLAGS - SET_SYS_FROM_STRING("abiflags", - PyUnicode_FromString(ABIFLAGS)); + SET_SYS_FROM_STRING("abiflags", ABIFLAGS); #endif /* version_info */ if (VersionInfoType.tp_name == NULL) { - if (PyStructSequence_InitType2(&VersionInfoType, - &version_info_desc) < 0) { + if (_PyStructSequence_InitType(&VersionInfoType, + &version_info_desc, + Py_TPFLAGS_DISALLOW_INSTANTIATION) < 0) { goto type_init_failed; } } version_info = make_version_info(tstate); - SET_SYS_FROM_STRING("version_info", version_info); - /* prevent user from creating new instances */ - VersionInfoType.tp_init = NULL; - VersionInfoType.tp_new = NULL; - res = PyDict_DelItemString(VersionInfoType.tp_dict, "__new__"); - if (res < 0 && _PyErr_ExceptionMatches(tstate, PyExc_KeyError)) { - _PyErr_Clear(tstate); - } + SET_SYS("version_info", version_info); /* implementation */ - SET_SYS_FROM_STRING("implementation", make_impl_info(version_info)); + SET_SYS("implementation", make_impl_info(version_info)); - /* flags */ + // sys.flags: updated in-place later by _PySys_UpdateConfig() if (FlagsType.tp_name == 0) { - if (PyStructSequence_InitType2(&FlagsType, &flags_desc) < 0) { + if (_PyStructSequence_InitType(&FlagsType, &flags_desc, + Py_TPFLAGS_DISALLOW_INSTANTIATION) < 0) { goto type_init_failed; } } - /* Set flags to their default values (updated by _PySys_InitMain()) */ - SET_SYS_FROM_STRING("flags", make_flags(tstate)); + SET_SYS("flags", make_flags(tstate->interp)); #if defined(MS_WINDOWS) /* getwindowsversion */ - if (WindowsVersionType.tp_name == 0) - if (PyStructSequence_InitType2(&WindowsVersionType, - &windows_version_desc) < 0) { + if (WindowsVersionType.tp_name == 0) { + if (_PyStructSequence_InitType(&WindowsVersionType, + &windows_version_desc, + Py_TPFLAGS_DISALLOW_INSTANTIATION) < 0) { goto type_init_failed; } - /* prevent user from creating new instances */ - WindowsVersionType.tp_init = NULL; - WindowsVersionType.tp_new = NULL; - assert(!_PyErr_Occurred(tstate)); - res = PyDict_DelItemString(WindowsVersionType.tp_dict, "__new__"); - if (res < 0 && _PyErr_ExceptionMatches(tstate, PyExc_KeyError)) { - _PyErr_Clear(tstate); } #endif /* float repr style: 0.03 (short) vs 0.029999999999999999 (legacy) */ #ifndef PY_NO_SHORT_FLOAT_REPR - SET_SYS_FROM_STRING("float_repr_style", - PyUnicode_FromString("short")); + SET_SYS_FROM_STRING("float_repr_style", "short"); #else - SET_SYS_FROM_STRING("float_repr_style", - PyUnicode_FromString("legacy")); + SET_SYS_FROM_STRING("float_repr_style", "legacy"); #endif - SET_SYS_FROM_STRING("thread_info", PyThread_GetInfo()); + SET_SYS("thread_info", PyThread_GetInfo()); /* initialize asyncgen_hooks */ if (AsyncGenHooksType.tp_name == NULL) { @@ -2805,6 +2860,11 @@ _PySys_InitCore(PyThreadState *tstate, PyObject *sysdict) } } + /* adding sys.path_hooks and sys.path_importer_cache */ + SET_SYS("meta_path", PyList_New(0)); + SET_SYS("path_importer_cache", PyDict_New()); + SET_SYS("path_hooks", PyList_New(0)); + if (_PyErr_Occurred(tstate)) { goto err_occurred; } @@ -2817,20 +2877,6 @@ err_occurred: return _PyStatus_ERR("can't initialize sys module"); } -/* Updating the sys namespace, returning integer error codes */ -#define SET_SYS_FROM_STRING_INT_RESULT(key, value) \ - do { \ - PyObject *v = (value); \ - if (v == NULL) \ - return -1; \ - res = PyDict_SetItemString(sysdict, key, v); \ - Py_DECREF(v); \ - if (res < 0) { \ - return res; \ - } \ - } while (0) - - static int sys_add_xoption(PyObject *opts, const wchar_t *s) { @@ -2885,42 +2931,38 @@ sys_create_xoptions_dict(const PyConfig *config) } +// Update sys attributes for a new PyConfig configuration. +// This function also adds attributes that _PySys_InitCore() didn't add. int -_PySys_InitMain(PyThreadState *tstate) +_PySys_UpdateConfig(PyThreadState *tstate) { - PyObject *sysdict = tstate->interp->sysdict; - const PyConfig *config = _PyInterpreterState_GetConfig(tstate->interp); + PyInterpreterState *interp = tstate->interp; + PyObject *sysdict = interp->sysdict; + const PyConfig *config = _PyInterpreterState_GetConfig(interp); int res; #define COPY_LIST(KEY, VALUE) \ - do { \ - PyObject *list = _PyWideStringList_AsList(&(VALUE)); \ - if (list == NULL) { \ - return -1; \ - } \ - SET_SYS_FROM_STRING_BORROW(KEY, list); \ - Py_DECREF(list); \ - } while (0) + SET_SYS(KEY, _PyWideStringList_AsList(&(VALUE))); #define SET_SYS_FROM_WSTR(KEY, VALUE) \ - do { \ - PyObject *str = PyUnicode_FromWideChar(VALUE, -1); \ - if (str == NULL) { \ - return -1; \ - } \ - SET_SYS_FROM_STRING_BORROW(KEY, str); \ - Py_DECREF(str); \ - } while (0) + SET_SYS(KEY, PyUnicode_FromWideChar(VALUE, -1)); - COPY_LIST("path", config->module_search_paths); +#define COPY_WSTR(SYS_ATTR, WSTR) \ + if (WSTR != NULL) { \ + SET_SYS_FROM_WSTR(SYS_ATTR, WSTR); \ + } - SET_SYS_FROM_WSTR("executable", config->executable); - SET_SYS_FROM_WSTR("_base_executable", config->base_executable); - SET_SYS_FROM_WSTR("prefix", config->prefix); - SET_SYS_FROM_WSTR("base_prefix", config->base_prefix); - SET_SYS_FROM_WSTR("exec_prefix", config->exec_prefix); - SET_SYS_FROM_WSTR("base_exec_prefix", config->base_exec_prefix); - SET_SYS_FROM_WSTR("platlibdir", config->platlibdir); + if (config->module_search_paths_set) { + COPY_LIST("path", config->module_search_paths); + } + + COPY_WSTR("executable", config->executable); + COPY_WSTR("_base_executable", config->base_executable); + COPY_WSTR("prefix", config->prefix); + COPY_WSTR("base_prefix", config->base_prefix); + COPY_WSTR("exec_prefix", config->exec_prefix); + COPY_WSTR("base_exec_prefix", config->base_exec_prefix); + COPY_WSTR("platlibdir", config->platlibdir); if (config->pycache_prefix != NULL) { SET_SYS_FROM_WSTR("pycache_prefix", config->pycache_prefix); @@ -2929,41 +2971,25 @@ _PySys_InitMain(PyThreadState *tstate) } COPY_LIST("argv", config->argv); + COPY_LIST("orig_argv", config->orig_argv); COPY_LIST("warnoptions", config->warnoptions); - PyObject *xoptions = sys_create_xoptions_dict(config); - if (xoptions == NULL) { - return -1; - } - SET_SYS_FROM_STRING_BORROW("_xoptions", xoptions); - Py_DECREF(xoptions); + SET_SYS("_xoptions", sys_create_xoptions_dict(config)); -#undef COPY_LIST #undef SET_SYS_FROM_WSTR +#undef COPY_LIST +#undef COPY_WSTR - - /* Set flags to their final values */ - SET_SYS_FROM_STRING_INT_RESULT("flags", make_flags(tstate)); - /* prevent user from creating new instances */ - FlagsType.tp_init = NULL; - FlagsType.tp_new = NULL; - res = PyDict_DelItemString(FlagsType.tp_dict, "__new__"); - if (res < 0) { - if (!_PyErr_ExceptionMatches(tstate, PyExc_KeyError)) { - return res; - } - _PyErr_Clear(tstate); + // sys.flags + PyObject *flags = _PySys_GetObject(interp, "flags"); // borrowed ref + if (flags == NULL) { + return -1; } - - SET_SYS_FROM_STRING_INT_RESULT("dont_write_bytecode", - PyBool_FromLong(!config->write_bytecode)); - - if (get_warnoptions(tstate) == NULL) { + if (set_flags_from_config(interp, flags) < 0) { return -1; } - if (get_xoptions(tstate) == NULL) - return -1; + SET_SYS("dont_write_bytecode", PyBool_FromLong(!config->write_bytecode)); if (_PyErr_Occurred(tstate)) { goto err_occurred; @@ -2975,15 +3001,14 @@ err_occurred: return -1; } +#undef SET_SYS #undef SET_SYS_FROM_STRING -#undef SET_SYS_FROM_STRING_BORROW -#undef SET_SYS_FROM_STRING_INT_RESULT /* Set up a preliminary stderr printer until we have enough infrastructure for the io module in place. - Use UTF-8/surrogateescape and ignore EAGAIN errors. */ + Use UTF-8/backslashreplace and ignore EAGAIN errors. */ static PyStatus _PySys_SetPreliminaryStderr(PyObject *sysdict) { @@ -3006,8 +3031,8 @@ error: } -/* Create sys module without all attributes: _PySys_InitMain() should be called - later to add remaining attributes. */ +/* Create sys module without all attributes. + _PySys_UpdateConfig() should be called later to add remaining attributes. */ PyStatus _PySys_Create(PyThreadState *tstate, PyObject **sysmod_p) { @@ -3100,8 +3125,8 @@ PySys_SetPath(const wchar_t *path) PyObject *v; if ((v = makepathobject(path, DELIM)) == NULL) Py_FatalError("can't create sys.path"); - PyThreadState *tstate = _PyThreadState_GET(); - if (sys_set_object_id(tstate, &PyId_path, v) != 0) { + PyInterpreterState *interp = _PyInterpreterState_GET(); + if (sys_set_object_id(interp, &PyId_path, v) != 0) { Py_FatalError("can't assign sys.path"); } Py_DECREF(v); @@ -3142,7 +3167,7 @@ PySys_SetArgvEx(int argc, wchar_t **argv, int updatepath) if (av == NULL) { Py_FatalError("no mem for sys.argv"); } - if (sys_set_object(tstate, "argv", av) != 0) { + if (sys_set_object_str(tstate->interp, "argv", av) != 0) { Py_DECREF(av); Py_FatalError("can't assign sys.argv"); } diff --git a/contrib/tools/python3/src/Python/thread.c b/contrib/tools/python3/src/Python/thread.c index a10f5728dc0..dfe28b6bdb6 100644 --- a/contrib/tools/python3/src/Python/thread.c +++ b/contrib/tools/python3/src/Python/thread.c @@ -75,6 +75,25 @@ PyThread_init_thread(void) PyThread__init_thread(); } +void +_PyThread_debug_deprecation(void) +{ +#ifdef Py_DEBUG + if (thread_debug) { + // Flush previous dprintf() logs + fflush(stdout); + if (PyErr_WarnEx(PyExc_DeprecationWarning, + "The threading debug (PYTHONTHREADDEBUG environment " + "variable) is deprecated and will be removed " + "in Python 3.12", + 0)) + { + _PyErr_WriteUnraisableMsg("at Python startup", NULL); + } + } +#endif +} + #if defined(_POSIX_THREADS) # define PYTHREAD_NAME "pthread" # include "thread_pthread.h" diff --git a/contrib/tools/python3/src/Python/thread_pthread.h b/contrib/tools/python3/src/Python/thread_pthread.h index 83974b4c0ca..35b9810aa37 100644 --- a/contrib/tools/python3/src/Python/thread_pthread.h +++ b/contrib/tools/python3/src/Python/thread_pthread.h @@ -32,18 +32,17 @@ #define THREAD_STACK_SIZE 0 /* use default stack size */ #endif -/* The default stack size for new threads on OSX and BSD is small enough that +/* The default stack size for new threads on BSD is small enough that * we'll get hard crashes instead of 'maximum recursion depth exceeded' * exceptions. * - * The default stack sizes below are the empirically determined minimal stack + * The default stack size below is the empirically determined minimal stack * sizes where a simple recursive function doesn't cause a hard crash. + * + * For macOS the value of THREAD_STACK_SIZE is determined in configure.ac + * as it also depends on the other configure options like chosen sanitizer + * runtimes. */ -#if defined(__APPLE__) && defined(THREAD_STACK_SIZE) && THREAD_STACK_SIZE == 0 -#undef THREAD_STACK_SIZE -/* Note: This matches the value of -Wl,-stack_size in configure.ac */ -#define THREAD_STACK_SIZE 0x1000000 -#endif #if defined(__FreeBSD__) && defined(THREAD_STACK_SIZE) && THREAD_STACK_SIZE == 0 #undef THREAD_STACK_SIZE #define THREAD_STACK_SIZE 0x400000 @@ -62,6 +61,10 @@ # define THREAD_STACK_SIZE 0x800000 # endif #endif +#if defined(__VXWORKS__) && defined(THREAD_STACK_SIZE) && THREAD_STACK_SIZE == 0 +#undef THREAD_STACK_SIZE +#define THREAD_STACK_SIZE 0x100000 +#endif /* for safety, ensure a viable minimum stacksize */ #define THREAD_STACK_MIN 0x8000 /* 32 KiB */ #else /* !_POSIX_THREAD_ATTR_STACKSIZE */ diff --git a/contrib/tools/python3/src/Python/traceback.c b/contrib/tools/python3/src/Python/traceback.c index 23d0e38e737..7d6f7f435a6 100644 --- a/contrib/tools/python3/src/Python/traceback.c +++ b/contrib/tools/python3/src/Python/traceback.c @@ -4,6 +4,7 @@ #include "Python.h" #include "code.h" +#include "pycore_interp.h" // PyInterpreterState.gc #include "frameobject.h" // PyFrame_GetBack() #include "structmember.h" // PyMemberDef #include "osdefs.h" // SEP @@ -147,7 +148,7 @@ static PyMethodDef tb_methods[] = { }; static PyMemberDef tb_memberlist[] = { - {"tb_frame", T_OBJECT, OFF(tb_frame), READONLY|READ_RESTRICTED}, + {"tb_frame", T_OBJECT, OFF(tb_frame), READONLY|PY_AUDIT_READ}, {"tb_lasti", T_INT, OFF(tb_lasti), READONLY}, {"tb_lineno", T_INT, OFF(tb_lineno), READONLY}, {NULL} /* Sentinel */ @@ -233,7 +234,7 @@ _PyTraceBack_FromFrame(PyObject *tb_next, PyFrameObject *frame) assert(tb_next == NULL || PyTraceBack_Check(tb_next)); assert(frame != NULL); - return tb_create_raw((PyTracebackObject *)tb_next, frame, frame->f_lasti, + return tb_create_raw((PyTracebackObject *)tb_next, frame, frame->f_lasti*sizeof(_Py_CODEUNIT), PyFrame_GetLineNumber(frame)); } @@ -419,12 +420,12 @@ _Py_DisplaySourceLine(PyObject *f, PyObject *filename, int lineno, int indent) if (lseek(fd, 0, SEEK_SET) == (off_t)-1) { Py_DECREF(io); Py_DECREF(binary); - PyMem_FREE(found_encoding); + PyMem_Free(found_encoding); return 0; } fob = _PyObject_CallMethodId(io, &PyId_TextIOWrapper, "Os", binary, encoding); Py_DECREF(io); - PyMem_FREE(found_encoding); + PyMem_Free(found_encoding); if (fob == NULL) { PyErr_Clear(); @@ -628,12 +629,12 @@ PyTraceBack_Print(PyObject *v, PyObject *f) This function is signal safe. */ void -_Py_DumpDecimal(int fd, unsigned long value) +_Py_DumpDecimal(int fd, size_t value) { /* maximum number of characters required for output of %lld or %p. We need at most ceil(log10(256)*SIZEOF_LONG_LONG) digits, plus 1 for the null byte. 53/22 is an upper bound for log10(256). */ - char buffer[1 + (sizeof(unsigned long)*53-1) / 22 + 1]; + char buffer[1 + (sizeof(size_t)*53-1) / 22 + 1]; char *ptr, *end; end = &buffer[Py_ARRAY_LENGTH(buffer) - 1]; @@ -649,15 +650,12 @@ _Py_DumpDecimal(int fd, unsigned long value) _Py_write_noraise(fd, ptr, end - ptr); } -/* Format an integer in range [0; 0xffffffff] to hexadecimal of 'width' digits, - and write it into the file fd. - - This function is signal safe. */ - +/* Format an integer as hexadecimal with width digits into fd file descriptor. + The function is signal safe. */ void -_Py_DumpHexadecimal(int fd, unsigned long value, Py_ssize_t width) +_Py_DumpHexadecimal(int fd, uintptr_t value, Py_ssize_t width) { - char buffer[sizeof(unsigned long) * 2 + 1], *ptr, *end; + char buffer[sizeof(uintptr_t) * 2 + 1], *ptr, *end; const Py_ssize_t size = Py_ARRAY_LENGTH(buffer) - 1; if (width > size) @@ -788,11 +786,10 @@ dump_frame(int fd, PyFrameObject *frame) PUTS(fd, "???"); } - /* PyFrame_GetLineNumber() was introduced in Python 2.7.0 and 3.2.0 */ - int lineno = PyCode_Addr2Line(code, frame->f_lasti); + int lineno = PyFrame_GetLineNumber(frame); PUTS(fd, ", line "); if (lineno >= 0) { - _Py_DumpDecimal(fd, (unsigned long)lineno); + _Py_DumpDecimal(fd, (size_t)lineno); } else { PUTS(fd, "???"); @@ -826,7 +823,7 @@ dump_traceback(int fd, PyThreadState *tstate, int write_header) // not modify Python objects. frame = tstate->frame; if (frame == NULL) { - PUTS(fd, "<no Python frame>\n"); + PUTS(fd, " <no Python frame>\n"); return; } @@ -940,6 +937,9 @@ _Py_DumpTracebackThreads(int fd, PyInterpreterState *interp, break; } write_thread_id(fd, tstate, tstate == current_tstate); + if (tstate == current_tstate && tstate->interp->gc.collecting) { + PUTS(fd, " Garbage-collecting\n"); + } dump_traceback(fd, tstate, 0); tstate = PyThreadState_Next(tstate); nthreads++; |
