Change mp_obj_type_t.name from const char * to qstr.

Ultimately all static strings should be qstr.  This entry in the type
structure is only used for printing error messages (to tell the type of
the bad argument), and printing objects that don't supply a .print method.
This commit is contained in:
Damien George
2014-02-15 11:34:50 +00:00
parent 8ac72b9d00
commit a71c83a1d1
47 changed files with 100 additions and 77 deletions

View File

@@ -25,7 +25,7 @@ STATIC mp_obj_t range_getiter(mp_obj_t o_in) {
STATIC const mp_obj_type_t range_type = {
{ &mp_const_type} ,
"range",
.name = MP_QSTR_range,
.getiter = range_getiter,
};
@@ -63,7 +63,7 @@ STATIC mp_obj_t range_it_iternext(mp_obj_t o_in) {
STATIC const mp_obj_type_t range_it_type = {
{ &mp_const_type },
"range_iterator",
.name = MP_QSTR_iterator,
.iternext = range_it_iternext,
};