Skip to content

Processor drops patterns from imported RELAX NG with the same name as a generated pattern #623

@dmj

Description

@dmj

Take for example the tei_odds.odd customization: https://tei-c.org/Vault/P5/current/xml/tei/custom/odd/tei_odds.odd.

It imports the RELAX NG grammar via moduleRef/@url:

<moduleRef url="https://www.tei-c.org/release/xml/tei/Exemplars/relaxng.rng"/>

The grammar defines a pattern with the name "param" (Line 205).

  <define name="param">
    <element name="param">
      <attribute name="name">
        <data type="NCName"/>
      </attribute>
      <data type="string"/>
    </element>
  </define>

If you transpile the tei_odds.odd to RELAX NG you get a grammar that also defines a pattern with the name "param", but for the TEI param element:

<define name="param">
      <element name="param">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">provides a parameter for a model behaviour by supplying its name and an XPath expression identifying the location of its content. [22.5.4.5. Behaviours and their parameters]</a:documentation>
         <empty/>
         <ref name="att.global.attributes"/>
         <attribute name="name">
         ...

The pattern from the RELAX NG with the name "param" is gone while all other patterns from the grammar are still present.

Metadata

Metadata

Assignees

Labels

status: needsDiscussionCouncil has not yet been able to agree on how to proceed.type: bugA bug report.

Type

No type
No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions