-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Fix Japanese Abbreviated Era Names #40300
Conversation
abbrevEnglishEraNames = s_abbreviatedEnglishEraNames; | ||
} | ||
|
||
if (abbrevEnglishEraNames[abbrevEnglishEraNames.Length - 1].Length != 1 || abbrevEnglishEraNames[abbrevEnglishEraNames.Length - 1][0] > '\u007F') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to understand this, why would having the Length != 1 of the abbrevEnglishEraNames on the last element or having a character in first position greater than DELETE
character is an indicator that we couldn't get the abbreviated english names?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Japanese English abbreviated names so far is only one letter. In some versions of ICU versions (e.g. ver 50) it doesn't return these Latin letters. The check here is indicating if we have Latin or non Latin names. The check here is enough. I may remove the length check just in case in the future we'll get more than one letter (which unlikely but it is possible).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see, makes sense. Thanks for explaining!
ApiCompat failure is: #40416 |
Fixes #40194