Re: [basex-talk] Bug in evaluating conditionals? Not short-circuiting?

2015-03-23 Thread Leonard Wörteler
Hi Marc, Am 21.03.2015 um 15:12 schrieb Marc van Grootel: I think I found a bug in 8.0.3 (and earlier) declare function local:shortcircuit($a) { if ($a castable as xs:double and xs:double($a) gt 0) then $a else () }; local:shortcircuit('foo') = [FORG0001] Cannot cast to

[basex-talk] Bug in evaluating conditionals? Not short-circuiting?

2015-03-21 Thread Marc van Grootel
Hi, I think I found a bug in 8.0.3 (and earlier) declare function local:shortcircuit($a) { if ($a castable as xs:double and xs:double($a) gt 0) then $a else () }; local:shortcircuit('foo') = [FORG0001] Cannot cast to xs:double: foo. In http://www.w3.org/TR/xpath/#booleans