Saxon 8.6 still implements the rules for order of
prolog declarations from the XQuery February 2005
draft. These rules required "setters" to come before
any other declarations in the prolog.
Source code fixed. Note that the new ordering rules
allow the base URI to be declared after the schema and
module imports which use it: its scope is the entire
query module, not only the declarations that follow it.