-
Notifications
You must be signed in to change notification settings - Fork 8
Description
Definition of pattern in the tutorial (chapter 8) is wrong because
<mixed> p </mixed>
is NOT short for
<interleave> <text/> p </interleave>
but IS short for
<interleave> <text/> <group> p </group> </interleave>
(of course when p is >1)
Apparently this omission has history:
https://markmail.org/thread/opo5titnrythjnsy
https://markmail.org/message/nypy2dk24rtavg3o
The automagic grouping came straight from TREX and I did not find any discussion how it is motivated. Why specification authors decided on such exotic usability? The O'Reilly book "RELAX NG" even has a chapter "6.8 Mixed Content Models with Order" which states that a grouping is a special additional possibility: "If you want to fix the order of the child elements, just embed a group pattern inside a mixed pattern" + "These content models are quite unusual in XML". I totally agree with the later and wish to future RELAX NG users more luck learning about <mixed>.