there's no payoff in confusing the users
david.chambers.05 at gmail.com
Thu Dec 1 20:02:40 EST 2011
I find discussion of techniques for building Markdown parsers very
interesting. It's slightly off topic, perhaps, but I don't think this list
is large enough to spawn a separate "Markdown implementers" list.
On 1 December 2011 16:53, Seumas Mac Uilleachan <seumas at idirect.ca> wrote:
> On 12/01/2011 11:37 AM, Bowerbird at aol.com wrote:
> john said:
> > Have you considered using a PEG instead of regexes?
> for all you home-schooled and self-taught programmers
> for whom "peg" is far too computer-sciencey for comfort,
> consider as an alternative the simple methodology i use...
> i split the text-file on blank lines and place it in an array.
> that is first-cut for my light-markup format, a.k.a., "zml"
> -- zen markup language -- but it's alright with me if you
> markdown people want to borrow it for your own purpose.
> i mean, seriously, it's not like i could patent it, or anything.
> (but, on second thought, perhaps i _should_ at least apply.)
> then i walk the array, analyzing each item to see what it is;
> the chunk might get tagged as a blockquote, or a heading,
> or a list item, or a plain old paragraph, or _whatever_ it is.
> then i walk the array again, using the tag for each chunk to
> generate the appropriate output for the desired format(s)...
> (sometimes the tag, or the output, is dependent upon the
> surrounding chunks, and that's the reason i walk it twice.)
> it's the methodology of a simpleton, i am the first to admit,
> but it works, and it works well, and it works sufficiently fast.
> best of all, for me, is that it's extremely easy to understand.
> even better, for everyone: it's easy for users to understand.
> after all, there's no payoff in confusing the users. is there?
> p.s. "alright" is a word i like to use... it's akin to "already"...
> Markdown-Discuss mailing listMarkdown-Discuss at six.pairlist.nethttp://six.pairlist.net/mailman/listinfo/markdown-discuss
> What confuses me is what this all has to do with markdown.
> Markdown-Discuss mailing list
> Markdown-Discuss at six.pairlist.net
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Markdown-Discuss