[Bug 4219] why is K2-NameTest-60 an expected-error?

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

           Summary: why is K2-NameTest-60 an expected-error?
           Product: XML Query Test Suite
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XML Query Test Suite
        AssignedTo: andrew.eisenberg@us.ibm.com
        ReportedBy: per@bothner.com
         QAContact: public-qt-comments@w3.org


K2-NameTest-60 is:
declare variable $input := <e/>;
for $PI as processing-instruction() in $input//processing-instruction() return
$PI
I'm not seeing where the error is supposed to come from.
Doesn't $input//processing-instruction() evaluate to an empty sequence.
Then each item (i.e. one of them) are cast to processing-instruction().
It seems the "loop" should run zero times and produce the empty sequence.
This is without static typing, but I'm don't know why there should be an error
with static typing either.

Received on Monday, 15 January 2007 12:40:30 UTC