every $s in tokenize("",",") satisfies matches($s,"^(?:[^cde-[ag]]+)$")
is indeed true. This is because tokenize("", ",") returns the empty sequence, and as a result the whole "every" expression returns true (without the need to evaluate the fn:match()).
The correct reuslt for the query
every $s in tokenize("",",") satisfies matches( $s,"^(? :[^cde- [ag]]+) $")
is indeed true. This is because tokenize("", ",") returns the empty sequence, and as a result the whole "every" expression returns true (without the need to evaluate the fn:match()).