Re: Comment delimiters
Tue, 15 Nov 94 13:50:47 EST

The following grammar for SGML comments may help.

I don't want to get into this much detail really, so reply to me directly
if I'm wrong or whatever & I'll send out a summary.

Murry wrote
> From my reading of the SGML Handbook, white space
> would not be allowed between the -- (com) and the > (mdc).
> See section 10.3 on pages 390-391 of the Handbook.
It's really hard to read the handbook, although the standard is often even

The section Murray refers to gives
comment declaration = mdo, (comment, (s|comment)*)? mdc

Here, using the reference concrete syntax delimiter definitions (as does HTML)
mdo is <!
mdc is >
s is defined on p.297 as
an s separator is blank space that is inserted by the user...

comment = com, SGML character*, com

where com is --
SGML character is things that can appear in the document (i.e.
not SHUNCHAR things, in short)

so a comment is <! followed by one or more -- stuff -- sequences, followed
by a >, with any amount of optional whitespace interspresed.

<! -- this -- -- is a valid --
-- comment -- >
<!- - this isn't - ->


Liam Quin, Manager of Contracting, SoftQuad Inc +1 416 239 4801
HexSweeper NeWS game;OPEN LOOK+XView+mf-fonts FAQs;lq-text unix text retrieval
SoftQuad HoTMetaL:;