Re: KISS (was: Parameter entity references in WF docs)

Christopher R. Maden <crm@eps.inso.com> wrote"
> I find [parements] invaluable for both readability
> and maintenance of content models like (#PCDATA|%flow;)*.  I typically
> use a content model like this everywhere #PCDATA is allowed;
> maintaining the list of flow-level elements in every single possible
> container would be a nightmare, and reading the content model is
> easier this way.

Yes, I agree with you.  If XML didn't support %RunningText; in this way,
I'd use a separate preprocessor to do it.  If I was going to do that, I'd
probably start keeping my DTD itself in XML, and translate on the fly,
as then I could simply use &TunningText; instead!

> Using PEs in ATTLISTs (for universal attributes like ID) is debatable;
> the change in readability is not as severe.
I agree.  Worse, they are sometimes used as a sort of formulaic idiom,
often giving attributes on every element without considering why.o

The best thing about losing PEs might be that DTDs could no longer contain
the infamous
    p.ZZ
entity still all to often seen.... :-)

Seriously, since you have to implement general entities anyway, I don't
see PEs as being much harder, if you parse a DTD at all.  I agree that it
is worth restricting them and clarifying the spec.

Lee

Received on Wednesday, 4 June 1997 13:32:45 UTC