diff options
author | Damien George <damien.p.george@gmail.com> | 2014-07-17 12:37:56 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2014-07-17 12:37:56 +0100 |
commit | a4022c92f037e38822f4652ee142670193bafcf4 (patch) | |
tree | a156cf69b4977a156e2c8e9e499018e0cdb19675 | |
parent | a50494ab68802ccab5fc2573f5485e4c7b5bfdc8 (diff) | |
download | micropython-a4022c92f037e38822f4652ee142670193bafcf4.tar.gz micropython-a4022c92f037e38822f4652ee142670193bafcf4.zip |
py, inline asm: Change "and" op name to "and_" to avoid keyword clash.
Addresses issue #753.
-rw-r--r-- | py/emitinlinethumb.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/py/emitinlinethumb.c b/py/emitinlinethumb.c index 435e1b64d9..3d0efd5645 100644 --- a/py/emitinlinethumb.c +++ b/py/emitinlinethumb.c @@ -315,7 +315,7 @@ STATIC void emit_inline_thumb_op(emit_inline_asm_t *emit, qstr op, int n_args, m uint reg_dest = get_arg_reg(emit, op_str, pn_args[0], 15); uint reg_src = get_arg_reg(emit, op_str, pn_args[1], 15); asm_thumb_mov_reg_reg(emit->as, reg_dest, reg_src); - } else if (strcmp(op_str, "and") == 0) { + } else if (strcmp(op_str, "and_") == 0) { op_code = ASM_THUMB_FORMAT_4_AND; uint reg_dest, reg_src; op_format_4: @@ -323,7 +323,6 @@ STATIC void emit_inline_thumb_op(emit_inline_asm_t *emit, qstr op, int n_args, m reg_src = get_arg_reg(emit, op_str, pn_args[1], 7); asm_thumb_format_4(emit->as, op_code, reg_dest, reg_src); // TODO probably uses less ROM if these ops are in a lookup table - } else if (strcmp(op_str, "and") == 0) { op_code = ASM_THUMB_FORMAT_4_AND; goto op_format_4; } else if (strcmp(op_str, "eor") == 0) { op_code = ASM_THUMB_FORMAT_4_EOR; goto op_format_4; } else if (strcmp(op_str, "lsl") == 0) { op_code = ASM_THUMB_FORMAT_4_LSL; goto op_format_4; } else if (strcmp(op_str, "lsr") == 0) { op_code = ASM_THUMB_FORMAT_4_LSR; goto op_format_4; |