Under some circumstances list syntax is parsed inside <pre> tags. The same happens with <syntaxhighlight> and additionaly causes a terribly mis-nested output. Example input:
```
The same happens with <syntaxhighlight> and additionaly causes a terribly mis-nested output.
Example input:
<pre>[[a]]
#[[a]]</pre>
----
*<pre>[[a]]
[[a]]</pre>
----
*<pre>[[a]]
#[[a]]</pre>```
Output:
```
<pre>[[a]]
#[[a]]</pre>
<hr>
<ul><li><pre>[[a]]
</pre></li></ul>
[[a]]
<hr>
<ul><li><pre>[[a]]
</pre></li></ul>
<ol><li>[[a]]
</li></ol>
No 1 is ok.
In No 2 the second line is outside the <pre>, but not parsed as wikisyntax. With <syntaxhighlight> instead of <pre> two additional </div>s appear (unless tidy removes them again).```
No 1 is ok. In No 2 the second line is outside the <pre>, but not parsed as wikisyntax. With <syntaxhighlight> instead of <pre> two additional </div>s appear (unless tidy removes them again). No 3 is like No 2, but the # is interpreted as wikisyntax for <ol>.
--------------------------
**Version**: 1.21.x
**Severity**: normal
**See also**: T3581