diff options
author | Ryo Nihei <nihei.dev@gmail.com> | 2021-11-28 00:37:03 +0900 |
---|---|---|
committer | Ryo Nihei <nihei.dev@gmail.com> | 2021-11-28 13:53:18 +0900 |
commit | cb9d92f0b4e0097579f6e5da1dc6e2f063b532a9 (patch) | |
tree | 3d43aa9f3463f93451532d6dec9442a664d2d0a9 /ucd/property.go | |
parent | Move all UCD-related processes to ucd package (diff) | |
download | tre-cb9d92f0b4e0097579f6e5da1dc6e2f063b532a9.tar.gz tre-cb9d92f0b4e0097579f6e5da1dc6e2f063b532a9.tar.xz |
Make contributory properties unavailable except internal use
This change follows [UAX #44 5.13 Property APIs].
> The following subtypes of Unicode character properties should generally not be exposed in APIs,
> except in limited circumstances. They may not be useful, particularly in public API collections,
> and may instead prove misleading to the users of such API collections.
>
> * Contributory properties are not recommended for public APIs.
> ...
https://unicode.org/reports/tr44/#Property_APIs
Diffstat (limited to 'ucd/property.go')
-rw-r--r-- | ucd/property.go | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/ucd/property.go b/ucd/property.go index 71bbcad..0b2ac62 100644 --- a/ucd/property.go +++ b/ucd/property.go @@ -1,5 +1,19 @@ package ucd +// contributoryProperties is a set of contributory properties maleeni uses internally. Property statuses are +// defined in the following table. +// +// https://unicode.org/reports/tr44/#Property_List_Table +var contributoryProperties = []string{ + "oalpha", + "olower", + "oupper", +} + +func ContributoryProperties() []string { + return contributoryProperties +} + // https://www.unicode.org/reports/tr44/#GC_Values_Table var compositGeneralCategories = map[string][]string{ // Cased_Letter |