4 ms·
The HTML example is much better than "}}}}} though, since you can e.g. add a new item at the end of the list without needing a specialized editor to locate the
by olavk 9y ago
The HTML example is much better than "}}}}} though, since you can e.g. add a new item at the end of the list without needing a specialized editor to locate the right position. This is one of the reasons for the redundancy in repeating the tag name in the end-tag. In theory Lisp should have the same problem, but usually code (hopefully) rarely have nested blocks larger than a screen, so it is not a big issue in practice, even if )))) looks ugly. Bottom line is code have a different structure than typical hypertext documents, so just because a notation is suitable for one does not mean it is suitable for the other.
- henryluo 9y agoBut when s-expression is used to represent document, not a program, then it is also not free to refactor deep nested content. So s-expression is no better than XML/HTML/JSON/Mark when encountering deep nested content.
- olavk 9y agoIt is exactly the same as Mark, but I am arguing it is worse than XML/HTML for these scenarios.
- phoe-krk 9y agowithout needing a specialized editor to locate the right position Paren-matching is a commodity today in all sane programming editors. It is no longer anything you could call "specialized".