Skip to content

Editorial: Refactor SetNumberFormatDigitOptions for comprehensibility#1050

Open
gibson042 wants to merge 9 commits intotc39:mainfrom
gibson042:2026-04-numberformat-aliases
Open

Editorial: Refactor SetNumberFormatDigitOptions for comprehensibility#1050
gibson042 wants to merge 9 commits intotc39:mainfrom
gibson042:2026-04-numberformat-aliases

Conversation

@gibson042
Copy link
Copy Markdown
Member

Prompted by recent reviews of proposal-amount PRs.

@gibson042 gibson042 requested review from ben-allen and ryzokuken April 2, 2026 17:39
Copy link
Copy Markdown
Contributor

@sffc sffc left a comment

Choose a reason for hiding this comment

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

I agree that this is a pure refactor, no logic change.

I have a general preference for keeping the variable names the same; I don't see a reason to change them.

The main change here is to switch some if statements from

let variable be A
if B, then set variable to C

to

if B, let variable be C
else, let variable be A

This seems fine and probably beneficial.

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.

2 participants