Commit 35608b78 authored by Stefan Behnel's avatar Stefan Behnel

decode included filenames as we can't handle byte encoded filenames in Py3

parent b387b235
......@@ -1430,6 +1430,7 @@ def p_include_statement(s, ctx):
_, include_file_name = p_string_literal(s)
s.expect_newline("Syntax error in include statement")
if s.compile_time_eval:
include_file_name = include_file_name.decode(s.source_encoding)
include_file_path = s.context.find_include_file(include_file_name, pos)
if include_file_path:
s.included_files.append(include_file_name)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment