Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SR-3633] Support for segmented data structures #46218

Open
dabrahams opened this issue Jan 13, 2017 · 1 comment
Open

[SR-3633] Support for segmented data structures #46218

dabrahams opened this issue Jan 13, 2017 · 1 comment
Labels
affects ABI Flag: Affects ABI bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. standard library Area: Standard library umbrella

Comments

@dabrahams
Copy link
Collaborator

Previous ID SR-3633
Radar rdar://problem/31411203
Original Reporter @dabrahams
Type Bug
Additional Detail from JIRA
Votes 0
Component/s Standard Library
Labels Bug, AffectsABI
Assignee None
Priority Medium

md5: 1477fc519a29b7ca1f9937bf79331ec6

relates to:

  • SR-3631 Introduce ContiguouslyStored protocol and kill ArraySlice type

Issue Description:

Per http://lafstern.org/matt/segmented.pdf

Sketch:

protocol Collection {
  associatedType Segments : Collection where Segments.Element : Collection, Segments.Element.Element == Element = CollectionOfOne<Self>
  var segments: Segments? { get }
  // ...existing definition...
}
extension Collection where Segments == CollectionOfOne<Self> {
  var segments: Segments? { return nil }
}
// ...refined constraints for BidirectionalCollection, 
// RandomAccessCollection, and MutableCollection...

The sketch is missing at least:

  • refined constraints for BidirectionalCollection, RandomAccessCollection, and MutableCollection

  • A means of composing inner segment indices into outer indices

@bob-wilson
Copy link

@swift-ci create

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects ABI Flag: Affects ABI bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. standard library Area: Standard library umbrella
Projects
None yet
Development

No branches or pull requests

2 participants