[Bug 4441] [XQuery] 2.3.4 Optimization rules unclear?

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





------- Comment #7 from hrennau@yahoo.de  2007-04-02 17:13 -------
(In reply to comment #2)

But there remain two problems, if I am not mistaken:

a) the order of evaluation is not guaranteed - the processor may choose to
execute 'do-something' first and only afterwards 'prepareEnvironment'

b) if $env must not leave any trace in the query result (as was the case in the
scenario we started at), there are two possibilities:

- if the code is based on the assumption that $env evaluates to the empty
sequence, we have constraints on the function (empty result, but static return
type T? or T*) - therefore the pattern is not generic

- otherwise I must still get rid of $env, and therefore I am still not on dry
land - the riddance offers the processor a chance of optimizing the function
call away

Received on Monday, 2 April 2007 17:13:56 UTC