[Bug 1897] New: [XSLT2.0] cardinalities of unparsed-text-available function

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

           Summary: [XSLT2.0] cardinalities of unparsed-text-available
                    function
           Product: XPath / XQuery / XSLT
           Version: Last Call drafts
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XSLT 2.0
        AssignedTo: mike@saxonica.com
        ReportedBy: colin@colina.demon.co.uk
         QAContact: public-qt-comments@w3.org


Both of the arguments to this function have a cardinality of exactly one, whereas 
the corresponding arguments to unparsed-text are optional.
This means you cannot reliably pass a computed value to unparsed-text-available,
as a processor might deduce during the static analysis phase that the only
possible value is the empty sequence, and accordingly raise a type error.
Since unparsed-text would succeed if the first argument is an empty sequence,
then unparsed-text-available should return true given the same value.
For the encoding, if this is the empty sequence, then I am unclear as to what
the processor should do - it does not seem to be specified - I'm personally
treating it the same as if only one argument is present, but I think that
legalistically the current spec. requires the processor to raise XTDE1190.
In any case, unparsed-text-available should not suffer a type error.

Received on Friday, 26 August 2005 18:32:23 UTC