- From: Rick Jelliffe <ricko@allette.com.au>
- Date: Fri, 11 Oct 1996 18:24:55 +1000 (EST)
- To: lee@sq.com
- Cc: Charles@sgmlsource.com, w3c-sgml-wg@w3.org
On Thu, 10 Oct 1996 lee@sq.com wrote: > But I expect that XML will have SGML's weird multiple syntaxes... :-( Is the programming language world really so simple? What about C++? It has three comment delimiters: // for C++ /* */ from C # (at beginnning of line) from cpp It has different delimiters for blocks ( {} ) and statements ( ; ) and function calls ( () ). People complain that LISP is difficult to read because it only has one delimiter for comments and one for function calls. The reasons for C++'s multiple comments delimiters might be artifacts of its implementation history, but C++ syntax is more popular than LISP syntax, as Java proves. One very good reason for tag delimiters and comment delimiters to be different is that if they are different non-SGML-aware text tools can play with them. E.g. off-the-shelf text editors can display markup in different colors, if they they can detect the markup easily. This is something we use a real lot here, and we even make sure our SGML documents are marked up so that the simple detection mechanism based on delimiters with no context will be reliable: e.g. < and & always must be done by entity references, and CDATA content models are deprecated. (I guess it means we already try to make our in-process documents more like XML already.) While it might be good to have a comment declaration like you suggested in SGML, I think it would be a terrible idea in XML: anything that requires context or previous declarations to parse should be viewed as suspect and complicating. But even in SGML, you could declare an architectural form or fixed attribute for an element that labels it as having the nature of a comment. Rick Jelliffe http://www.allette.com.au/allette/ricko email: ricko@allette.com.au ================================================================ Allette Systems http://www.allette.com.au email: info@allette.com.au 10/91 York St, 2000, phone: +61 2 9262 4777 Sydney, Australia fax: +61 2 9262 4774 ================================================================
Received on Friday, 11 October 1996 04:53:06 UTC