Hacker News new | ask | show | jobs
by massivecali 2611 days ago
How do placeholders work in languages where you are forced to assign lengths to variables?
1 comments

Not a Problem in this case, the era is always a single character, a newly formed ligature of two kanjis.

The code point was already reserved in unicode 11.0, so you could even just the unicode code point.

The real world is not so perfect. I never see Heisei or Showa, or earlier reigns as a single character. The Japanese are also not fully onboard with Unicode so there's an extra level of effort needed if you want to get into a normalized form.
For this specific question, I strongly suspect that whatever the length of your Heisei string is, it's safe to assume that the new era string will be the same length.
>The real world is not so perfect. Perfect summation. Curious how this will also impact other consumers of Japanese data.
Then it looks even harder. How do we handle it if our system doesn't support Unicode 11.0? Is platform upgrade only option?