Move MathML tree simplification from `mrow.close()` to `parse_latex_math()`.
commiteb3920394a39ba92216d64b2c8816eca258a1175
authormilde <milde@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>
Thu, 1 Feb 2024 13:02:01 +0000 (1 13:02 +0000)
committermilde <milde@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>
Thu, 1 Feb 2024 13:02:01 +0000 (1 13:02 +0000)
tree2909388774d6c59f276958c5710c3968a85f51d6
parent6d3f01267ad3b8fa0d6cf8ea899f58103b66fa02
Move MathML tree simplification from `mrow.close()` to `parse_latex_math()`.

Do not open a new `<mrow>` (only to remove it afterwards)
for commands like ``\sqrt{3 +1}`` (LaTeX macro takes one argument
but `<sqrt>` node accepts a group).

Note: The replacement of `mrow` by a single child node remains
in the `mrow.close()` method, because we don't know in forehand
whether there is only one child.

git-svn-id: http://svn.code.sf.net/p/docutils/code/trunk@9524 929543f6-e4f2-0310-98a6-ba3bd3dd1d04
docutils/docutils/utils/math/latex2mathml.py
docutils/docutils/utils/math/mathml_elements.py