Open Bug 1960300 Opened 9 days ago Updated 8 days ago

Upgrade ICU4X to 2.0 (or 2.0-beta3 or git main)

Categories

(Core :: Internationalization, enhancement)

enhancement

Tracking

()

People

(Reporter: hsivonen, Unassigned)

References

(Blocks 1 open bug)

Details

After bug 1954138 and bug 1955545, we'd still have islamic-umalqura disabled in Temporal due to the calendar implementation in ICU4X 1.x not matching what the calendar steward (and, therefore, ICU4C) says.

This has been fixed on ICU4X main: https://github.com/unicode-org/icu4x/pull/6385 .

The fix wouldn't be particularly difficult to backport to ICU4X 1.5.x, but backporting isn't a particularly good use of effort if we can put the effort into making Gecko work with ICU4X 2.0, which we'll have to do eventually anyway.

Currently, ICU4X 2.0-beta2 isn't new enough, so whether we should be upgrading to a snapshot of ICU4X main vendored from git, a possible 2.0-beta3, or the eventual 2.0 depends on when relative to ICU4X timelines an upgrade in m-c takes place.

Let's start by listing what we know needs changing outside the vendored icu_whatever crates in m-c.

I'll start:

  • The vendored idna_adapter crate needs to be semver-compatible with the ICU4X version. Moreover, betas aren't semver compatible with other version in Cargo. I have code waiting at https://github.com/hsivonen/idna_adapter/tree/icu4x-trunk , but its Cargo.toml declarations of the ICU4X dependencies need to be adjusted to match whichever version of ICU4X we vendor. (Once the non-beta ICU4X 2.0 has been released, I'll publish a new version of idna_adapter on crates.io. I previously published a version that depended on beta1, but it didn't work the way it was mean to due to the way betas behave in Cargo version resolution, so I had to yank the version.)
  • The API entry points for the Hirji calendars have been renamed, so the Temporal code needs to be updated to use the new names.

m_kato, has ICU4X's segmenter API changed in a way that needs Gecko-side planning?

Flags: needinfo?(m_kato)

After releasing 1.5.0, Segmenter changes are

Currently we have some bugs for line segmenter. Upgrading to 2.0, we can resolve some bugs. Also, we can add locale support for segmenter.

Flags: needinfo?(m_kato)
You need to log in before you can comment on or make changes to this bug.