W3C home > Mailing lists > Public > w3c-ietf-xmldsig@w3.org > April to June 2001

RE: Erratum in section 1.1 of Canonical XML

From: Elliotte Rusty Harold <elharo@metalab.unc.edu>
Date: Wed, 9 May 2001 13:02:36 -0400
Message-Id: <p0433010ab71f23c68d4c@[192.168.1.4]>
To: "John Boyer" <JBoyer@PureEdge.com>
Cc: w3c-ietf-xmldsig@w3.org
>Hi Elliotte,
>
>I'd appreciate it if you'd elaborate on this point a bit more.  For my
>own case, I currently believe that DTD is used interchangeably as an
>abbreviation for both the document type definition grammar and the
>document type declaration.  Note, however, that I take my understanding
>of what DTD means directly from its usage in the XML Recommendation [1],
>which incidentally seems to use DTD more often to refer to the
>DTDeclaration. Moreover, the same usage for DTD appears in XPath [2].
>

They certainly are commonly used this way. However I find that use to 
be misleading and claim it is mistaken. The document type declaration 
and document type definition are two different things and need two 
different abbreviations. "Document type declaration" can be 
abbreviated "DOCTYPE declaration" if necessary. It cannot be 
abbreviated DTD.

The only truly normative spec on this point is XML 1.0. In the 2nd 
edition section 2.8 clearly states:

[Definition: The XML document type declaration contains or points to 
markup declarations that provide a grammar for a class of documents. 
This grammar is known as a document type definition, or DTD. The 
document type declaration can point to an external subset (a special 
kind of external entity) containing markup declarations, or can 
contain the markup declarations directly in an internal subset, or 
can do both. The DTD for a document consists of both subsets taken 
together.]

This normative part of the spec clearly indicates that "DTD" means 
"document type definition" and is distinguished from "document type 
declaration"

I have searched through the XML spec for every occurrence of the 
string "DTD" and I cannot find one which suggests that DTD can 
sometimes mean "document type declaration".

I've also searched the XPath spec and cannot find any place where the 
acronym "DTD" is used to indicate a document type declaration. 
However, even if there were such a place, it would only indicate a 
mistake in the XPath spec. (I did find one place where the phrase 
"external DTD" was used instead of the more proper "external DTD 
subset". However, that's a minor mistake that doesn't affect what 
we're discussing here.)

Indeed I've made this mistake myself in the past, and in hindsight it 
always reflected confusion on my part about just what I was saying. 
It's unfortunate that document type declaration seems to have the 
same natural acronym as the closely related document type definition. 
However, this unfortunate confluence makes it all the more important 
that we use the term "DTD" very carefully and precisely, especially 
in other specifications.
-- 

+-----------------------+------------------------+-------------------+
| Elliotte Rusty Harold | elharo@metalab.unc.edu | Writer/Programmer |
+-----------------------+------------------------+-------------------+
|                  The XML Bible (IDG Books, 1999)                   |
|              http://metalab.unc.edu/xml/books/bible/               |
|   http://www.amazon.com/exec/obidos/ISBN=0764532367/cafeaulaitA/   |
+----------------------------------+---------------------------------+
|  Read Cafe au Lait for Java news:  http://metalab.unc.edu/javafaq/ |
|  Read Cafe con Leche for XML news: http://metalab.unc.edu/xml/     |
+----------------------------------+---------------------------------+
Received on Wednesday, 9 May 2001 13:09:49 GMT

This archive was generated by hypermail 2.2.0 + w3c-0.29 : Thursday, 13 January 2005 12:10:13 GMT