]> granicus.if.org Git - python/commitdiff
Document unicode.isnumeric() and unicode.isdecimal() (issue2326)
authorSteven Bethard <steven.bethard@gmail.com>
Mon, 17 Mar 2008 19:33:11 +0000 (19:33 +0000)
committerSteven Bethard <steven.bethard@gmail.com>
Mon, 17 Mar 2008 19:33:11 +0000 (19:33 +0000)
Doc/library/stdtypes.rst

index f14c71bcea447ae4ed64576fe904c412a1f86d99..e967c26d90611f2cfde304e6932e26d3546e7f97 100644 (file)
@@ -1082,6 +1082,22 @@ string functions based on regular expressions.
 
    .. versionadded:: 2.2.2
 
+The following methods are present only on unicode objects:
+
+.. method:: unicode.isnumeric()
+
+   Return ``True`` if there are only numeric characters in S, ``False``
+   otherwise. Numeric characters include digit characters, and all characters
+   that have the Unicode numeric value property, e.g. U+2155,
+   VULGAR FRACTION ONE FIFTH.
+   
+.. method:: unicode.isdecimal()
+
+   Return ``True`` if there are only decimal characters in S, ``False``
+   otherwise. Decimal characters include digit characters, and all characters
+   that that can be used to form decimal-radix numbers, e.g. U+0660,
+   ARABIC-INDIC DIGIT ZERO.
+
 
 .. _string-formatting: