diff options
author | stijn <stinos@zoho.com> | 2015-02-14 18:44:31 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2015-03-20 23:13:32 +0000 |
commit | 3cc17c69ffd64dca55fe613f6e931585d8893c0d (patch) | |
tree | 73fe88917c5b65ac3fdb679e5aee7338ed2fa66b /py/obj.h | |
parent | 07b8dc68d667c212f9a3710b74e90e05e1032316 (diff) | |
download | micropython-3cc17c69ffd64dca55fe613f6e931585d8893c0d.tar.gz micropython-3cc17c69ffd64dca55fe613f6e931585d8893c0d.zip |
py: Allow retrieving a function's __name__.
Disabled by default. Enabled on unix and stmhal ports.
Diffstat (limited to 'py/obj.h')
-rw-r--r-- | py/obj.h | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -574,8 +574,8 @@ typedef struct _mp_obj_fun_builtin_t { // use this to make const objects that go void *fun; // must be a pointer to a callable function in ROM } mp_obj_fun_builtin_t; -const char *mp_obj_fun_get_name(mp_const_obj_t fun); -const char *mp_obj_code_get_name(const byte *code_info); +qstr mp_obj_fun_get_name(mp_const_obj_t fun); +qstr mp_obj_code_get_name(const byte *code_info); mp_obj_t mp_identity(mp_obj_t self); MP_DECLARE_CONST_FUN_OBJ(mp_identity_obj); |