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

Editorial: Inlined Intl.PluralRules's GetOperands AO. #930

Merged
merged 3 commits into from
Oct 29, 2024

Conversation

ben-allen
Copy link
Contributor

GetOperands was only called from the ResolvePlural AO, which immediately passed the Record returned by GetOperands to the implementation-defined PluralRuleSelect AO. The revised version of ResolvePlural directly passes PluralRuleSelect the decimal String which was previously parsed by GetOperands. Implementations of PluralRuleSelect may (or may not) use something like GetOperands to determine the correct plural category.

fixes #635

This AO was only called from the ResolvePlural AO, which immediately passed the Record it returns
into the implementation-defined PluralRuleSelect AO. The revised version directly passes
PluralRuleSelect the decimal String which was previously parsed by GetOperands. Implementations of PluralRuleSelect
may (or may not) use something like GetOperands to determine the plural category returned.

fixes tc39#635
@ben-allen ben-allen added the editorial Involves an editorial fix label Sep 27, 2024
Copy link
Contributor

@gibson042 gibson042 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I have a suggested tweak, but I'm so happy to see this simplification!

spec/pluralrules.html Outdated Show resolved Hide resolved
Co-authored-by: Richard Gibson <[email protected]>
@ben-allen
Copy link
Contributor Author

Look good? @gibson042

@gibson042 gibson042 merged commit c7bca3a into tc39:main Oct 29, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
editorial Involves an editorial fix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inline GetOperands into PluralRuleSelect
2 participants