Re: [relax-ng] (Minor) inconstency between XML and compact syntaxes

From
James Clark <>
Date
2003-01-03T11:40:33+00:00
ID
002b01c2b31c$8ebf8ed0$
Thread
Re: [relax-ng] (Minor) inconstency between XML and compact syntaxes
> Not very important, but I have just noticed that...
>
> start = foo, bar
>
> is allowed while
>
> <start>
>  <ref name="foo"/>
>  <ref name="bar"/>
> </start>
>
> is forbidden (the content model of the start element accepts only one
> pattern).

The reason why the latter is forbidden is that there's a tendency to use it
assuming it means

<start>
  <choice>
    <ref name="foo"/>
    <ref name="bar"/>
  </choice>
</start>

(I think the corresponding thing in RELAX core had such a semantic).  Since
there's an explicit "," in the compact syntax, there's no such problem in
that case.

Anyway, in most cases

  start = foo, bar

will get an error because of 7.1.5.

James