← Prev in month ← Prev in thread
Next in thread → Next in month →

Redefinition of named <start>

From
David Rosenborg <>
Date
2001-06-27T14:05:41+00:00
ID
002001c0ff12$9e5070e0$6500000a@KENNY
Thread
Redefinition of named <start>
Hi,

 

I'm trying to figure out what the correct behaviour 
of the following should be:

 

A.rng:

 

<grammar>

  <start name="start">

    <element 
name="x">

      
<optional>

        <ref 
name="start"/>

      
</optional>

    </element>

  </start>

</grammar>

 

B.rng

 

<grammar>

  <include href="A.rng">

    <define 
name="start">

      <element 
name="y">

        
<optional>

          <ref 
name="start"/>

        
</optional>

      
</element>

    </define>

  </include>

</grammar>

 

Jing rejects the instance 
<y><y/></y> given the B.rng grammar.

The tutorial states that a named start is 
just a shorthand for (given the example above)

 

<start>

  <ref name="start"/>

</start>

<define 
name="start">...</define>

 

So I expected the <y><y/></y> 
instance to be valid, but Jing wants <x><y/></x>.

 

What is the correct behavior?

 

Cheers,

 

</David>

 

David Rosenborg

Pantor Engineering AB
← Prev in month ← Prev in thread
Next in thread → Next in month →