Skip to content

SE-0202 amendment: Remove Collection.randomElement requirement. #863

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

Conversation

jckarter
Copy link
Contributor

As a protocol requirement, this poses a potential forward compatibility hazard with move-only collections, and it's far from the only collection operation that would trap on a huge range used as a collection.

Pitch: https://forums.swift.org/t/proposed-amendment-to-se-202-replace-collection-randomelement-requirement-with-randomindex/13056

As a protocol requirement, this poses a potential forward compatibility hazard with move-only collections, and it's far from the only collection operation that would trap on a huge range used as a collection.
@jckarter jckarter merged commit 4ff7d60 into swiftlang:master Jun 29, 2018
@jckarter
Copy link
Contributor Author

jckarter added a commit to jckarter/swift that referenced this pull request Jun 29, 2018
As proposed and accepted in amendment swiftlang/swift-evolution#863. rdar://problem/41067949
jckarter added a commit to jckarter/swift that referenced this pull request Jun 29, 2018
As proposed and accepted in amendment swiftlang/swift-evolution#863. rdar://problem/41067949
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant