Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
9bc4f2de
Commit
9bc4f2de
authored
Jun 03, 2004
by
Martin v. Löwis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Drop claims that Unicode always means UCS-2. Fixes #881861.
parent
4a9b8069
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
9 deletions
+10
-9
Doc/api/concrete.tex
Doc/api/concrete.tex
+4
-3
Doc/api/utilities.tex
Doc/api/utilities.tex
+6
-6
No files found.
Doc/api/concrete.tex
View file @
9bc4f2de
...
...
@@ -1109,9 +1109,10 @@ These are the UTF-16 codec APIs:
the Unicode BOM mark (U+FEFF). In the other two modes, no BOM mark
is prepended.
Note that
\ctype
{
Py
_
UNICODE
}
data is being interpreted as UTF-16
reduced to UCS-2. This trick makes it possible to add full UTF-16
capabilities at a later point without comprimising the APIs.
If
\var
{
Py
_
UNICODE
_
WIDE
}
is defined, a single
\ctype
{
Py
_
UNICODE
}
value may get represented as a surrogate pair. If it is not
defined, each
\ctype
{
Py
_
UNICODE
}
values is interpreted as an
UCS-2 character.
Returns
\NULL
{}
if an exception was raised by the codec.
\end{cfuncdesc}
...
...
Doc/api/utilities.tex
View file @
9bc4f2de
...
...
@@ -780,14 +780,14 @@ PyArg_ParseTuple(args, "O|O:ref", &object, &callback)
Same as
\samp
{
s
\#
}
.
\item
[\samp{u} (Unicode string) {[Py_UNICODE *]
}
]
Convert a null-terminated buffer of Unicode (UCS-2
) data to a
Python Unicode object. If the Unicode buffer pointer is
\NULL
,
\code
{
None
}
is returned.
Convert a null-terminated buffer of Unicode (UCS-2
or UCS-4)
data to a Python Unicode object. If the Unicode buffer pointer
is
\NULL
,
\code
{
None
}
is returned.
\item
[\samp{u\#} (Unicode string) {[Py_UNICODE *, int]
}
]
Convert a Unicode (UCS-2
) data buffer and its length to a Python
Unicode object. If the Unicode buffer pointer is
\NULL
, the
length is ignored and
\code
{
None
}
is returned.
Convert a Unicode (UCS-2
or UCS-4) data buffer and its length
to a Python Unicode object. If the Unicode buffer pointer
is
\NULL
, the
length is ignored and
\code
{
None
}
is returned.
\item
[\samp{i} (integer) {[int]
}
]
Convert a plain C
\ctype
{
int
}
to a Python integer object.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment