BaseXdb / basex

BaseX Main Repository.
http://basex.org
BSD 3-Clause "New" or "Revised" License
661 stars 267 forks source link

XQuery: Simplify `descendant-or-self` steps #2223

Closed ChristianGruen closed 1 year ago

ChristianGruen commented 1 year ago

Subsequent descendant-or-self steps can be merged if the second node test matches the first, or is more specific, and if no positional predicates are used:

descendant-or-self::node() / descendant-or-self::*
→ descendant-or-self::*