exist
exist copied to clipboard
No static typing
Description:
fixes #2445
Reference:
- exist-db never stated that it would implement / support the static typing feature
- with XQuery 4.0 static typing feature is removed entirely
- [ ] drop static typing feature from XQST runner (see https://github.com/eXist-db/exist-xqts-runner/blob/21abfbb8cca2ad6eb300a0af030f3a23f16ab625/src/main/scala/org/exist/xqts/runner/XQTSRunner.scala#L92)
- [ ] open issue to prominently state that exist-db does not support the static typing feature
Type of tests:
XQSuite tests
I applied commits from an older PR that targeted develop-6.x.x and it took 3 attempts to get it to compile.
I will look to add one or two tests from the original issue.
I would expect for one to many additional XQTS test cases to now pass.
There seems to be zero tests that assert error XPST0005 to be raised. ;)
I am wondering.... should this code change be 'protected' to it would not be effective for 'query 3.1' (and older) based queries?
The error with code XPST0005 should only be raised when a XQuery processor implements the static typing feature.
exist-db never claimed to support this optional feature, which is why I believe we do not need to guard against it. I do agree that one can argue it is a breaking change which is why I ported my original PR #3653 to target exist 7 instead.
With this PR applied XPath queries will behave much more like in any other Xquery processor (namely baseX and Saxon).
An interesting idea of how to fix the issue... But it must be recognised that this small change is very significant!
Before it is merged two things need to be checked carefully in great detail:
- No regression in the XQTS results
- No performance regression (looking at the code change, I suspect this PR will result in a regression in its current form)