minirst: do not add a 2nd empty paragraph
This does not add a separating block after a separated note directive.
.. note::
text
is formatted to
Note:
text
--- a/mercurial/minirst.py Mon Nov 04 10:23:06 2013 +0100
+++ b/mercurial/minirst.py Mon Nov 04 10:23:06 2013 +0100
@@ -381,6 +381,9 @@
if (blocks[i]['type'] == blocks[i - 1]['type'] and
blocks[i]['type'] in ('bullet', 'option', 'field')):
i += 1
+ elif not blocks[i - 1]['lines']:
+ # no lines in previous block, do not seperate
+ i += 1
else:
blocks.insert(i, dict(lines=[''], indent=0, type='margin'))
i += 2