forked from groonga/groonga
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
NormalizerNFKC: add
unify_katakana_z_sounds
option (groonga#1502)
When `unify_katakana_z_sounds` is specified, `NormalizerNFKC*` normalize characters as below. ズァ -> ザ ズィ -> ジ ズェ -> ゼ ズォ -> ゾ Usage: ``` normalize \ 'NormalizerNFKC130("unify_katakana_z_sounds", true, \ "report_source_offset", true)' \ "ズァズィズェズォ" \ WITH_CHECKS|WITH_TYPES ```
- Loading branch information
1 parent
f84cf01
commit 441d800
Showing
11 changed files
with
291 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 42 additions & 0 deletions
42
test/command/suite/normalizers/nfkc100/unify_katakana_z_sounds.expected
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
normalize 'NormalizerNFKC100("unify_katakana_z_sounds", true, "report_source_offset", true)' "ズァズィズズェズォ" WITH_CHECKS|WITH_TYPES | ||
[ | ||
[ | ||
0, | ||
0.0, | ||
0.0 | ||
], | ||
{ | ||
"normalized": "ザジズゼゾ", | ||
"types": [ | ||
"katakana", | ||
"katakana", | ||
"katakana", | ||
"katakana", | ||
"katakana" | ||
], | ||
"checks": [ | ||
6, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0, | ||
3, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0 | ||
], | ||
"offsets": [ | ||
0, | ||
6, | ||
12, | ||
15, | ||
21 | ||
] | ||
} | ||
] |
5 changes: 5 additions & 0 deletions
5
test/command/suite/normalizers/nfkc100/unify_katakana_z_sounds.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
normalize \ | ||
'NormalizerNFKC100("unify_katakana_z_sounds", true, \ | ||
"report_source_offset", true)' \ | ||
"ズァズィズズェズォ" \ | ||
WITH_CHECKS|WITH_TYPES |
42 changes: 42 additions & 0 deletions
42
test/command/suite/normalizers/nfkc121/unify_katakana_z_sounds.expected
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
normalize 'NormalizerNFKC121("unify_katakana_z_sounds", true, "report_source_offset", true)' "ズァズィズズェズォ" WITH_CHECKS|WITH_TYPES | ||
[ | ||
[ | ||
0, | ||
0.0, | ||
0.0 | ||
], | ||
{ | ||
"normalized": "ザジズゼゾ", | ||
"types": [ | ||
"katakana", | ||
"katakana", | ||
"katakana", | ||
"katakana", | ||
"katakana" | ||
], | ||
"checks": [ | ||
6, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0, | ||
3, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0 | ||
], | ||
"offsets": [ | ||
0, | ||
6, | ||
12, | ||
15, | ||
21 | ||
] | ||
} | ||
] |
5 changes: 5 additions & 0 deletions
5
test/command/suite/normalizers/nfkc121/unify_katakana_z_sounds.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
normalize \ | ||
'NormalizerNFKC121("unify_katakana_z_sounds", true, \ | ||
"report_source_offset", true)' \ | ||
"ズァズィズズェズォ" \ | ||
WITH_CHECKS|WITH_TYPES |
42 changes: 42 additions & 0 deletions
42
test/command/suite/normalizers/nfkc130/unify_katakana_z_sounds.expected
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
normalize 'NormalizerNFKC130("unify_katakana_z_sounds", true, "report_source_offset", true)' "ズァズィズズェズォ" WITH_CHECKS|WITH_TYPES | ||
[ | ||
[ | ||
0, | ||
0.0, | ||
0.0 | ||
], | ||
{ | ||
"normalized": "ザジズゼゾ", | ||
"types": [ | ||
"katakana", | ||
"katakana", | ||
"katakana", | ||
"katakana", | ||
"katakana" | ||
], | ||
"checks": [ | ||
6, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0, | ||
3, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0 | ||
], | ||
"offsets": [ | ||
0, | ||
6, | ||
12, | ||
15, | ||
21 | ||
] | ||
} | ||
] |
5 changes: 5 additions & 0 deletions
5
test/command/suite/normalizers/nfkc130/unify_katakana_z_sounds.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
normalize \ | ||
'NormalizerNFKC130("unify_katakana_z_sounds", true, \ | ||
"report_source_offset", true)' \ | ||
"ズァズィズズェズォ" \ | ||
WITH_CHECKS|WITH_TYPES |
42 changes: 42 additions & 0 deletions
42
test/command/suite/normalizers/nfkc150/unify_katakana_z_sounds.expected
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
normalize 'NormalizerNFKC150("unify_katakana_z_sounds", true, "report_source_offset", true)' "ズァズィズズェズォ" WITH_CHECKS|WITH_TYPES | ||
[ | ||
[ | ||
0, | ||
0.0, | ||
0.0 | ||
], | ||
{ | ||
"normalized": "ザジズゼゾ", | ||
"types": [ | ||
"katakana", | ||
"katakana", | ||
"katakana", | ||
"katakana", | ||
"katakana" | ||
], | ||
"checks": [ | ||
6, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0, | ||
3, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0, | ||
6, | ||
0, | ||
0 | ||
], | ||
"offsets": [ | ||
0, | ||
6, | ||
12, | ||
15, | ||
21 | ||
] | ||
} | ||
] |
5 changes: 5 additions & 0 deletions
5
test/command/suite/normalizers/nfkc150/unify_katakana_z_sounds.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
normalize \ | ||
'NormalizerNFKC150("unify_katakana_z_sounds", true, \ | ||
"report_source_offset", true)' \ | ||
"ズァズィズズェズォ" \ | ||
WITH_CHECKS|WITH_TYPES |