summaryrefslogtreecommitdiffstatshomepage
path: root/py/parse.c
diff options
context:
space:
mode:
authorDamien <damien.p.george@gmail.com>2013-10-05 23:17:28 +0100
committerDamien <damien.p.george@gmail.com>2013-10-05 23:17:28 +0100
commit826005c60b3c22c468ec21e995844037aafd6f99 (patch)
tree291ba04ec4ab625316babc91bcdeebf5634150a3 /py/parse.c
parent5bfb759980c3891a9401d877fb225770146c79df (diff)
downloadmicropython-826005c60b3c22c468ec21e995844037aafd6f99.tar.gz
micropython-826005c60b3c22c468ec21e995844037aafd6f99.zip
Add support for inline thumb assembly.
Diffstat (limited to 'py/parse.c')
-rw-r--r--py/parse.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/py/parse.c b/py/parse.c
index 94a5a5d9ca..74bfdf48d6 100644
--- a/py/parse.c
+++ b/py/parse.c
@@ -228,7 +228,7 @@ static void push_result_token(parser_t *parser, const py_lexer_t *lex) {
}
if (dec) {
pn = py_parse_node_new_leaf(PY_PARSE_NODE_DECIMAL, qstr_from_strn_copy(str, len));
- } else if (small_int && -0x10000 <= int_val && int_val <= 0xffff) {
+ } else if (small_int && -0x10000000 <= int_val && int_val <= 0xfffffff) { // XXX check this range formula!
pn = py_parse_node_new_leaf(PY_PARSE_NODE_SMALL_INT, int_val);
} else {
pn = py_parse_node_new_leaf(PY_PARSE_NODE_INTEGER, qstr_from_strn_copy(str, len));