-
Notifications
You must be signed in to change notification settings - Fork 33
Added Chinese #14
base: master
Are you sure you want to change the base?
Added Chinese #14
Conversation
Thank you for your interest in contributing to Numsense. FTR, I'm currently travelling, and have only limited to time to evaluate pull requests. In due time, I'll work through my backlog, but it may take weeks 😳 😓 |
hundredMillions = "亿" | ||
} | ||
|
||
let rec internal toChineseImp useAlternativeTwo characterSet x = |
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.
Is there any case when useAlternativeTwo
is false
?
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.
You are right, this is not needed here.
I added this parameter because in Chinese depending on few conditions a number two may be written in alternative form.
I think it is trivial for a user to replace the alternative form with the usual one so I assume it is better to have it always enabled.
I've removed unneeded |
b8f151c
to
7692ba3
Compare
|
||
type CharacterSet = | ||
{ | ||
negative: string; |
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.
Since this is an internal type, it may not be that big a deal, but since CharacterSet
is a type, it'd be more idiomatic to give each named element a PascalCased name: Negative
, Zero
, One
, etc.
From an API design perspective, it doesn't matter, because the type (currently) isn't exposed to the public, but from a readability perspective, it constitutes a small 'speed bump' for the reader of the code.
@ploeh: Thanks for CR 😃 |
It builds and runs all tests without warnings on my machine, so from a technical perspective I think we're good to go 👍 As I don't read Chinese, I'd like someone who does to review that part of it, if at all possible. I don't expect any errors, but it's always good with a second pair of eyes 😄 |
I solicited a review on Twitter: https://twitter.com/ploeh/status/693845849370169346 Please retweet and spread the word 😄 |
I've added traditional and simplified Chinese with normal and financial variants.
Please keep in mind I'm not a Chinese native speaker and it would be great if somebody could check my text for correctness.
Also I'm just starting with F# and any comments how can I improve my code are very welcome 😃