Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions luqum/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,14 @@ class OpenRangeTransformer(visitor.TreeTransformer):
Open ranges in OR and unknown clauses are not adjusted. Use :cls:`UnknownOperationResolver`
to make sure that unknown operations are resolved first.

Ranges with none of the bounds set are left unadjusted. Additionally, the ranges must be
direct siblings of the same parent. Ranges such as ``[foo TO *]^2 AND [* TO bar]^2`` are
therefore not merged (though ``([foo TO *] AND [* TO bar])^2`` would).
Ranges with none of the bounds set are left unadjusted.

Additionally, the ranges must be direct siblings of the same parent.
Ranges such as ``[foo TO *]^2 AND [* TO bar]^2``
are therefore not merged (though ``([foo TO *] AND [* TO bar])^2`` would).

Also not that it does not check ranges bound ordering
so that you might end-up with incoherent ranges like [* TO 3] AND [4 TO *] -> [4 TO 3]
"""

WILDCARD_WORD = Word("*")
Expand Down