diff options
author | Damien George <damien.p.george@gmail.com> | 2016-04-13 15:21:47 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2016-04-13 15:26:39 +0100 |
commit | eacbd7aeba3bdd634b56af544e40da87779f4a95 (patch) | |
tree | a48308a5110a11d162ee05803886f7b690615e88 /py/compile.c | |
parent | 81ebba7e0236163b7594938201bf3a6b802ebfaa (diff) |
py: Fix constant folding and inline-asm to work with new async grammar.
Diffstat (limited to 'py/compile.c')
-rw-r--r-- | py/compile.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/py/compile.c b/py/compile.c index 7366ee1fb..d40d8a1ff 100644 --- a/py/compile.c +++ b/py/compile.c @@ -1402,8 +1402,7 @@ STATIC void compile_for_stmt(compiler_t *comp, mp_parse_node_struct_t *pns) { mp_parse_node_struct_t *pns_it = (mp_parse_node_struct_t*)pns->nodes[1]; if (MP_PARSE_NODE_IS_ID(pns_it->nodes[0]) && MP_PARSE_NODE_LEAF_ARG(pns_it->nodes[0]) == MP_QSTR_range - && MP_PARSE_NODE_IS_STRUCT_KIND(pns_it->nodes[1], PN_trailer_paren) - && MP_PARSE_NODE_IS_NULL(pns_it->nodes[2])) { + && MP_PARSE_NODE_IS_STRUCT_KIND(pns_it->nodes[1], PN_trailer_paren)) { mp_parse_node_t pn_range_args = ((mp_parse_node_struct_t*)pns_it->nodes[1])->nodes[0]; mp_parse_node_t *args; int n_args = mp_parse_node_extract_list(&pn_range_args, PN_arglist, &args); @@ -3186,7 +3185,6 @@ STATIC void compile_scope_inline_asm(compiler_t *comp, scope_t *scope, pass_kind if (!MP_PARSE_NODE_IS_STRUCT_KIND(pns2->nodes[1], PN_trailer_paren)) { goto not_an_instruction; } - assert(MP_PARSE_NODE_IS_NULL(pns2->nodes[2])); // parse node looks like an instruction // get instruction name and args |