ret_expr -> return_expr

This matches Python's AST a little more closely
This commit is contained in:
rocky
2022-01-03 21:51:32 -05:00
parent 7f42694c25
commit deea74b6a8
20 changed files with 92 additions and 92 deletions

View File

@@ -5,7 +5,7 @@
# fully handle Python 3.5's jump optimization
# So in 3.5, for now, we allow:
#
# return_stmt ::= ret_expr RETURN_END_IF
# return_stmt ::= return_expr RETURN_END_IF
# and you see that in the grammar rules for below.
# For other pythons the RETURN_END_IF may be a

View File

@@ -1,9 +1,9 @@
# Tests:
# ret_expr_or_cond ::= ret_expr
# if_exp_ret ::= expr POP_JUMP_IF_FALSE expr RETURN_END_IF ret_expr_or_cond
# ret_expr_or_cond ::= if_exp_ret
# ret_or ::= expr JUMP_IF_TRUE_OR_POP ret_expr_or_cond COME_FROM
# return_expr_or_cond ::= return_expr
# if_exp_ret ::= expr POP_JUMP_IF_FALSE expr RETURN_END_IF return_expr_or_cond
# return_expr_or_cond ::= if_exp_ret
# ret_or ::= expr JUMP_IF_TRUE_OR_POP return_expr_or_cond COME_FROM
# See https://github.com/rocky/python-uncompyle6/issues/5