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

sets: allow unordered types #41371

Merged
merged 1 commit into from
Oct 13, 2022

Conversation

howardjohn
Copy link
Member

@howardjohn howardjohn commented Oct 11, 2022

This allows us to use Sets for (almost) arbitrary types. The cost is that SortedList must become a function, not a method.

Rewrite done using gofmt -r 'x.SortedList() -> sets.SortedList(x)' -w **/*.go.

The alternative would be to create a duplicate Set type, UnoderedSet; in talking with Rama we both preferred this option.

Please provide a description of this PR:

@howardjohn howardjohn added the release-notes-none Indicates a PR that does not require release notes. label Oct 11, 2022
@howardjohn howardjohn requested review from a team as code owners October 11, 2022 14:32
@istio-testing istio-testing added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Oct 11, 2022
This allows us to use Sets for (almost) arbitrary types. The cost is
that SortedList must become a function, not a method.

Rewrite done using `gofmt -r 'x.SortedList() -> sets.SortedList(x)' -w **/*.go`.

The alternative would be to create a duplicate Set type, UnoderedSet; in
talking with Rama we both preferred this option.
@howardjohn howardjohn force-pushed the sets/allow-unordered branch from ac83b5d to 9f60122 Compare October 11, 2022 14:36
@istio-testing istio-testing merged commit ea42853 into istio:master Oct 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-notes-none Indicates a PR that does not require release notes. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants