all: Rename mp_obj_type_t::stream_p to protocol.

It's now used for more than just stream protocol (e.g. pin protocol), so
don't use false names.
This commit is contained in:
Paul Sokolovsky
2016-06-18 18:19:24 +03:00
parent 080137961d
commit 07209f8592
22 changed files with 38 additions and 33 deletions

View File

@@ -259,7 +259,7 @@ const mp_obj_type_t mp_type_fileio = {
.make_new = file_obj_make_new,
.getiter = mp_identity,
.iternext = mp_stream_unbuffered_iter,
.stream_p = &fileio_stream_p,
.protocol = &fileio_stream_p,
.locals_dict = (mp_obj_dict_t*)&rawfile_locals_dict,
};
#endif
@@ -278,7 +278,7 @@ const mp_obj_type_t mp_type_textio = {
.make_new = file_obj_make_new,
.getiter = mp_identity,
.iternext = mp_stream_unbuffered_iter,
.stream_p = &textio_stream_p,
.protocol = &textio_stream_p,
.locals_dict = (mp_obj_dict_t*)&rawfile_locals_dict,
};