aboutsummaryrefslogtreecommitdiffstats
path: root/pkg/index/index_test.go
diff options
context:
space:
mode:
authorJP Appel <jeanpierre.appel01@gmail.com>2025-06-10 16:33:03 -0400
committerJP Appel <jeanpierre.appel01@gmail.com>2025-06-10 16:33:03 -0400
commiteef03d11d91afe3f722830b966ad5494d8d85e19 (patch)
treef487c4cd0b99070e5a67c821a1aabc90e806d9b6 /pkg/index/index_test.go
parentc3d812262761c140316f5501783f8302191e5053 (diff)
Add method to merge subtrees in a clause tree
Add `Flatten` method to `query.Clause` which merges a parent clause with its children. The merge occurs if clauses have the same operator. The merge transforms the tree similar to the examples below: (+ (+ (+ (+ a b) c) d) e) -> (+ a b c d e) (+ (+ a b) c (* d e)) -> (+ a b c (* d e))
Diffstat (limited to 'pkg/index/index_test.go')
0 files changed, 0 insertions, 0 deletions