diff --git a/clang/docs/tools/dump_format_style.py b/clang/docs/tools/dump_format_style.py index acb0dfcaf4a7..61167979b3e6 100755 --- a/clang/docs/tools/dump_format_style.py +++ b/clang/docs/tools/dump_format_style.py @@ -225,4 +225,4 @@ contents = open(DOC_FILE).read() contents = substitute(contents, 'FORMAT_STYLE_OPTIONS', options_text) with open(DOC_FILE, 'wb') as output: - output.write(contents) + output.write(contents.encode())