W3C home > Mailing lists > Public > public-qt-comments@w3.org > November 2003

[XQuery] What dynamic error does treat expression raise?

From: Priscilla Walmsley <priscilla@walmsley.com>
Date: Fri, 21 Nov 2003 10:21:05 -0500
To: <public-qt-comments@w3.org>
Message-Id: <20031121152115.7C8A213B66@dr-nick.w3.org>

The description of the treat expression in the XQuery language draft says:

"During expression evaluation: If expr1 matches type1, using the
SequenceType Matching rules in 2.4 Types, the treat expression returns the
value of expr1; otherwise, it raises a dynamic error.[err:XP0006] "

Then later it says:

"The static type of $myaddress may be element(*, Address), a less specific
type than element(*, USAddress). However, at run-time, the value of
$myaddress must match the type element(*, USAddress) using SequenceType
Matching rules; otherwise a dynamic error is raised.[err:XP0050]"

These seem like the same situation with 2 different error messages (XP0006
and XP0050).

Does the draft contradict itself, or am I misreading?

Received on Friday, 21 November 2003 10:21:16 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:45:15 UTC