Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e43baab

Browse files
committed
Fix nits in the lexical analysis section: \u requires four digits, backtick is not allowed in source in 3.x.
1 parent b496bad commit e43baab

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

Doc/reference/lexical_analysis.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -512,13 +512,13 @@ Notes:
512512

513513
(4)
514514
Individual code units which form parts of a surrogate pair can be encoded using
515-
this escape sequence. Unlike in Standard C, exactly two hex digits are required.
515+
this escape sequence. Exactly four hex digits are required.
516516

517517
(5)
518518
Any Unicode character can be encoded this way, but characters outside the Basic
519519
Multilingual Plane (BMP) will be encoded using a surrogate pair if Python is
520-
compiled to use 16-bit code units (the default). Individual code units which
521-
form parts of a surrogate pair can be encoded using this escape sequence.
520+
compiled to use 16-bit code units (the default). Exactly eight hex digits
521+
are required.
522522

523523

524524
.. index:: unrecognized escape sequence
@@ -700,4 +700,4 @@ tokens or are otherwise significant to the lexical analyzer::
700700
The following printing ASCII characters are not used in Python. Their
701701
occurrence outside string literals and comments is an unconditional error::
702702

703-
$ ?
703+
$ ? `

0 commit comments

Comments
 (0)