Also:
- Tweak RigidArray.
- Define some default implementations for Container requirements.
- Beef up ContiguousContainer.
- Add support for testing contiguous access on minimal collections.
- Container, MutableContainer: Replace iterator protocols with direct methods that return the next span following a particular index. This is a radical simplification, but it reintroduces some index validation during iteration, and may have undesirable overhead for complex container types.
- RigidArray, DynamicArray, NewArray: Update to reflect changes
- Span: Conform to RandomAccessContainer
- Borrow, Inout: Normalize labels of “owner” parameters. Expose pointers within the package.
- Shared: Normalize read() into borrow()
We cannot express the right subscript requirements yet; make do by requiring hidden members that return (unsafe, escaping) pointers, and provide a default subscript that’s based on unsafe addressors.
This is very unsatisfying, but currently there is no way for a protocol to require subscripts with the right semantics.