summaryrefslogtreecommitdiffstats
path: root/Parser
diff options
context:
space:
mode:
authorInada Naoki <songofacandy@gmail.com>2021-04-02 03:53:46 (GMT)
committerGitHub <noreply@github.com>2021-04-02 03:53:46 (GMT)
commit8bbfeb3330c10d52274bb85fce59ae614f0500bf (patch)
treee599878998ff1f8b1cf61bce14ff2a2037871a87 /Parser
parentbef7b26f7229f8b7cde843118a7bc7e2b00f0372 (diff)
downloadcpython-8bbfeb3330c10d52274bb85fce59ae614f0500bf.zip
cpython-8bbfeb3330c10d52274bb85fce59ae614f0500bf.tar.gz
cpython-8bbfeb3330c10d52274bb85fce59ae614f0500bf.tar.bz2
bpo-43651: PEP 597: Fix EncodingWarning in some tests (GH-25142)
* test__xxsubinterpreters * test_builtin * test_doctest * test_exceptions * test_opcodes * test_support * test_argparse * test_baseexception * test_bdb * test_bool * test_asdl_parser
Diffstat (limited to 'Parser')
-rw-r--r--Parser/asdl.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Parser/asdl.py b/Parser/asdl.py
index 7f50948..e3e6c34 100644
--- a/Parser/asdl.py
+++ b/Parser/asdl.py
@@ -204,7 +204,7 @@ def check(mod):
def parse(filename):
"""Parse ASDL from the given file and return a Module node describing it."""
- with open(filename) as f:
+ with open(filename, encoding="utf-8") as f:
parser = ASDLParser()
return parser.parse(f.read())