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

core: fix floating-point number formatting Locale #7473

Merged
merged 4 commits into from Oct 29, 2020

Conversation

dapengzhang0
Copy link
Member

@dapengzhang0 dapengzhang0 commented Sep 30, 2020

In some Locale, floating-point number like 1,234.56 is formatted as 1.234,56; and in some Locale, integers are formatted with non-ASCII decimal digits.

https://developer.android.com/reference/java/util/Locale.html#default_locale

@dapengzhang0
Copy link
Member Author

I'm actually not sure to choose Locale.ROOT or Locale.US.

@voidzcy
Copy link
Contributor

voidzcy commented Oct 14, 2020

I'm actually not sure to choose Locale.ROOT or Locale.US.

I think Locale.US is safest, although numbers seem to be locale-neutral. It shouldn't matter much. But I would vote for Locale.US.

@dapengzhang0 dapengzhang0 merged commit 654f7c3 into grpc:master Oct 29, 2020
@dapengzhang0 dapengzhang0 deleted the fix-locale branch October 29, 2020 00:24
sergiitk pushed a commit to sergiitk/grpc-java that referenced this pull request Oct 29, 2020
dfawley pushed a commit to dfawley/grpc-java that referenced this pull request Jan 15, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 5, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants