Re: [xml] Problem with data in interleave in RELAX NG validation


This remains unfixed. I have absolutely no idea what’s going on in the interleave validation code. Daniel, could you please put together some minor documentation on how the interleave validation code works? It’s very complicated.

Thank you,


Nikolai Weibull, 2018-09-09 21:26:


Given the following input RELAX NG grammar:

<grammar xmlns="";
   <element name="a">
       <attribute name="b"/>
       <data type="string"/>

and the following input document a.xml:

<a b="1">c</a>

xmllint reports:

a.xml:1: element a: Relax-NG validity error : Element a has extra
content: text
a.xml fails to validate

Changing the interleave to a group solves the issue, so the problem is
with how interleaves are validated.

I looked at xmlRelaxNGValidateInterleave() and I sadly have no idea what’s going on. Please point me in the right direction and I’ll
gladly write a patch.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]