summaryrefslogtreecommitdiff
path: root/docutils
diff options
context:
space:
mode:
authorwiemann <wiemann@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2007-07-01 22:35:49 +0000
committerwiemann <wiemann@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2007-07-01 22:35:49 +0000
commita14ed8b0df3142475a7b7eb767ffd7d6c7554da9 (patch)
treed839f3a3fcd19184c0dcbccd9d5fc1d26df2d617 /docutils
parent8c348ea8c72a7cedf1422e781b80cb43955a9ab3 (diff)
downloaddocutils-a14ed8b0df3142475a7b7eb767ffd7d6c7554da9.tar.gz
simplified parse_field_body so it puts everything into one paragraph; this does not make a difference since role/directive options cannot contain blank lines anyway
git-svn-id: http://svn.code.sf.net/p/docutils/code/branches/subdocs@5309 929543f6-e4f2-0310-98a6-ba3bd3dd1d04
Diffstat (limited to 'docutils')
-rw-r--r--docutils/parsers/rst/states.py9
1 files changed, 1 insertions, 8 deletions
diff --git a/docutils/parsers/rst/states.py b/docutils/parsers/rst/states.py
index 0cd7a9863..9afac5c8d 100644
--- a/docutils/parsers/rst/states.py
+++ b/docutils/parsers/rst/states.py
@@ -2509,14 +2509,7 @@ class ExtensionOptions(FieldList):
def parse_field_body(self, indented, offset, node):
"""Override `Body.parse_field_body` for simpler parsing."""
- lines = []
- for line in list(indented) + ['']:
- if line.strip():
- lines.append(line)
- elif lines:
- text = '\n'.join(lines)
- node += nodes.paragraph(text, text)
- lines = []
+ node += nodes.paragraph('\n'.join(indented), '\n'.join(indented))
class LineBlock(SpecializedBody):