diff options
author | Damien George <damien.p.george@gmail.com> | 2016-08-15 10:56:55 +1000 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2016-08-15 10:56:55 +1000 |
commit | 41fceae559ff2272a88441dbf531232f173ccbd6 (patch) | |
tree | e06c22aa3c4b6c7fc599b2253f696e6e494d97bf /py/obj.h | |
parent | b359cf2911781120f5c866107734269435c4e424 (diff) | |
download | micropython-41fceae559ff2272a88441dbf531232f173ccbd6.tar.gz micropython-41fceae559ff2272a88441dbf531232f173ccbd6.zip |
py/obj.h: For obj reprs A,B,C use void* explicitly for mp_obj_t typedef.
The machine_ptr_t type is long obsolete as the type of mp_obj_t is now
defined by the object representation, ie by MICROPY_OBJ_REPR. So just use
void* explicitly for the typedef of mp_obj_t.
If a port wants to use something different then they should define a new
object representation.
Diffstat (limited to 'py/obj.h')
-rw-r--r-- | py/obj.h | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -31,15 +31,15 @@ #include "py/qstr.h" #include "py/mpprint.h" -// All Micro Python objects are at least this type -// The bit-size must be at least pointer size - +// This is the definition of the opaque MicroPython object type. +// All concrete objects have an encoding within this type and the +// particular encoding is specified by MICROPY_OBJ_REPR. #if MICROPY_OBJ_REPR == MICROPY_OBJ_REPR_D typedef uint64_t mp_obj_t; typedef uint64_t mp_const_obj_t; #else -typedef machine_ptr_t mp_obj_t; -typedef machine_const_ptr_t mp_const_obj_t; +typedef void *mp_obj_t; +typedef const void *mp_const_obj_t; #endif // This mp_obj_type_t struct is a concrete MicroPython object which holds info |