diff options
Diffstat (limited to 'pygments/lexers/_mysql_builtins.py')
-rw-r--r-- | pygments/lexers/_mysql_builtins.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pygments/lexers/_mysql_builtins.py b/pygments/lexers/_mysql_builtins.py index d266789c..cbcc9b8b 100644 --- a/pygments/lexers/_mysql_builtins.py +++ b/pygments/lexers/_mysql_builtins.py @@ -1317,7 +1317,7 @@ if __name__ == '__main__': # pragma: no cover def update_content(field_name, content): """Overwrite this file with content parsed from MySQL's source code.""" - with open(__file__) as f: + with open(__file__, encoding="utf-8") as f: data = f.read() # Line to start/end inserting @@ -1329,7 +1329,7 @@ if __name__ == '__main__': # pragma: no cover new_block = format_lines(field_name, content) data = data[:m.start()] + new_block + data[m.end():] - with open(__file__, 'w', newline='\n') as f: + with open(__file__, 'w', encoding='utf-8', newline='\n') as f: f.write(data) update_myself() |