commit | 062478e66d03cc59ed73484a3032ef5f08db12a4 | [log] [tgz] |
---|---|---|
author | Damien George <damien.p.george@gmail.com> | Thu Jan 09 20:57:50 2014 +0000 |
committer | Damien George <damien.p.george@gmail.com> | Thu Jan 09 20:57:50 2014 +0000 |
tree | 6d3beb59ade6fe3d1ab7a5f05ff876e63062717f | |
parent | d944a66ead38b15b5a3c7a4ae8b054451fd5c077 [diff] [blame] |
Improved type/class/instance code; mp_obj_type_t now has load_attr, store_attr. Creating of classes (types) and instances is much more like CPython now. You can use "type('name', (), {...})" to create classes.
diff --git a/py/map.h b/py/map.h index 4905f5b..5ce4e83 100644 --- a/py/map.h +++ b/py/map.h
@@ -18,7 +18,7 @@ mp_obj_t *table; } mp_set_t; -typedef enum { +typedef enum _mp_map_lookup_kind_t { MP_MAP_LOOKUP, MP_MAP_LOOKUP_ADD_IF_NOT_FOUND, MP_MAP_LOOKUP_REMOVE_IF_FOUND,