summaryrefslogtreecommitdiff
path: root/py/runtime0.h
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2015-06-13 22:00:10 +0100
committerDamien George <damien.p.george@gmail.com>2015-06-13 23:36:30 +0100
commitc5029bcbf37fd1a3fb145d9fa9e4a5094478f17b (patch)
tree3f5f37bbf827d9b1ca302a5492e6522090998076 /py/runtime0.h
parent6f4952004207a249a437dc822c5252422f63cc69 (diff)
py: Add MP_BINARY_OP_DIVMOD to simplify and consolidate divmod builtin.
Diffstat (limited to 'py/runtime0.h')
-rw-r--r--py/runtime0.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/py/runtime0.h b/py/runtime0.h
index 65c7df0ae..cdcb6e3dc 100644
--- a/py/runtime0.h
+++ b/py/runtime0.h
@@ -74,29 +74,30 @@ typedef enum {
MP_BINARY_OP_MODULO,
MP_BINARY_OP_POWER,
+ MP_BINARY_OP_DIVMOD, // not emitted by the compiler but supported by the runtime
MP_BINARY_OP_INPLACE_OR,
MP_BINARY_OP_INPLACE_XOR,
- MP_BINARY_OP_INPLACE_AND,
+ MP_BINARY_OP_INPLACE_AND,
MP_BINARY_OP_INPLACE_LSHIFT,
MP_BINARY_OP_INPLACE_RSHIFT,
MP_BINARY_OP_INPLACE_ADD,
MP_BINARY_OP_INPLACE_SUBTRACT,
- MP_BINARY_OP_INPLACE_MULTIPLY,
+ MP_BINARY_OP_INPLACE_MULTIPLY,
MP_BINARY_OP_INPLACE_FLOOR_DIVIDE,
MP_BINARY_OP_INPLACE_TRUE_DIVIDE,
MP_BINARY_OP_INPLACE_MODULO,
MP_BINARY_OP_INPLACE_POWER,
+
// these should return a bool
MP_BINARY_OP_LESS,
-
MP_BINARY_OP_MORE,
MP_BINARY_OP_EQUAL,
MP_BINARY_OP_LESS_EQUAL,
MP_BINARY_OP_MORE_EQUAL,
- MP_BINARY_OP_NOT_EQUAL,
+ MP_BINARY_OP_NOT_EQUAL,
MP_BINARY_OP_IN,
MP_BINARY_OP_IS,
MP_BINARY_OP_EXCEPTION_MATCH,