OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-comment message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Found a mistake in the Schematron of DocBook 5.1b7


In some cases, the logic of s:assert is inverted:

---
<s:pattern>
  <s:title>XLink locator placement</s:title>
  <s:rule context="*[@xlink:type='locator']">
<s:assert test="not(parent::*[@xlink:type='extended'])">An XLink locator type element must occur as the direct child of an XLink extended type element.</s:assert>
  </s:rule>
</s:pattern>

<s:pattern>
  <s:title>XLink resource placement</s:title>
  <s:rule context="*[@xlink:type='resource']">
<s:assert test="not(parent::*[@xlink:type='extended'])">An XLink resource type element must occur as the direct child of an XLink extended type element.</s:assert>
  </s:rule>
</s:pattern>

<s:pattern>
  <s:title>XLink title placement</s:title>
  <s:rule context="*[@xlink:type='title']">
<s:assert test="not(parent::*[@xlink:type='extended']) and not(parent::*[@xlink:type='locator']) and not(parent::*[@xlink:type='arc'])">An XLink title type element must occur as the direct child of an XLink extended, locator, or arc type element.</s:assert>
  </s:rule>
</s:pattern>
---

should read:

---
<s:pattern>
  <s:title>XLink locator placement</s:title>
  <s:rule context="*[@xlink:type='locator']">
<s:assert test="parent::*[@xlink:type='extended']">An XLink locator type element must occur as the direct child of an XLink extended type element.</s:assert>
  </s:rule>
</s:pattern>

<s:pattern>
  <s:title>XLink resource placement</s:title>
  <s:rule context="*[@xlink:type='resource']">
<s:assert test="parent::*[@xlink:type='extended']">An XLink resource type element must occur as the direct child of an XLink extended type element.</s:assert>
  </s:rule>
</s:pattern>

<s:pattern>
  <s:title>XLink title placement</s:title>
  <s:rule context="*[@xlink:type='title']">
<s:assert test="parent::*[@xlink:type='extended'] or parent::*[@xlink:type='locator'] or parent::*[@xlink:type='arc']">An XLink title type element must occur as the direct child of an XLink extended, locator, or arc type element.</s:assert>
  </s:rule>
</s:pattern>
---

The above mistake is found in both docbook.sch and assembly.sch (didn't look at the other .sch files).

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]