test-base64: Improve.
[gnulib.git] / lib / unictype.h
index b4cee65..ae47d11 100644 (file)
@@ -1,5 +1,5 @@
 /* Unicode character classification and properties.
-   Copyright (C) 2002, 2005-2007 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2005-2009 Free Software Foundation, Inc.
 
    This program is free software: you can redistribute it and/or modify it
    under the terms of the GNU Lesser General Public License as published
@@ -56,7 +56,8 @@ uc_general_category_t;
 
 /* Bits and bit masks denoting General category values.  UnicodeData-3.2.0.html
    says a 32-bit integer will always suffice to represent them.
-   These bit masks are just informative; you cannot use them in any API.  */
+   These bit masks can only be used with the uc_is_general_category_withtable
+   function.  */
 enum
 {
   UC_CATEGORY_MASK_L  = 0x0000001f,
@@ -212,7 +213,7 @@ extern uc_general_category_t
        uc_general_category (ucs4_t uc);
 
 /* Test whether a Unicode character belongs to a given category.
-   The CATEGORY argument can be the combination of several built-in
+   The CATEGORY argument can be the combination of several predefined
    general categories.  */
 extern bool
        uc_is_general_category (ucs4_t uc, uc_general_category_t category);
@@ -247,7 +248,7 @@ enum
   UC_CCC_AR   = 232, /* Above Right */
   UC_CCC_DB   = 233, /* Double Below */
   UC_CCC_DA   = 234, /* Double Above */
-  UC_CCC_IS   = 240, /* Iota Subscript */
+  UC_CCC_IS   = 240  /* Iota Subscript */
 };
 
 /* Return the canonical combining class of a Unicode character.  */
@@ -301,7 +302,7 @@ extern bool
 /* ========================================================================= */
 
 /* Field 5 of Unicode Character Database: Character decomposition mapping.
-   See "unicomp.h".  */
+   See "uninorm.h".  */
 
 /* ========================================================================= */
 
@@ -462,6 +463,9 @@ extern const uc_property_t UC_PROPERTY_IGNORABLE_CONTROL;
 extern uc_property_t
        uc_property_byname (const char *property_name);
 
+/* Test whether a property is valid.  */
+#define uc_property_is_valid(property) ((property).test_fn != NULL)
+
 /* Test whether a Unicode character has a given property.  */
 extern bool
        uc_is_property (ucs4_t uc, uc_property_t property);
@@ -547,7 +551,7 @@ extern bool uc_is_property_ignorable_control (ucs4_t uc);
 
 /* ========================================================================= */
 
-/* Subdivision of the the Unicode characters into scripts.  */
+/* Subdivision of the Unicode characters into scripts.  */
 
 typedef struct
 {
@@ -693,9 +697,8 @@ extern bool
 extern bool
        uc_is_upper (ucs4_t uc);
 
-/* Test for any character that corresponds to a hexadecimal-digit character
-   equivalent to that performed by the functions described in the previous
-   subclause.  */
+/* Test for any character that corresponds to a hexadecimal-digit
+   character.  */
 extern bool
        uc_is_xdigit (ucs4_t uc);