Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Avoid eager copying with BytesBuilder (dart-archive/async#186)
The previous implementation of `collectBytes` would return a `Uint8List` where the `lengthInBytes` and `buffer.lengthInBytes` matched. This property isn't an intended guarantee, however since some callers may rely on it for correct behavior it is safer to retain it. Use `copy: false` so that the buffer used in `takeBytes` has the same length as the data.
- Loading branch information