Skip to content

Deprecate Ordering.arbitrary(). - #8849

Merged
copybara-service[bot] merged 1 commit into
masterfrom
test_1018519832
Nov 10, 2026
Merged

copybara-service[bot] merged 1 commit into
masterfrom
test_1018519832

Conversation

@copybara-service

Copy link
Copy Markdown
Contributor

Deprecate Ordering.arbitrary().

We're not removing it, but we've known it's a bad idea for close to 15 years now, and it's becoming an even worse idea with Valhalla.

(prompted by #8815, which makes it tangentially related to #3864 in that it might leave Ordering.explicit as the only method without a Java 8 replacement, though I notice that we don't appear to document replacements for sortedCopy and immutableSorteCopy)

RELNOTES=n/a

We're not removing it, but we've known it's a bad idea for close to 15 years now, and it's becoming an even worse idea [with Valhalla](https://openjdk.java.net/jeps/401).

(prompted by #8815, which makes it tangentially related to #3864 in that it might leave `Ordering.explicit` as the _only_ method without a Java 8 replacement, though I notice that we don't appear to document replacements for `sortedCopy` and `immutableSorteCopy`)

RELNOTES=n/a
PiperOrigin-RevId: 1018611950
@copybara-service
copybara-service Bot merged commit 1b402e4 into master Nov 10, 2026
15 checks passed
@copybara-service
copybara-service Bot deleted the test_1018519832 branch November 10, 2026 23:40
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