Problem with UL followed by OL

Kazutaka Matsuda kztk.matsuda at gmail.com
Wed Jan 23 16:14:18 EST 2008


I got a problem with UL followed by by OL
when I using perl module "Text-Markdown-1.0.5".

I wrote the following markdown code.
- a
- b

1. 1
2. 2
I expected that Text-Markdown would produce the following HTML.
<ul>
<li>a</li>
<li>b</li>
</ul>
<ol>
<li>1</li>
<li>2</li>
</ol>
However, "Text-Markdown-1.0.5" generated the following HTML.
<ul>
<li>a</li>
<li><p>b</p></li>
<li><p>1</p></li>
<li>2</li>
</ul>
At least for me, this is not intuitive.

I attached a patch for "Markdown.pm" in "Text-Markdown-1.0.5".
And, I also attached a simple test for the above.
I checked that patched "Text-Markdown" returns the same result as I expected.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: diff_ul_ol.patch
Type: application/octet-stream
Size: 1932 bytes
Desc: not available
Url : <http://six.pairlist.net/pipermail/markdown-discuss/attachments/20080124/43366b18/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ul_ol.t
Type: application/x-troff
Size: 306 bytes
Desc: not available
Url : <http://six.pairlist.net/pipermail/markdown-discuss/attachments/20080124/43366b18/attachment.t>


More information about the Markdown-Discuss mailing list