Bug: 175870123

Clone this repo:
  1. 1e06739 Refresh Android.bp, cargo2android.json, TEST_MAPPING. by Joel Galenson · 7 weeks ago master
  2. 5939050 Upgrade rust/crates/unicode-normalization to 0.1.19 am: 674441f567 am: 0b757b34fd by Joel Galenson · 7 months ago android-s-v2-preview-1 android-s-v2-beta-2 android-s-v2-preview-2
  3. 0b757b3 Upgrade rust/crates/unicode-normalization to 0.1.19 am: 674441f567 by Joel Galenson · 7 months ago
  4. 674441f Upgrade rust/crates/unicode-normalization to 0.1.19 by Joel Galenson · 7 months ago android-s-beta-4 android-s-beta-5 android-s-beta-3
  5. 0182218 Generate apex_available from c2a instead of a patch am: e432fd933d am: d43d2d3679 am: 699554b476 by Joel Galenson · 9 months ago android12-dev android12-qpr1-d-release android12-qpr1-d-s1-release android12-qpr1-d-s2-release android12-qpr1-d-s3-release android12-qpr1-release android-12.0.0_r16 android-12.0.0_r18 android-12.0.0_r19 android-12.0.0_r20 android-12.0.0_r21 android-12.0.0_r26 android-12.0.0_r27

unicode-normalization

Build Status Docs

Unicode character composition and decomposition utilities as described in Unicode Standard Annex #15.

This crate requires Rust 1.36+.

extern crate unicode_normalization;

use unicode_normalization::char::compose;
use unicode_normalization::UnicodeNormalization;

fn main() {
    assert_eq!(compose('A','\u{30a}'), Some('Å'));

    let s = "ÅΩ";
    let c = s.nfc().collect::<String>();
    assert_eq!(c, "ÅΩ");
}

crates.io

You can use this package in your project by adding the following to your Cargo.toml:

[dependencies]
unicode-normalization = "0.1.19"

no_std + alloc support

This crate is completely no_std + alloc compatible. This can be enabled by disabling the std feature, i.e. specifying default-features = false for this crate on your Cargo.toml.