Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge $collation into $options parameter of fn:deep-equal() #1167

Open
michaelhkay opened this issue Apr 22, 2024 · 1 comment
Open

Merge $collation into $options parameter of fn:deep-equal() #1167

michaelhkay opened this issue Apr 22, 2024 · 1 comment
Labels
Enhancement A change or improvement to an existing feature XQFO An issue related to Functions and Operators

Comments

@michaelhkay
Copy link
Contributor

To avoid the ugly third parameter to deep-equal which will almost always be set to (), merge $collation into the $options parameter, whose type becomes (map(*) | xs:string)? for backwards compatibility.

The same idea is being applied to unparsed-text and can probably be done elsewhere.

@ChristianGruen ChristianGruen added XQFO An issue related to Functions and Operators Enhancement A change or improvement to an existing feature labels Apr 22, 2024
@ChristianGruen
Copy link
Contributor

👍

For fn:sort, we could possibly allow…

sort($data, (
  { 'key': fn { name }, 'collation': 'lang=fr' },
  { 'key': fn { city }, 'order': 'descending' }
))

If a map is supplied as 2nd argument, a 3rd (legacy) argument would need to be rejected.

Related: #1085

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement A change or improvement to an existing feature XQFO An issue related to Functions and Operators
Projects
None yet
Development

No branches or pull requests

2 participants