diff options
author | Damien George <damien.p.george@gmail.com> | 2014-07-03 13:25:24 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2014-07-03 13:25:24 +0100 |
commit | 40f3c026823f8951a2fa04e9c7fc93c75bc27bec (patch) | |
tree | c9c8210654c7114f00c5234a8481d9b5fbd28ce0 /py/objstringio.c | |
parent | 065aba587571150074ea79483ffa72c0fe6bc8c8 (diff) | |
download | micropython-40f3c026823f8951a2fa04e9c7fc93c75bc27bec.tar.gz micropython-40f3c026823f8951a2fa04e9c7fc93c75bc27bec.zip |
Rename machine_(u)int_t to mp_(u)int_t.
See discussion in issue #50.
Diffstat (limited to 'py/objstringio.c')
-rw-r--r-- | py/objstringio.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/py/objstringio.c b/py/objstringio.c index d9ad604b41..bffdf2cf79 100644 --- a/py/objstringio.c +++ b/py/objstringio.c @@ -43,7 +43,7 @@ typedef struct _mp_obj_stringio_t { mp_obj_base_t base; vstr_t *vstr; // StringIO has single pointer used for both reading and writing - machine_uint_t pos; + mp_uint_t pos; } mp_obj_stringio_t; STATIC void stringio_print(void (*print)(void *env, const char *fmt, ...), void *env, mp_obj_t self_in, mp_print_kind_t kind) { @@ -51,9 +51,9 @@ STATIC void stringio_print(void (*print)(void *env, const char *fmt, ...), void print(env, self->base.type == &mp_type_stringio ? "<io.StringIO 0x%x>" : "<io.BytesIO 0x%x>", self->vstr); } -STATIC machine_int_t stringio_read(mp_obj_t o_in, void *buf, machine_uint_t size, int *errcode) { +STATIC mp_int_t stringio_read(mp_obj_t o_in, void *buf, mp_uint_t size, int *errcode) { mp_obj_stringio_t *o = o_in; - machine_uint_t remaining = o->vstr->len - o->pos; + mp_uint_t remaining = o->vstr->len - o->pos; if (size > remaining) { size = remaining; } @@ -62,9 +62,9 @@ STATIC machine_int_t stringio_read(mp_obj_t o_in, void *buf, machine_uint_t size return size; } -STATIC machine_int_t stringio_write(mp_obj_t o_in, const void *buf, machine_uint_t size, int *errcode) { +STATIC mp_int_t stringio_write(mp_obj_t o_in, const void *buf, mp_uint_t size, int *errcode) { mp_obj_stringio_t *o = o_in; - machine_uint_t remaining = o->vstr->alloc - o->pos; + mp_uint_t remaining = o->vstr->alloc - o->pos; if (size > remaining) { // Take all what's already allocated... o->vstr->len = o->vstr->alloc; |