canonical / canonical/stdlibc.dart
read & write use signed bytes
Open
- Dominant language
- Dart
- Stars
- 58
- Forks
- 13
- PR merge metrics
- No merged PRs in 30d
Description
Hey!
For me it was counter-intuitive to discover that the posix unistd functions, e.g. `read` and `write` use signed 8-bit values, instead of unsigned.
The rest of dart seems to use unsigned 0-255 values as bytes, e.g.: https://api.dart.dev/dart-io/File/writeAsBytes.html or the codecs in https://api.flutter.dev/flutter/dart-convert/
Is that intentional? If it is, I think it might be worth adding notes about that in the docs, or providing uint8 variants
Contributor guide
Assessment
This issue has not been assessed yet.