Hello,
The query
xquery:eval( 'contains(.,"&")', map{'':<foo><&></foo>} )
results in: [XPST0003] Invalid entity: '&")...'.
I can get the expected result if I double-escape the entity:
'contains(.,"&amp;")'
or wrap in a call to serialize:
serialize('contains(.,"&")')
However, both
xquery:eval( 'contains(.,"<")', map{'':<foo><&></foo>} )
and
xquery:eval( 'contains(.,">")', map{'':<foo><&></foo>} )
return true, as expected.
Is this a bug, or am I missing something?
Thanks, Andrew