summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
Diffstat (limited to 'Doc')
-rw-r--r--Doc/whatsnew/3.8.rst7
1 files changed, 7 insertions, 0 deletions
diff --git a/Doc/whatsnew/3.8.rst b/Doc/whatsnew/3.8.rst
index bf8d8f1..0360be6 100644
--- a/Doc/whatsnew/3.8.rst
+++ b/Doc/whatsnew/3.8.rst
@@ -442,6 +442,13 @@ Changes in Python behavior
in the leftmost :keyword:`!for` clause).
(Contributed by Serhiy Storchaka in :issue:`10544`.)
+* The compiler now produces a :exc:`SyntaxWarning` when identity checks
+ (``is`` and ``is not``) are used with certain types of literals
+ (e.g. strings, ints). These can often work by accident in CPython,
+ but are not guaranteed by the language spec. The warning advises users
+ to use equality tests (``==`` and ``!=``) instead.
+ (Contributed by Serhiy Storchaka in :issue:`34850`.)
+
Changes in the Python API
-------------------------