minirst: look for column delimiters using slices instead of indicies
This works on both Python 2 and 3.
--- a/mercurial/minirst.py Sun May 28 13:36:02 2017 -0400
+++ b/mercurial/minirst.py Sun May 28 15:47:43 2017 -0400
@@ -315,7 +315,8 @@
# column markers are ASCII so we can calculate column
# position in bytes
columns = [x for x in xrange(len(div))
- if div[x] == '=' and (x == 0 or div[x - 1] == ' ')]
+ if div[x:x + 1] == '=' and (x == 0 or
+ div[x - 1:x] == ' ')]
rows = []
for l in block['lines'][1:-1]:
if l == div: