summaryrefslogtreecommitdiff
path: root/Lib/test/test_fstring.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2019-08-10 01:34:22 +0300
committerGregory P. Smith <greg@krypto.org>2019-08-09 15:34:22 -0700
commit4c5b6bac2408f879231c7cd38d67657dd4804e7c (patch)
tree71c68d4bea17e42da6f071920c48c2492c77fe38 /Lib/test/test_fstring.py
parent217077440a6938a0b428f67cfef6e053c4f8673c (diff)
downloadcpython-git-4c5b6bac2408f879231c7cd38d67657dd4804e7c.tar.gz
[3.8] bpo-32912: Revert SyntaxWarning on invalid escape sequences (GH-15142)
* bpo-32912: Revert warnings for invalid escape sequences. DeprecationWarning will continue to be emitted for invalid escape sequences in string and bytes literals in 3.8 just as it did in 3.7. SyntaxWarning may be emitted in the future. But per mailing list discussion, we don't yet know when because we haven't settled on how to do so in a non-disruptive manner.
Diffstat (limited to 'Lib/test/test_fstring.py')
-rw-r--r--Lib/test/test_fstring.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_fstring.py b/Lib/test/test_fstring.py
index fb761441fc..49663923e7 100644
--- a/Lib/test/test_fstring.py
+++ b/Lib/test/test_fstring.py
@@ -649,7 +649,7 @@ non-important content
self.assertEqual(f'2\x203', '2 3')
self.assertEqual(f'\x203', ' 3')
- with self.assertWarns(SyntaxWarning): # invalid escape sequence
+ with self.assertWarns(DeprecationWarning): # invalid escape sequence
value = eval(r"f'\{6*7}'")
self.assertEqual(value, '\\42')
self.assertEqual(f'\\{6*7}', '\\42')