[Bug 3838] fn:codepoints-to-string should allow any infoset character

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

           Summary: fn:codepoints-to-string should allow any infoset
                    character
           Product: XPath / XQuery / XSLT
           Version: Candidate Recommendation
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Functions and Operators
        AssignedTo: ashok.malhotra@oracle.com
        ReportedBy: per@bothner.com
         QAContact: public-qt-comments@w3.org


The specification of 7.2.1 fn:codepoints-to-string says:

  If any of the code points in $arg is not a legal XML character, an error is
raised.

Why?  What is the rationale for this?  I thought XQuery was supposed be useful
not *only* for XML files, but more generally useful for datasets compatible
with XML inforsets, which are not always XML files.

Furthermore, there is a "Text" output method,  One might want to emit text
files which are not always XML files.

The infoset specification says about characters:
  [character code] The ISO 10646 character code (in the range 0 to #x10FFFF,  
though not every value in this range is a legal XML character code) of the  
character.

codepoints-to-string should allow all Unicode characters, possibly excepted
surrogates.  (Though allowing a pair of surrogate characters might be useful
too.)

See also 3776, relating to tests in the testsuite.

Received on Sunday, 15 October 2006 20:08:36 UTC