We don’t know what next year is in Japan

2019’s biggest Unicode change isn’t an emoji

Nick Doiron
3 min readDec 19, 2018

On April 30 of next year, the Emperor of Japan will abdicate for the first time since Japan formed an elected national government. Among the ceremonies and constitutional changes necessary for this to go smoothly, there’s one thing which programmers in Japan (and to a lesser extent, worldwide) are growing aware of: a still-unnamed change in the Japanese calendar.

The Problem

When the current Emperor acceded in 1989, Japan’s imperial year changed
平成1年 (Heisei year one). Computers were not so integrated into everyday life, and most systems had limited support for other languages and calendars. Today all of your devices know the whole Japanese calendar, as it’s encoded via ICU (International Components for Unicode). JavaScript developers can try it like this:

new Date().toLocaleDateString(“ja-JP-u-ca-japanese”, {era: “long”})
> “平成30年12月19日”
new Date().toLocaleDateString(“en-US-u-ca-japanese”, {era: “long”})
> “12 19, 30 Heisei”

You can even trace the Emperors back in time as far as 645 AD:

new Date(“7/2/645”).toLocaleDateString(“ja-JP-u-ca-japanese”, {era: “long”})
“大化1年6月29日”

If you try to request an earlier year, the calendar will show 大化0年 before turning negative. I asked a Japanese friend, why 645?, and ended up reading:

The Next Emperor

With the next Emperor, there will be a new era name chosen and added to driving licenses, government documents, etc. Currently, no one knows for certain what this era will be named, so dates are typically written as if the current era continues (try requesting a future date in JavaScript). There are many systems written inflexibly / hard-coded to print the year with the current era, sometimes with a one-character Unicode shortcut such as ㍻.

Only in 2016, when the Emperor asked the Japanese parliament to allow abdication, could people start discussing how these systems could be adapted and continued in the future.

The unprecedented situation has left it unclear when the Japanese government will announce the new era. This article indicates that we will get less than three weeks notice:

In December 2017, the Japanese Industrial Standards Committee filed an unusual request with the Unicode Consortium. They asked for the next Emperor’s era to be represented by a new codepoint — a successor to ㍻ — before we know what it actually looks like. This codepoint 0x32FF was approved in summer 2018 and currently looks like a blank square on my machine: “㋿” .

Calendars to watch for in 2019

There are several other calendars in ICU, and while Japan has solid coverage, others do not. Burmese has a lunar calendar, so I started copying ICU C++ code from the Persian lunar calendar as an alternative. Then I got stuck on their two different ‘leap month’ concepts. There are two positive developments: a new and more readable JS library with C++ code from Yan Naing Aye, and updates to Burmese month names in other calendars. The bugs from 2013 and 2014 remain ‘unscheduled’, but I remain hopeful.

Updated April 2019

The chosen era was 令和 (“Reiwa”), so the English short form would be R.

--

--