Skip to content

Commit

Permalink
Upgrade to Unicode 16.0
Browse files Browse the repository at this point in the history
  • Loading branch information
wezm committed Oct 3, 2024
1 parent fcec08d commit cbad1e7
Show file tree
Hide file tree
Showing 5 changed files with 69 additions and 25 deletions.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ authors = [
"The Servo Project Developers",
"YesLogic Pty. Ltd. <[email protected]>"
]
edition = "2018"

homepage = "https://github.com/yeslogic/unicode-script"
repository = "https://github.com/yeslogic/unicode-script"
Expand Down
9 changes: 9 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
UCD:=16.0.0

tables:
yeslogic-ucd-generate script --rust-enum --name Script ../ucd-generate/ucd-$(UCD) > src/tables.rs
cargo fmt


.PHONY: tables

4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ yeslogic-unicode-script
<a href="https://docs.rs/yeslogic-unicode-script">
<img src="https://docs.rs/yeslogic-unicode-script/badge.svg" alt="Documentation">
</a>
<img src="https://img.shields.io/badge/unicode-15.0-informational" alt="Unicode Version">
<img src="https://img.shields.io/badge/unicode-16.0-informational" alt="Unicode Version">
<a href="https://crates.io/crates/yeslogic-unicode-script">
<img src="https://img.shields.io/crates/v/yeslogic-unicode-script.svg" alt="Version">
</a>
Expand All @@ -16,7 +16,7 @@ yeslogic-unicode-script
<br>

Fast lookup of the Unicode Script property for `char` in Rust using
Unicode 15.0 data.
Unicode 16.0 data.

Usage
-----
Expand Down
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ pub use tables::Script;

/// The version of [Unicode](http://www.unicode.org/)
/// that this version of unicode-script is based on.
pub const UNICODE_VERSION: (u64, u64, u64) = (15, 0, 0);
pub const UNICODE_VERSION: (u64, u64, u64) = (16, 0, 0);

#[cfg(feature = "harfbuzz")]
extern crate harfbuzz_sys;
Expand Down
78 changes: 56 additions & 22 deletions src/tables.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// DO NOT EDIT THIS FILE. IT WAS AUTOMATICALLY GENERATED BY:
//
// yeslogic-ucd-generate script --rust-enum --name Script ../ucd-generate/ucd-15.0.0
// yeslogic-ucd-generate script --rust-enum --name Script ../ucd-generate/ucd-16.0.0
//
// Unicode version: 15.0.0.
// Unicode version: 16.0.0.
//
// yeslogic-ucd-generate 0.6.0 is available on crates.io.
// yeslogic-ucd-generate 0.7.0 is available on crates.io.

#[derive(Clone, Copy, Debug, Hash, Eq, PartialEq)]
pub enum Script {
Expand Down Expand Up @@ -48,6 +48,7 @@ pub enum Script {
Elbasan,
Elymaic,
Ethiopic,
Garay,
Georgian,
Glagolitic,
Gothic,
Expand All @@ -56,6 +57,7 @@ pub enum Script {
Gujarati,
GunjalaGondi,
Gurmukhi,
GurungKhema,
Han,
Hangul,
HanifiRohingya,
Expand All @@ -78,6 +80,7 @@ pub enum Script {
Khmer,
Khojki,
Khudawadi,
KiratRai,
Lao,
Latin,
Lepcha,
Expand Down Expand Up @@ -115,6 +118,7 @@ pub enum Script {
NyiakengPuachueHmong,
Ogham,
OlChiki,
OlOnal,
OldHungarian,
OldItalic,
OldNorthArabian,
Expand Down Expand Up @@ -146,6 +150,7 @@ pub enum Script {
SoraSompeng,
Soyombo,
Sundanese,
Sunuwar,
SylotiNagri,
Syriac,
Tagalog,
Expand All @@ -163,7 +168,9 @@ pub enum Script {
Tibetan,
Tifinagh,
Tirhuta,
Todhri,
Toto,
TuluTigalari,
Ugaritic,
Vai,
Vithkuqi,
Expand Down Expand Up @@ -251,7 +258,7 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(2144, 2154, Script::Syriac),
(2160, 2190, Script::Arabic),
(2192, 2193, Script::Arabic),
(2200, 2273, Script::Arabic),
(2199, 2273, Script::Arabic),
(2274, 2274, Script::Common),
(2275, 2303, Script::Arabic),
(2304, 2384, Script::Devanagari),
Expand Down Expand Up @@ -473,15 +480,15 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(6816, 6829, Script::TaiTham),
(6832, 6862, Script::Inherited),
(6912, 6988, Script::Balinese),
(6992, 7038, Script::Balinese),
(6990, 7039, Script::Balinese),
(7040, 7103, Script::Sundanese),
(7104, 7155, Script::Batak),
(7164, 7167, Script::Batak),
(7168, 7223, Script::Lepcha),
(7227, 7241, Script::Lepcha),
(7245, 7247, Script::Lepcha),
(7248, 7295, Script::OlChiki),
(7296, 7304, Script::Cyrillic),
(7296, 7306, Script::Cyrillic),
(7312, 7354, Script::Georgian),
(7357, 7359, Script::Georgian),
(7360, 7367, Script::Sundanese),
Expand Down Expand Up @@ -548,7 +555,7 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(8527, 8543, Script::Common),
(8544, 8584, Script::Latin),
(8585, 8587, Script::Common),
(8592, 9254, Script::Common),
(8592, 9257, Script::Common),
(9280, 9290, Script::Common),
(9312, 10239, Script::Common),
(10240, 10495, Script::Braille),
Expand Down Expand Up @@ -579,8 +586,7 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(11904, 11929, Script::Han),
(11931, 12019, Script::Han),
(12032, 12245, Script::Han),
(12272, 12283, Script::Common),
(12288, 12292, Script::Common),
(12272, 12292, Script::Common),
(12293, 12293, Script::Han),
(12294, 12294, Script::Common),
(12295, 12295, Script::Han),
Expand All @@ -603,7 +609,8 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(12593, 12686, Script::Hangul),
(12688, 12703, Script::Common),
(12704, 12735, Script::Bopomofo),
(12736, 12771, Script::Common),
(12736, 12773, Script::Common),
(12783, 12783, Script::Common),
(12784, 12799, Script::Katakana),
(12800, 12830, Script::Hangul),
(12832, 12895, Script::Common),
Expand All @@ -625,10 +632,10 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(42752, 42785, Script::Common),
(42786, 42887, Script::Latin),
(42888, 42890, Script::Common),
(42891, 42954, Script::Latin),
(42891, 42957, Script::Latin),
(42960, 42961, Script::Latin),
(42963, 42963, Script::Latin),
(42965, 42969, Script::Latin),
(42965, 42972, Script::Latin),
(42994, 43007, Script::Latin),
(43008, 43052, Script::SylotiNagri),
(43056, 43065, Script::Common),
Expand Down Expand Up @@ -760,6 +767,7 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(66979, 66993, Script::Vithkuqi),
(66995, 67001, Script::Vithkuqi),
(67003, 67004, Script::Vithkuqi),
(67008, 67059, Script::Todhri),
(67072, 67382, Script::LinearA),
(67392, 67413, Script::LinearA),
(67424, 67431, Script::LinearA),
Expand Down Expand Up @@ -815,11 +823,15 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(68858, 68863, Script::OldHungarian),
(68864, 68903, Script::HanifiRohingya),
(68912, 68921, Script::HanifiRohingya),
(68928, 68965, Script::Garay),
(68969, 68997, Script::Garay),
(69006, 69007, Script::Garay),
(69216, 69246, Script::Arabic),
(69248, 69289, Script::Yezidi),
(69291, 69293, Script::Yezidi),
(69296, 69297, Script::Yezidi),
(69373, 69375, Script::Arabic),
(69314, 69316, Script::Arabic),
(69372, 69375, Script::Arabic),
(69376, 69415, Script::OldSogdian),
(69424, 69465, Script::Sogdian),
(69488, 69513, Script::OldUyghur),
Expand Down Expand Up @@ -862,6 +874,17 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(70493, 70499, Script::Grantha),
(70502, 70508, Script::Grantha),
(70512, 70516, Script::Grantha),
(70528, 70537, Script::TuluTigalari),
(70539, 70539, Script::TuluTigalari),
(70542, 70542, Script::TuluTigalari),
(70544, 70581, Script::TuluTigalari),
(70583, 70592, Script::TuluTigalari),
(70594, 70594, Script::TuluTigalari),
(70597, 70597, Script::TuluTigalari),
(70599, 70602, Script::TuluTigalari),
(70604, 70613, Script::TuluTigalari),
(70615, 70616, Script::TuluTigalari),
(70625, 70626, Script::TuluTigalari),
(70656, 70747, Script::Newa),
(70749, 70753, Script::Newa),
(70784, 70855, Script::Tirhuta),
Expand All @@ -873,6 +896,7 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(71264, 71276, Script::Mongolian),
(71296, 71353, Script::Takri),
(71360, 71369, Script::Takri),
(71376, 71395, Script::Myanmar),
(71424, 71450, Script::Ahom),
(71453, 71467, Script::Ahom),
(71472, 71494, Script::Ahom),
Expand All @@ -895,6 +919,8 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(72368, 72383, Script::CanadianAboriginal),
(72384, 72440, Script::PauCinHau),
(72448, 72457, Script::Devanagari),
(72640, 72673, Script::Sunuwar),
(72688, 72697, Script::Sunuwar),
(72704, 72712, Script::Bhaiksuki),
(72714, 72758, Script::Bhaiksuki),
(72760, 72773, Script::Bhaiksuki),
Expand All @@ -918,7 +944,7 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(73440, 73464, Script::Makasar),
(73472, 73488, Script::Kawi),
(73490, 73530, Script::Kawi),
(73534, 73561, Script::Kawi),
(73534, 73562, Script::Kawi),
(73648, 73648, Script::Lisu),
(73664, 73713, Script::Tamil),
(73727, 73727, Script::Tamil),
Expand All @@ -928,7 +954,9 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(74880, 75075, Script::Cuneiform),
(77712, 77810, Script::CyproMinoan),
(77824, 78933, Script::EgyptianHieroglyphs),
(78944, 82938, Script::EgyptianHieroglyphs),
(82944, 83526, Script::AnatolianHieroglyphs),
(90368, 90425, Script::GurungKhema),
(92160, 92728, Script::Bamum),
(92736, 92766, Script::Mro),
(92768, 92777, Script::Mro),
Expand All @@ -942,6 +970,7 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(93019, 93025, Script::PahawhHmong),
(93027, 93047, Script::PahawhHmong),
(93053, 93071, Script::PahawhHmong),
(93504, 93561, Script::KiratRai),
(93760, 93850, Script::Medefaidrin),
(93952, 94026, Script::Miao),
(94031, 94087, Script::Miao),
Expand All @@ -954,6 +983,7 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(94208, 100343, Script::Tangut),
(100352, 101119, Script::Tangut),
(101120, 101589, Script::KhitanSmallScript),
(101631, 101631, Script::KhitanSmallScript),
(101632, 101640, Script::Tangut),
(110576, 110579, Script::Katakana),
(110581, 110587, Script::Katakana),
Expand All @@ -972,6 +1002,8 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(113808, 113817, Script::Duployan),
(113820, 113823, Script::Duployan),
(113824, 113827, Script::Common),
(117760, 118009, Script::Common),
(118016, 118451, Script::Common),
(118528, 118573, Script::Inherited),
(118576, 118598, Script::Inherited),
(118608, 118723, Script::Common),
Expand Down Expand Up @@ -1032,6 +1064,8 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(123584, 123641, Script::Wancho),
(123647, 123647, Script::Wancho),
(124112, 124153, Script::NagMundari),
(124368, 124410, Script::OlOnal),
(124415, 124415, Script::OlOnal),
(124896, 124902, Script::Ethiopic),
(124904, 124907, Script::Ethiopic),
(124909, 124910, Script::Ethiopic),
Expand Down Expand Up @@ -1103,24 +1137,24 @@ pub const SCRIPT: &'static [(u32, u32, Script)] = &[
(129104, 129113, Script::Common),
(129120, 129159, Script::Common),
(129168, 129197, Script::Common),
(129200, 129201, Script::Common),
(129200, 129211, Script::Common),
(129216, 129217, Script::Common),
(129280, 129619, Script::Common),
(129632, 129645, Script::Common),
(129648, 129660, Script::Common),
(129664, 129672, Script::Common),
(129680, 129725, Script::Common),
(129727, 129733, Script::Common),
(129742, 129755, Script::Common),
(129760, 129768, Script::Common),
(129664, 129673, Script::Common),
(129679, 129734, Script::Common),
(129742, 129756, Script::Common),
(129759, 129769, Script::Common),
(129776, 129784, Script::Common),
(129792, 129938, Script::Common),
(129940, 129994, Script::Common),
(130032, 130041, Script::Common),
(129940, 130041, Script::Common),
(131072, 173791, Script::Han),
(173824, 177977, Script::Han),
(177984, 178205, Script::Han),
(178208, 183969, Script::Han),
(183984, 191456, Script::Han),
(191472, 192093, Script::Han),
(194560, 195101, Script::Han),
(196608, 201546, Script::Han),
(201552, 205743, Script::Han),
Expand Down

0 comments on commit cbad1e7

Please sign in to comment.