[xquery-talk] problem with saxon PE support of XQuery 3.0 try/catch

Michael Dyck jmdyck at ibiblio.org
Thu Dec 22 15:50:01 PST 2011


James Fuller wrote:
> running XQuery 3.0 spec example
> 
> try {
>     fn:error(fn:QName('http://www.w3.org/2005/xqt-errors', 'err:FOER0000'))
> }
> catch * {
>     $err:code, $err:value, " module: ",
>     $err:module, "(", $err:line-number, ",", $err:column-number, ")"
> 
> getting an odd error
> 
>       XPST0008: Variable $err:code has not been declared

Up until a couple drafts ago, the syntax of try/catch was different, and 
the various $err:* variables were not auto-declared:
http://www.w3.org/TR/2009/WD-xquery-11-20091215/#id-try-catch

Perhaps that's the version of try/catch that the processor supports.

-Michael


More information about the talk mailing list