- From: <bugzilla@wiggum.w3.org>
- Date: Mon, 02 Oct 2006 18:59:40 +0000
- To: public-qt-comments@w3.org
- CC:
http://www.w3.org/Bugs/Public/show_bug.cgi?id=3784
           Summary: fn:trace is cumbersome with static typing
           Product: XPath / XQuery / XSLT
           Version: Candidate Recommendation
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Formal Semantics
        AssignedTo: simeon@us.ibm.com
        ReportedBy: frans.englich@telia.com
         QAContact: public-qt-comments@w3.org
This is from a problem encountered in report #3782:
Since the return type for fn:trace isn't inferred from the input it is tracing,
one must in most cases insert a 'treat as' expression each time one inserts an
fn:trace call. I would find this very cumbersome. For example, this query is a
static typing error:
trace("this Input is traced", "The trace message.") eq "a string"
because the left operand to 'eq' has item()* as static type.
I suggest that a section is added for fn:trace, and that its return type is
inferred similarly to fn:reverse().
This is a large change, but the specification also has a large hole here, in my
opinion. fn:trace() is very unpractical on a static typing implementation as it
is now.
Received on Monday, 2 October 2006 18:59:48 UTC