Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion Lib/test/test_ucn.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

"""#"

import ast
import unittest
import unicodedata

Expand All @@ -24,7 +25,7 @@ def checkletter(self, name, code):
# Helper that put all \N escapes inside eval'd raw strings,
# to make sure this script runs even if the compiler
# chokes on \N escapes
res = eval(r'"\N{%s}"' % name)
res = ast.literal_eval(r'"\N{%s}"' % name)
self.assertEqual(res, code)
return res

Expand Down