DTD / xmerl_scan:file help !!!!! {invalid_nmtoken,"*) #RE"

Richard A. O'Keefe <>
Thu Jul 14 00:32:01 CEST 2005

Helmut Enck-Radana <> wrote:
	in XML DTDs enumerated values have to be NMTOKENs, i.e. you can only use 
	strings which could be used as names.

That's not quite right.  All Names are Nmtokens, but Names have to start
with a letter, and Nmtokens don't.  1 is an Nmtoken but not a Name.

An extremely horrible design glitch in SGML is that SGML uses "--" to begin
a comment, but "--" is also an Nmtoken.  There are thus a number of places
where any reasonable person would expect to be able to write a comment, but
you can't.

	You have to use a different schema language,

One of the features in the full version of SGML is that an attribute
can be specified as "DATA <notation> <pattern>" where <notation> specifies
one of the standardised regular expression notations and <pattern> is a
pattern in that notation saying what good values look like.  I've always
thought it a pity that XML didn't retain that feature.

More information about the erlang-questions mailing list