-
Notifications
You must be signed in to change notification settings - Fork 237
Always generate fast-mode data for NFD and NFKD tries #7222
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,7 @@ | ||
| normalizer/nfc/v1, <singleton>, 5332B, 5310B, dd048e68b718a993 | ||
| normalizer/nfd/data/v1, <singleton>, 28208B, 28144B, a37d3c274c030323 | ||
| normalizer/nfd/data/v1, <singleton>, 34912B, 34848B, 933447e5c056e49c | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm surprised that the toml files didn't change but the generated data did. |
||
| normalizer/nfd/supplement/v1, <singleton>, 4486B, 4403B, a587960aa6faa95c | ||
| normalizer/nfd/tables/v1, <singleton>, 2177B, 2133B, 8818c6d23b22796a | ||
| normalizer/nfkd/data/v1, <singleton>, 43400B, 43336B, 855553ea574c0178 | ||
| normalizer/nfkd/data/v1, <singleton>, 51488B, 51424B, a5a4848d32dd13f8 | ||
| normalizer/nfkd/tables/v1, <singleton>, 5865B, 5821B, 7f50ce23df00365d | ||
| normalizer/uts46/data/v1, <singleton>, 56552B, 56493B, 2f3422c2c9cc708b | ||
Large diffs are not rendered by default.
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -6,6 +6,7 @@ | |
| //! exported from ICU. | ||
|
|
||
| use crate::SourceDataProvider; | ||
| use crate::TrieType; | ||
| use icu::collections::char16trie::Char16Trie; | ||
| use icu::collections::codepointtrie::CodePointTrie; | ||
| use icu::normalizer::provider::*; | ||
|
|
@@ -26,7 +27,11 @@ macro_rules! normalization_provider { | |
| let $toml_data: &normalizer_serde::$serde_struct = | ||
| self.icuexport()?.read_and_parse_toml(&format!( | ||
| "norm/{}/{}.toml", | ||
| self.trie_type(), | ||
| if $file_name == "nfd" || $file_name == "nfkd" { | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. nit: link to issue or otherwise document why |
||
| TrieType::Fast | ||
| } else { | ||
| self.trie_type() | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. suggestion: document that the |
||
| }, | ||
| $file_name | ||
| ))?; | ||
|
|
||
|
|
||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. why is there no change here?
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Perhaps icuexportdata has a bug?
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ah CI is failing, these files are wrong
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah, well. I bet the new data is generated off of the real files, it's just the test data that didn't get updated correctly. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
observation: 23% and 18% size increase