Skip to content

Commit

Permalink
update to Unicode 11.0.0 (closes bpo-33778) (GH-7439) (GH-7470)
Browse files Browse the repository at this point in the history
Also, standardize indentation of generated tables.
(cherry picked from commit 7c69c1c)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
  • Loading branch information
2 people authored and ned-deily committed Jun 7, 2018
1 parent d2a2af0 commit 4705ea3
Show file tree
Hide file tree
Showing 9 changed files with 28,286 additions and 26,103 deletions.
8 changes: 4 additions & 4 deletions Doc/library/unicodedata.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@

This module provides access to the Unicode Character Database (UCD) which
defines character properties for all Unicode characters. The data contained in
this database is compiled from the `UCD version 10.0.0
<http://www.unicode.org/Public/10.0.0/ucd>`_.
this database is compiled from the `UCD version 11.0.0
<http://www.unicode.org/Public/11.0.0/ucd>`_.

The module uses the same names and symbols as defined by Unicode
Standard Annex #44, `"Unicode Character Database"
Expand Down Expand Up @@ -168,6 +168,6 @@ Examples:

.. rubric:: Footnotes

.. [#] http://www.unicode.org/Public/10.0.0/ucd/NameAliases.txt
.. [#] http://www.unicode.org/Public/11.0.0/ucd/NameAliases.txt
.. [#] http://www.unicode.org/Public/10.0.0/ucd/NamedSequences.txt
.. [#] http://www.unicode.org/Public/11.0.0/ucd/NamedSequences.txt
4 changes: 2 additions & 2 deletions Doc/reference/lexical_analysis.rst
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ The Unicode category codes mentioned above stand for:
* *Nd* - decimal numbers
* *Pc* - connector punctuations
* *Other_ID_Start* - explicit list of characters in `PropList.txt
<http://www.unicode.org/Public/10.0.0/ucd/PropList.txt>`_ to support backwards
<http://www.unicode.org/Public/11.0.0/ucd/PropList.txt>`_ to support backwards
compatibility
* *Other_ID_Continue* - likewise

Expand Down Expand Up @@ -876,4 +876,4 @@ occurrence outside string literals and comments is an unconditional error:
.. rubric:: Footnotes

.. [#] http://www.unicode.org/Public/10.0.0/ucd/NameAliases.txt
.. [#] http://www.unicode.org/Public/11.0.0/ucd/NameAliases.txt
4 changes: 2 additions & 2 deletions Lib/test/test_unicodedata.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
class UnicodeMethodsTest(unittest.TestCase):

# update this, if the database changes
expectedchecksum = '727091e0fd5807eb41c72912ae95cdd74c795e27'
expectedchecksum = '97a41f208c53d5e08c77c1175187e95386b82b6f'

def test_method_checksum(self):
h = hashlib.sha1()
Expand Down Expand Up @@ -80,7 +80,7 @@ class UnicodeFunctionsTest(UnicodeDatabaseTest):

# Update this if the database changes. Make sure to do a full rebuild
# (e.g. 'make distclean && make') to get the correct checksum.
expectedchecksum = 'db6f92bb5010f8e85000634b08e77233355ab37a'
expectedchecksum = '4f73278b19c2ec3099724c132f0b90a1d25c19e4'
def test_function_checksum(self):
data = []
h = hashlib.sha1()
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Update ``unicodedata``'s database to Unicode version 11.0.0.
2 changes: 1 addition & 1 deletion Modules/unicodedata.c
Original file line number Diff line number Diff line change
Expand Up @@ -921,7 +921,7 @@ is_unified_ideograph(Py_UCS4 code)
{
return
(0x3400 <= code && code <= 0x4DB5) || /* CJK Ideograph Extension A */
(0x4E00 <= code && code <= 0x9FEA) || /* CJK Ideograph */
(0x4E00 <= code && code <= 0x9FEF) || /* CJK Ideograph */
(0x20000 <= code && code <= 0x2A6D6) || /* CJK Ideograph Extension B */
(0x2A700 <= code && code <= 0x2B734) || /* CJK Ideograph Extension C */
(0x2B740 <= code && code <= 0x2B81D) || /* CJK Ideograph Extension D */
Expand Down
Loading

0 comments on commit 4705ea3

Please sign in to comment.