mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Disallow structural changes to TextElements; replace their children instead.
This commit is contained in:
parent
1433b5cb11
commit
8a5af56e62
@ -767,7 +767,8 @@ class BuildEnvironment:
|
||||
patch = new_document(source, settings)
|
||||
msgstr = translation.ugettext(msg)
|
||||
parser.parse(msgstr, patch)
|
||||
ctx.replace(node, patch.children)
|
||||
assert isinstance(patch[0], nodes.paragraph)
|
||||
node.children = patch[0].children
|
||||
|
||||
|
||||
def process_dependencies(self, docname, doctree):
|
||||
|
Loading…
Reference in New Issue
Block a user