diff options
author | Damien George <damien.p.george@gmail.com> | 2018-09-15 12:15:19 +1000 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2018-09-15 12:17:09 +1000 |
commit | 3751512e9db7ebda9ff06a710038c742ac91126c (patch) | |
tree | cf984a0c3ff2c2f64a781208dfaab2bbaeff278d /py | |
parent | abb536da499498b94d5c3dc7379fd5136d273f2d (diff) | |
download | micropython-3751512e9db7ebda9ff06a710038c742ac91126c.tar.gz micropython-3751512e9db7ebda9ff06a710038c742ac91126c.zip |
py/emit: Move MP_EMIT_OPT_xxx enums from compile.h to emitglue.h.
Diffstat (limited to 'py')
-rw-r--r-- | py/compile.h | 9 | ||||
-rw-r--r-- | py/emitglue.h | 9 | ||||
-rw-r--r-- | py/scope.h | 2 |
3 files changed, 10 insertions, 10 deletions
diff --git a/py/compile.h b/py/compile.h index 3297e83aeb..99a17a8d1e 100644 --- a/py/compile.h +++ b/py/compile.h @@ -30,15 +30,6 @@ #include "py/parse.h" #include "py/emitglue.h" -// These must fit in 8 bits; see scope.h -enum { - MP_EMIT_OPT_NONE, - MP_EMIT_OPT_BYTECODE, - MP_EMIT_OPT_NATIVE_PYTHON, - MP_EMIT_OPT_VIPER, - MP_EMIT_OPT_ASM, -}; - // the compiler will raise an exception if an error occurred // the compiler will clear the parse tree before it returns mp_obj_t mp_compile(mp_parse_tree_t *parse_tree, qstr source_file, uint emit_opt, bool is_repl); diff --git a/py/emitglue.h b/py/emitglue.h index 0830a0d5c8..d39a10ee94 100644 --- a/py/emitglue.h +++ b/py/emitglue.h @@ -30,6 +30,15 @@ // These variables and functions glue the code emitters to the runtime. +// These must fit in 8 bits; see scope.h +enum { + MP_EMIT_OPT_NONE, + MP_EMIT_OPT_BYTECODE, + MP_EMIT_OPT_NATIVE_PYTHON, + MP_EMIT_OPT_VIPER, + MP_EMIT_OPT_ASM, +}; + typedef enum { MP_CODE_UNUSED, MP_CODE_RESERVED, diff --git a/py/scope.h b/py/scope.h index e3b6a57c79..d6742b4c96 100644 --- a/py/scope.h +++ b/py/scope.h @@ -75,7 +75,7 @@ typedef struct _scope_t { uint16_t simple_name; // a qstr mp_raw_code_t *raw_code; uint8_t scope_flags; // see runtime0.h - uint8_t emit_options; // see compile.h + uint8_t emit_options; // see emitglue.h uint16_t num_pos_args; uint16_t num_kwonly_args; uint16_t num_def_pos_args; |