Browse Source
3-arg form: stream.write(data, offset, length) 2-arg form: stream.write(data, length) These allow efficient buffer writing without incurring extra memory allocation for slicing or creating memoryview() object, what is important for low-memory ports. All arguments must be positional. It might be not so bad idea to standardize on 3-arg form, but 2-arg case would need check and raising an exception anyway then, so instead it was just made to work.pull/2244/head
Paul Sokolovsky
8 years ago
1 changed files with 16 additions and 4 deletions
Loading…
Reference in new issue