Next in thread → Next in month →

RE: Ambiguous content model in DITA 2.0

From
Jristen Dberlein
Date
2022-08-08T11:46:00+00:00
ID
Thread
RE: Ambiguous content model in DITA 2.0
I’m thinking that what we originally approved for the content model of <messagepanel> was the following sequence: Zero or more <data> elements One <typeofhazard> element One of the following: <consequence> element (zero or more), followed by <howtoavoid> element (at least one) <howtoavoid> element (at least one), followed by <consequence> element (zero or more)

Zero or more <hazardsymbol> elements My memory is a little fuzzy now, but what I remember is that we: Knew that different types of safety statements listed “consequence” and “how to avoid” in different order Wanted to help people avoid doing gymnastics in their style sheets Wanted to minimize migration pains in moving to DITA 2.0 markup Wanted to allow <hazardsymbol> in a number of places – directly within <messagepanel> and also within other elements: <typeofhazard>, <consequence>, and <howtoavoid> We approved the stage three proposa l for this on 22 October 2019.
Best, Kris Kristen James Eberlein Chair, OASIS DITA Technical Committee Owner, Eberlein Consulting LLC 
Skype: kriseberlein; voice: +1 (919) 622-1501
From:  <> On Behalf Of Robert Anderson Sent: Monday, August 1, 2022 3:30 PM
To: 
Subject: [dita] Fw: Ambiguous content model in DITA 2.0 Hi everyone, Passing along a reported issue in the grammar files for TC discussion. Thanks, Robert
From: Patrick Baker < 
> Sent: Saturday, July 30, 2022 9:58 AM
To: Robert Anderson < 
>
Subject: [External] : Ambiguous content model in DITA 2.0 Hi Robert, According to OmniMark, the following content model is ambiguous: <!ENTITY % messagepanel.content "( (%data;)*, (%typeofhazard;), ( ((%consequence;)*, (%howtoavoid;)+) ((%howtoavoid;)+, (%consequence;)*) ),(%hazardsymbol;)* )" A content model must not be ambiguous. For the declared element "messagepanel", the element "howtoavoid" is ambiguous in the content model. At line 132 of entity hazard-d-def In entity file://${ROOT_PATH}/schema/OASIS/DITA/2.0/org.oasis-open.dita.v2_0/dtd/base/hazardstatementDomain.mod Included from entity file://${ROOT_PATH}/schema/OASIS/DITA/2.0/org.oasis-open.dita.techcomm.v2_0/dtd/technicalContent/ditabase.dtd The fix would be straight forward... Just change one * to a +. It will match the same XML, but will not be ambiguous. <!ENTITY % messagepanel.content "( (%data;)*, (%typeofhazard;), ( ((%consequence;) + , (%howtoavoid;)+) ((%howtoavoid;)+, (%consequence;)*) ),(%hazardsymbol;)* )" I'd recommend a similar change in the RNG. regards, Patrick
Next in thread → Next in month →