slice method
Returns a slice retaining the original native allocation, when present.
Implementation
NativeByteView slice(int start, int end) {
RangeError.checkValidRange(start, end, bytes.length);
final slice = Uint8List.sublistView(bytes, start, end);
final backing = _backing;
if (backing != null) {
_nativeByteBackings[slice] = backing;
}
return NativeByteView._(slice, backing, _offset + start);
}