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

 


Help: OASIS Mailing Lists Help | MarkMail Help

relax-ng-comment message

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


Subject: Re: [relax-ng-comment] An RNC modularisation strategy question



On Mon, 19 Jul 2004 16:01:58 -0400
John Cowan <jcowan@reutershealth.com> wrote:

> > The resultant schema (as I understand it) is illegal because M2 is
> > included twice.
> 
> Correct.  That's because inclusion is flat (it does not introduce a name
> scope); when you include rules, you throw away the enclosing grammar pattern
> (implicit in the case of rnc format).

You might want to use nested grammars for avoding conflicts.  For example:

start = foo
foo =
  grammar {
    start = foo
    foo = element foo { empty }
  }

In this schema, we have two definitions of "foo".  But the first  and 
the second belong to different grammars and thus they do not conflict.

Cheers,

Makoto

-- 
MURATA Makoto (FAMILY Given) <EB2M-MRT@asahi-net.or.jp>




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