Consistently allow Locale objects in locale list params #52996
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #52946
I've also removed the type
BCP47LanguageTag
in favor ofUnicodeBCP47LocaleIdentifier
— not sure why there were 2 distinct types for this in the first place, especially given that both are just aliases ofstring
. In any case, the correct term is "locale identifier", not "language tag" — BCP 47 locale identifiers are a subset of BCP 47 language tags, and language tags that aren't locale identifiers aren't supported byIntl
.BCP47LanguageTag
could alternatively be deprecated rather than removed, to mitigate the unlikely case of userland code using theIntl.BCP47LanguageTag
type... not sure if that's a necessary consideration, though.