diff options
| author | Serge Guelton <sguelton@quarkslab.com> | 2019-01-03 14:11:33 +0000 |
|---|---|---|
| committer | Serge Guelton <sguelton@quarkslab.com> | 2019-01-03 14:11:33 +0000 |
| commit | 4a27478a5b8bd9f13fef65e66b291a352c532371 (patch) | |
| tree | a086542fe11fba6d8779ca2fa96036d80af04312 /llvm/docs/conf.py | |
| parent | 41f98c834bc62a605ec51032482369cfa128d711 (diff) | |
Python compat - print statement
Make sure all print statements are compatible with Python 2 and Python3 using
the `from __future__ import print_function` statement.
Differential Revision: https://reviews.llvm.org/D56249
llvm-svn: 350307
Diffstat (limited to 'llvm/docs/conf.py')
| -rw-r--r-- | llvm/docs/conf.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/llvm/docs/conf.py b/llvm/docs/conf.py index 254f334c013b..7fdcb3d2f525 100644 --- a/llvm/docs/conf.py +++ b/llvm/docs/conf.py @@ -9,6 +9,7 @@ # # All configuration values have a default; values that are commented out # serve to show the default. +from __future__ import print_function import sys, os from datetime import date @@ -234,14 +235,14 @@ for name in os.listdir(command_guide_path): header = f.readline().rstrip('\n') if len(header) != len(title): - print >>sys.stderr, ( + print(( "error: invalid header in %r (does not match title)" % ( - file_subpath,)) + file_subpath,)), file=sys.stderr) if ' - ' not in title: - print >>sys.stderr, ( + print(( ("error: invalid title in %r " "(expected '<name> - <description>')") % ( - file_subpath,)) + file_subpath,)), file=sys.stderr) # Split the name out of the title. name,description = title.split(' - ', 1) |
