/external/python/cpython2/Include/ |
D | Python-ast.h | 9 typedef struct _expr *expr_ty; typedef 52 expr_ty body; 87 expr_ty value; 96 expr_ty value; 100 expr_ty target; 102 expr_ty value; 106 expr_ty dest; 112 expr_ty target; 113 expr_ty iter; 119 expr_ty test; [all …]
|
/external/python/cpython3/Include/ |
D | Python-ast.h | 18 typedef struct _expr *expr_ty; typedef 65 expr_ty body; 70 expr_ty returns; 92 expr_ty returns; 101 expr_ty returns; 114 expr_ty value; 123 expr_ty value; 128 expr_ty target; 130 expr_ty value; 134 expr_ty target; [all …]
|
D | ast.h | 24 PyAPI_FUNC(PyObject *) _PyAST_ExprAsUnicode(expr_ty);
|
/external/python/cpython3/Python/ |
D | ast_opt.c | 8 make_const(expr_ty node, PyObject *val, PyArena *arena) in make_const() 39 fold_unaryop(expr_ty node, PyArena *arena, _PyASTOptimizeState *state) in fold_unaryop() 41 expr_ty arg = node->v.UnaryOp.operand; in fold_unaryop() 216 fold_binop(expr_ty node, PyArena *arena, _PyASTOptimizeState *state) in fold_binop() 218 expr_ty lhs, rhs; in fold_binop() 277 expr_ty e = (expr_ty)asdl_seq_GET(elts, i); in make_const_tuple() 289 expr_ty e = (expr_ty)asdl_seq_GET(elts, i); in make_const_tuple() 298 fold_tuple(expr_ty node, PyArena *arena, _PyASTOptimizeState *state) in fold_tuple() 310 fold_subscr(expr_ty node, PyArena *arena, _PyASTOptimizeState *state) in fold_subscr() 313 expr_ty arg, idx; in fold_subscr() [all …]
|
D | ast_unparse.c | 15 expr_as_unicode(expr_ty e, int level); 17 append_ast_expr(_PyUnicodeWriter *writer, expr_ty e, int level); 19 append_joinedstr(_PyUnicodeWriter *writer, expr_ty e, bool is_format_spec); 21 append_formattedvalue(_PyUnicodeWriter *writer, expr_ty e); 23 append_ast_slice(_PyUnicodeWriter *writer, expr_ty e); 117 append_ast_boolop(_PyUnicodeWriter *writer, expr_ty e, int level) in append_ast_boolop() 131 APPEND_EXPR((expr_ty)asdl_seq_GET(values, i), pr + 1); in append_ast_boolop() 139 append_ast_binop(_PyUnicodeWriter *writer, expr_ty e, int level) in append_ast_binop() 174 append_ast_unaryop(_PyUnicodeWriter *writer, expr_ty e, int level) in append_ast_unaryop() 233 APPEND_EXPR((expr_ty)asdl_seq_GET(args->defaults, di), PR_TEST); in append_ast_args() [all …]
|
D | ast.c | 22 static int validate_expr(expr_ty, expr_context_ty); 178 validate_expr(expr_ty exp, expr_context_ty ctx) in validate_expr() 515 expr_ty expr = asdl_seq_GET(exprs, i); in validate_exprs() 567 static expr_ty ast_for_expr(struct compiling *, const node *); 572 static expr_ty ast_for_testlist(struct compiling *, const node *); 579 static expr_ty ast_for_call(struct compiling *, const node *, expr_ty, 583 static expr_ty parsestrplus(struct compiling *, const node *n); 774 expr_ty ret, arg; in PyAST_FromNodeObject() 837 expr_ty testlist_ast; in PyAST_FromNodeObject() 1022 static expr_ty [all …]
|
D | Python-ast.c | 1885 static int obj2ast_expr(astmodulestate *state, PyObject* obj, expr_ty* out, 1940 Expression(expr_ty body, PyArena *arena) in Expression() 1957 FunctionType(asdl_seq * argtypes, expr_ty returns, PyArena *arena) in FunctionType() 1976 decorator_list, expr_ty returns, string type_comment, int lineno, in FunctionDef() 2009 * decorator_list, expr_ty returns, string type_comment, int in AsyncFunctionDef() 2069 Return(expr_ty value, int lineno, int col_offset, int end_lineno, int in Return() 2103 Assign(asdl_seq * targets, expr_ty value, string type_comment, int lineno, int in Assign() 2127 AugAssign(expr_ty target, operator_ty op, expr_ty value, int lineno, int in AugAssign() 2161 AnnAssign(expr_ty target, expr_ty annotation, expr_ty value, int simple, int in AnnAssign() 2192 For(expr_ty target, expr_ty iter, asdl_seq * body, asdl_seq * orelse, string in For() [all …]
|
D | compile.c | 194 static int compiler_visit_expr(struct compiler *, expr_ty); 197 static int compiler_subscript(struct compiler *, expr_ty); 198 static int compiler_slice(struct compiler *, expr_ty); 202 static int expr_constant(expr_ty); 217 expr_ty elt, expr_ty val, int type); 223 expr_ty elt, expr_ty val, int type); 1956 VISIT(c, expr, (expr_ty)asdl_seq_GET(decos, i)); in compiler_decorators() 1974 expr_ty default_ = asdl_seq_GET(kw_defaults, i); in compiler_visit_kwonlydefaults() 2019 compiler_visit_annexpr(struct compiler *c, expr_ty annotation) in compiler_visit_annexpr() 2027 expr_ty annotation, PyObject *names) in compiler_visit_argannotation() [all …]
|
D | symtable.c | 195 static int symtable_visit_expr(struct symtable *st, expr_ty s); 196 static int symtable_visit_genexp(struct symtable *st, expr_ty s); 197 static int symtable_visit_listcomp(struct symtable *st, expr_ty s); 198 static int symtable_visit_setcomp(struct symtable *st, expr_ty s); 199 static int symtable_visit_dictcomp(struct symtable *st, expr_ty s); 208 static int symtable_visit_annotations(struct symtable *st, arguments_ty, expr_ty); 1234 expr_ty e_name = s->v.AnnAssign.target; in symtable_visit_stmt() 1435 symtable_extend_namedexpr_scope(struct symtable *st, expr_ty e) in symtable_extend_namedexpr_scope() 1507 symtable_handle_namedexpr(struct symtable *st, expr_ty e) in symtable_handle_namedexpr() 1528 symtable_visit_expr(struct symtable *st, expr_ty e) in symtable_visit_expr() [all …]
|
/external/python/cpython3/Parser/pegen/ |
D | pegen.h | 81 expr_ty expr; 85 expr_ty key; 86 expr_ty value; 91 expr_ty value; 121 int _PyPegen_lookahead_with_name(int, expr_ty (func)(Parser *), Parser *); 122 int _PyPegen_lookahead_with_string(int , expr_ty (func)(Parser *, const char*), Parser *, const cha… 127 expr_ty _PyPegen_expect_soft_keyword(Parser *p, const char *keyword); 130 expr_ty _PyPegen_name_token(Parser *p); 131 expr_ty _PyPegen_number_token(Parser *p); 133 const char *_PyPegen_get_expr_name(expr_ty); [all …]
|
D | parse_string.c | 339 static expr_ty 343 expr_ty expr = NULL; in fstring_compile_expr() 347 expr_ty result = NULL; in fstring_compile_expr() 516 static expr_ty 537 PyObject **expr_text, expr_ty *expression, Token *first_token, in fstring_find_expr() 544 expr_ty simple_expression; in fstring_find_expr() 545 expr_ty format_spec = NULL; /* Optional format specifier. */ in fstring_find_expr() 851 PyObject **expr_text, expr_ty *expression, in fstring_find_literal_and_expr() 923 ExprList_Append(ExprList *l, expr_ty exp) in ExprList_Append() 935 l->p = PyMem_Malloc(sizeof(expr_ty) * new_size); in ExprList_Append() [all …]
|
D | parse_string.h | 21 expr_ty *p; /* Pointer to the memory we're actually 24 expr_ty data[EXPRLIST_N_CACHED]; 43 expr_ty _PyPegen_FstringParser_Finish(Parser *, FstringParser *, Token *, Token *);
|
D | parse.c | 398 static expr_ty fstring_rule(Parser *p); 421 static expr_ty dotted_name_rule(Parser *p); 447 static expr_ty annotation_rule(Parser *p); 448 static expr_ty default_rule(Parser *p); 453 static expr_ty star_expressions_rule(Parser *p); 454 static expr_ty star_expression_rule(Parser *p); 456 static expr_ty star_named_expression_rule(Parser *p); 457 static expr_ty named_expression_rule(Parser *p); 458 static expr_ty annotated_rhs_rule(Parser *p); 459 static expr_ty expressions_rule(Parser *p); [all …]
|
D | pegen.c | 160 _PyPegen_get_expr_name(expr_ty e) in _PyPegen_get_expr_name() 743 _PyPegen_lookahead_with_name(int positive, expr_ty (func)(Parser *), Parser *p) in _PyPegen_lookahead_with_name() 752 _PyPegen_lookahead_with_string(int positive, expr_ty (func)(Parser *, const char*), Parser *p, cons… in _PyPegen_lookahead_with_string() 795 expr_ty 833 expr_ty 933 expr_ty 1358 expr_ty 1359 _PyPegen_join_names_with_dot(Parser *p, expr_ty first_name, expr_ty second_name) in _PyPegen_join_names_with_dot() 1461 expr_ty e = asdl_seq_GET(seq, i); in _PyPegen_map_names_to_ids() 1469 _PyPegen_cmpop_expr_pair(Parser *p, cmpop_ty cmpop, expr_ty expr) in _PyPegen_cmpop_expr_pair() [all …]
|
/external/python/cpython3/Grammar/ |
D | python.gram | 34 fstring[expr_ty]: star_expressions 145 (b) ? ((expr_ty) b)->v.Name.id : NULL, 151 (b) ? ((expr_ty) b)->v.Name.id : NULL, 153 dotted_name[expr_ty]: 194 _Py_ExceptHandler(e, (t) ? ((expr_ty) t)->v.Name.id : NULL, b, EXTRA) } 284 annotation[expr_ty]: ':' a=expression { a } 285 default[expr_ty]: '=' a=expression { a } 295 (b) ? ((expr_ty) b)->v.Call.args : NULL, 296 (b) ? ((expr_ty) b)->v.Call.keywords : NULL, 304 star_expressions[expr_ty]: [all …]
|
/external/python/cpython2/Python/ |
D | ast.c | 27 static expr_ty ast_for_expr(struct compiling *, const node *); 32 static expr_ty ast_for_testlist(struct compiling *, const node *); 34 static expr_ty ast_for_testlist_comp(struct compiling *, const node *); 37 static expr_ty ast_for_call(struct compiling *, const node *, expr_ty); 272 expr_ty testlist_ast; in PyAST_FromNode() 370 set_context(struct compiling *c, expr_ty e, expr_context_ty ctx, const node *n) in set_context() 480 if (!set_context(c, (expr_ty)asdl_seq_GET(s, i), ctx, n)) in set_context() 582 expr_ty expression; in seq_for_testlist() 607 static expr_ty 611 expr_ty result; in compiler_complex_args() [all …]
|
D | Python-ast.c | 971 static int obj2ast_expr(PyObject* obj, expr_ty* out, PyArena* arena); 1012 Expression(expr_ty body, PyArena *arena) in Expression() 1092 Return(expr_ty value, int lineno, int col_offset, PyArena *arena) in Return() 1120 Assign(asdl_seq * targets, expr_ty value, int lineno, int col_offset, PyArena in Assign() 1141 AugAssign(expr_ty target, operator_ty op, expr_ty value, int lineno, int in AugAssign() 1173 Print(expr_ty dest, asdl_seq * values, bool nl, int lineno, int col_offset, in Print() 1190 For(expr_ty target, expr_ty iter, asdl_seq * body, asdl_seq * orelse, int in For() 1218 While(expr_ty test, asdl_seq * body, asdl_seq * orelse, int lineno, int in While() 1240 If(expr_ty test, asdl_seq * body, asdl_seq * orelse, int lineno, int in If() 1262 With(expr_ty context_expr, expr_ty optional_vars, asdl_seq * body, int lineno, in With() [all …]
|
D | compile.c | 164 static int compiler_visit_expr(struct compiler *, expr_ty); 177 static int expr_constant(expr_ty e); 1322 VISIT(c, expr, (expr_ty)asdl_seq_GET(decos, i)); in compiler_decorators() 1334 expr_ty arg = (expr_ty)asdl_seq_GET(args->args, i); in compiler_arguments() 1471 compiler_ifexp(struct compiler *c, expr_ty e) in compiler_ifexp() 1493 compiler_lambda(struct compiler *c, expr_ty e) in compiler_lambda() 1552 expr_ty e = (expr_ty)asdl_seq_GET(s->v.Print.values, i); in compiler_print() 2108 (expr_ty)asdl_seq_GET(s->v.Assign.targets, i)); in compiler_visit_stmt() 2439 compiler_boolop(struct compiler *c, expr_ty e) in compiler_boolop() 2457 VISIT(c, expr, (expr_ty)asdl_seq_GET(s, i)); in compiler_boolop() [all …]
|
D | symtable.c | 171 static int symtable_visit_expr(struct symtable *st, expr_ty s); 172 static int symtable_visit_listcomp(struct symtable *st, expr_ty e); 173 static int symtable_visit_genexp(struct symtable *st, expr_ty s); 174 static int symtable_visit_setcomp(struct symtable *st, expr_ty e); 175 static int symtable_visit_dictcomp(struct symtable *st, expr_ty e); 1190 symtable_visit_expr(struct symtable *st, expr_ty e) in symtable_visit_expr() 1322 expr_ty arg = (expr_ty)asdl_seq_GET(args, i); in symtable_visit_params() 1358 expr_ty arg = (expr_ty)asdl_seq_GET(args, i); in symtable_visit_params_nested() 1502 symtable_handle_comprehension(struct symtable *st, expr_ty e, in symtable_handle_comprehension() 1504 expr_ty elt, expr_ty value) in symtable_handle_comprehension() [all …]
|
D | future.c | 106 expr_ty e = s->v.Expr.value; in future_parse()
|