- From: Daniel Veillard <veillard@redhat.com>
- Date: Mon, 20 Mar 2006 11:06:38 -0500
- To: Elliotte Harold <elharo@metalab.unc.edu>
- Cc: public-xml-id@w3.org, Wolfgang Hoschek <whoschek@lbl.gov>, xom-interest <xom-interest@lists.ibiblio.org>
On Mon, Mar 20, 2006 at 10:45:58AM -0500, Elliotte Harold wrote: > > Wolfgang Hoschek pointed out an inconsistency in how XOM tests xml:id > values which I've now traced to an apparent discrepancy between the > current xml:id test suite and the xml:id spec, and I was hoping somebody > could explain this to me. > > Section 4 of xml:id states: > > An xml:id processor must assure that the following constraints hold for > all xml:id attributes: > > * The normalized value of the attribute is an NCName according to > the Namespaces in XML Recommendation which has the same version as the > document in which this attribute occurs (NCName for XML 1.0, or NCName > for XML 1.1). > > However the very first test case normal_001 uses a non-NCName and > apparently expects this test to pass: > > <doc> > <para xml:id=" te st ">MATCH</para> > </doc> xmllint raises an error about it: paphio:~/XML -> xmllint --noout id_err3.xml id_err3.xml:2: validity error : xml:id : attribute value te st is not an NCName <para xml:id=" te st ">MATCH</para> ^ paphio:~/XML -> > However a probably older version of the catalog I find laying around on > my hard drive lists this as an error condition. i.e. the value of the > operation attribute of the scenario element is error, not standard. that's my recollection too. > Can anyone shed some light on this? What is supposed to happen here? Is > the test suite wrong or the spec? Or are they consistent in a way I'm > not seeing? I tend to think that's an error. Moreover libxml2 does not register an ID in that case, XPath can't find one. Daniel -- Daniel Veillard | Red Hat http://redhat.com/ veillard@redhat.com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/ http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
Received on Monday, 20 March 2006 16:06:58 UTC