aboutsummaryrefslogtreecommitdiff
path: root/llvm/docs/conf.py
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2012-08-28 17:18:27 +0000
committerBill Wendling <isanbard@gmail.com>2012-08-28 17:18:27 +0000
commit783e7c02c6348a634fbbcfd46357125eafb87c40 (patch)
treea45184af8f7ffb8b3df11ec8c56fad51c9b7ae1d /llvm/docs/conf.py
parent48f498fccf84d4b8888a567884cb935a4f457741 (diff)
downloadllvm-783e7c02c6348a634fbbcfd46357125eafb87c40.zip
llvm-783e7c02c6348a634fbbcfd46357125eafb87c40.tar.gz
llvm-783e7c02c6348a634fbbcfd46357125eafb87c40.tar.bz2
Patch by Sean Silva to un-barf his computer by explicitly removing the '\n'
character instead of always the last character. llvm-svn: 162767
Diffstat (limited to 'llvm/docs/conf.py')
-rw-r--r--llvm/docs/conf.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/docs/conf.py b/llvm/docs/conf.py
index de0585d..f7b3a07 100644
--- a/llvm/docs/conf.py
+++ b/llvm/docs/conf.py
@@ -237,9 +237,8 @@ for name in os.listdir(command_guide_path):
# Otherwise, automatically extract the description.
file_subpath = os.path.join(command_guide_subpath, name)
with open(os.path.join(command_guide_path, name)) as f:
- it = iter(f)
- title = it.next()[:-1]
- header = it.next()[:-1]
+ title = f.readline().rstrip('\n')
+ header = f.readline().rstrip('\n')
if len(header) != len(title):
print >>sys.stderr, (