[XQuery] MS-XQ-LC1-056

Dear Michael,
Thank you for your comment MS-XQ-LC1-056 on XQuery Version 1.0. The Query 
working group considered this comment on 4/15/04. The working group 
observed that an implementation is allowed to infer a more specific static 
type for any expression than the static type indicated in the XQuery 
specification (this feature is called a "static typing extension"). 

The next edition of the XQuery specification will include the following 
non-normative note: "It is not recommended for a static typing extension 
to change the static type behavior of the 'treat' expression, since static 
type behavior is central to the semantics of this expression." Despite 
this note, you may wish to consider using a static typing extension when 
processing path expressions with a leading slash.

Regards,
--Don Chamberlin

----(referenced comment)----

Section 3.2 Path Expressions 
Technical 

fn:root(self::node()) treat as document-node() is not precise enough for
meaningful static typing of path expressions of the form /a/b/c. We
should use a type that is given via the static context as a new property
such as the static type of a built-in context root item (similar to the
notion of a context item).

Received on Thursday, 29 April 2004 19:54:05 UTC