|
|
|
|
|
by 616c
4304 days ago
|
|
But what are we describing then. I like to see org, HTML, asciidoc, and XML as taking any data, in a very moronic basic sense, and annotating it or reshaping it for different kinds of parsers to accept. Am I missing the mark somehow in your comment? |
|
But we don't operate in pure data structures, AST's, etc, so there has to be some kind of abstraction. Sexpr are one approach, but even die-hard lisp-heads usually don't contend that it's the only one. The aforementioned scribble isn't sexpr-based, either. Most markup languages these days really try to avoid spurious line noise for something as simple as paragraphs.
The working elements of your average program are much more complicated and varied than those of your average marked up document, and quite often much easier to heuristically derive -- significant line-ends being one prime example. Quite rarely is there a need for deep hierarchies, for example.
HTML these days isn't just about formating content, so there's a much higher signal/noise ratio, where something like sexpr markup could improve upon spurious end tags, attributes etc. And this is even more true for most XML data.
So I'd see a use case for these kinds of complicated and generic scenarios. But for simple annotated content, outlines and the occasional date? Do you really want to write tables as nested s-expressions instead of just working automagically with a neat ascii-art representation?