spacing before list continuations
Jacob Rus
jrus at hcs.harvard.edu
Sun Jan 7 20:07:30 EST 2007
John MacFarlane wrote:
> Is this a bug, or should the documentated syntax be revised? This more
> relaxed behavior is nice in some cases, but it seems to cause problems
> in others. For example, this ought to be a nested list followed by a
> horizontal rule:
I say it's a bug, because it leads to problems like the weird lists when
you do:
1. blah
9. blah blah
10. blah blah blah
This stuff should be consistent, and any paragraph with <4 spaces of
indentation should be considered to exit any block elements, while any
between 4 and 7 spaces should be considered to continue the block. When
it comes to numbered/unnumbered lists, any number from 1-3 spaces should
be ignored, whereas 4-7 spaces should indicate one nested level, etc. etc.
These should be consistent between block quotes, numbered and unnumbered
lists, and any other present or future block elements.
And this stuff should be much more clearly explained in the syntax
definition on daringfireball.net, along with how implementations should
work on the edge cases.
Things like this are where having a true grammar really shows its
benefits, as the grammar clarifies both for humans and computers exactly
how the parsing should proceed. As is, it's hard to tell without
actually running some text through markdown.pl what is going to happen
with edge cases.
-Jacob
More information about the Markdown-Discuss
mailing list