RedCloth master generates a spurios
undumbered list is followed by three or more newlines.
RedCloth.new("* one\n* two\n* three \n\n\n").to_html
- one \n\t
- two \n\t
- three \n
note extra trailing
A colleague generated a pull request with a new rspec test that exposes
I checked and the bug is present on master.
I just took a look at the ragel code but it’s been quite a while since
I’ve used ragel and it’s not quite as easy to parse as
Seems like li_open in lib/redcloth/formatters/html.rb is being called
incorrectly when the thrid newline is parsed.
Here are the locations in the code where li_open is referenced:
$ ack --all-types li_open
202: ASET(“type”, “li_open”);
95: ASET(“type”, “li_open”);
50: def li_open(opts)
103: def li_open(opts)
94: ASET(“type”, “li_open”);
309: ASET(“type”, “li_open”)