aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/libgnat/a-wichun.ads
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@adacore.com>2020-06-10 08:26:06 -0400
committerPierre-Marie de Rodat <derodat@adacore.com>2020-07-16 05:18:12 -0400
commit8e640a5f32160fd786cc4722c8b46bbca7ba500a (patch)
tree3c428cd1d4ba2585b9240fd889319769303aecd9 /gcc/ada/libgnat/a-wichun.ads
parent504dc34720756d4383f47fa48a0f40a5ad908146 (diff)
downloadgcc-8e640a5f32160fd786cc4722c8b46bbca7ba500a.zip
gcc-8e640a5f32160fd786cc4722c8b46bbca7ba500a.tar.gz
gcc-8e640a5f32160fd786cc4722c8b46bbca7ba500a.tar.bz2
[Ada] AI12-0004 Normalization and allowed characters
gcc/ada/ * scng.adb (Scan): Detect wide characters not in NFKC. * libgnat/a-chahan.adb, libgnat/a-chahan.ads, libgnat/a-wichha.adb, libgnat/a-wichha.ads, libgnat/a-wichun.adb, libgnat/a-wichun.ads, libgnat/a-zchhan.adb, libgnat/a-zchhan.ads, libgnat/a-zchuni.adb, libgnat/a-zchuni.ads (Is_NFKC): New. * libgnat/s-utf_32.ads, libgnat/s-utf_32.adb (Is_UTF_32_NFKC): New.
Diffstat (limited to 'gcc/ada/libgnat/a-wichun.ads')
-rw-r--r--gcc/ada/libgnat/a-wichun.ads8
1 files changed, 7 insertions, 1 deletions
diff --git a/gcc/ada/libgnat/a-wichun.ads b/gcc/ada/libgnat/a-wichun.ads
index c9eb938..9e42749 100644
--- a/gcc/ada/libgnat/a-wichun.ads
+++ b/gcc/ada/libgnat/a-wichun.ads
@@ -131,7 +131,7 @@ package Ada.Wide_Characters.Unicode is
pragma Inline (Is_Other);
-- Returns true iff U is an other format character, which means that it
-- can be used to extend an identifier, but is ignored for the purposes of
- -- matching of identiers, or if C is one of the corresponding categories,
+ -- matching of identifiers, or if C is one of the corresponding categories,
-- which are the following:
-- Other, Format (Cf)
@@ -150,6 +150,12 @@ package Ada.Wide_Characters.Unicode is
-- of the corresponding categories, which are the following:
-- Separator, Space (Zs)
+ function Is_NFKC (U : Wide_Character) return Boolean;
+ pragma Inline (Is_NFKC);
+ -- Returns True if the Wide_Character designated by U could be present
+ -- in a string normalized to Normalization Form KC (as defined by Clause
+ -- 21 of ISO/IEC 10646:2017), otherwise returns False.
+
function Is_Non_Graphic (U : Wide_Character) return Boolean;
function Is_Non_Graphic (C : Category) return Boolean;
pragma Inline (Is_Non_Graphic);