]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-34512: Document platform-specific strftime() behavior for non-ASCII format string...
authorAlexey Izbyshev <izbyshev@ispras.ru>
Sat, 12 Jan 2019 17:21:54 +0000 (00:21 +0700)
committerTal Einat <taleinat+github@gmail.com>
Sat, 12 Jan 2019 17:21:54 +0000 (19:21 +0200)
Doc/library/datetime.rst

index db3a6522c24f78141fae6ae5d597135fbdd0f7d0..121f73bbe852471ae245f13375e8dd1ac619b7c0 100644 (file)
@@ -2034,6 +2034,12 @@ calls the platform C library's :func:`strftime` function, and platform
 variations are common.  To see the full set of format codes supported on your
 platform, consult the :manpage:`strftime(3)` documentation.
 
+For the same reason, handling of format strings containing Unicode code points
+that can't be represented in the charset of the current locale is also
+platform-dependent. On some platforms such code points are preserved intact in
+the output, while on others ``strftime`` may raise :exc:`UnicodeError` or return
+an empty string instead.
+
 The following is a list of all the format codes that the C standard (1989
 version) requires, and these work on all platforms with a standard C
 implementation.  Note that the 1999 version of the C standard added additional