[Bug 3650] Editorial: error code on element(*, test:unknownType) is ambiguous -- XPST0001/XPTY0004?

http://www.w3.org/Bugs/Public/show_bug.cgi?id=3650

           Summary: Editorial: error code on element(*, test:unknownType) is
                    ambiguous -- XPST0001/XPTY0004?
           Product: XPath / XQuery / XSLT
           Version: Candidate Recommendation
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Keywords: editorial
          Severity: normal
          Priority: P2
         Component: XQuery
        AssignedTo: chamberl@almaden.ibm.com
        ReportedBy: frans.englich@telia.com
         QAContact: public-qt-comments@w3.org


See this report on the test suite:

http://www.w3.org/Bugs/Public/show_bug.cgi?id=3576

There's a wide agreement that the spec is unclear here, and it would be great
to have this fixed while it's possible.

This was also discussed by the task force in July, see(member only):
http://lists.w3.org/Archives/Member/member-query-test/2006Jul/0051.html

I disagree with my own comment in the member-query-test link that the spec
should raise XPST0051, because XPST0051 is for unknown schema types or types
that are not atomic(and the latter doesn't apply to this case).

I think issuing XTPY0004 is less sensible since it's not a type error. Either
XPST0001(unfortunate, since it's very generic) or a new code for unknown schema
types in element(). Adding a new code for that would be by the same thinking to
why XPST0051 exists.

2.5.4.4 Schema Element Test explicitly mentions what to do when "the
SchemaElementTest is not found in the in-scope element declarations". It could
be sensible to do the same in 2.5.4.3 Element Test.


Frans

Received on Monday, 4 September 2006 14:07:50 UTC