mirror of
https://github.com/martinvonz/jj.git
synced 2025-01-16 00:56:23 +00:00
951eb0b61a
This basically transforms 's1 & (f() | s2)' to 's1.iter().filter(all && f || s2)'. Still the predicate part includes "all", the filter function doesn't need to load commit data for every entry since 's1.iter().filter(all)' is tested first. To optimize "all" predicate out, maybe we can add a wrapper that returns '|_: &IndexEntry| true'. Instead of inserting AsFilter(_) node, I could add a recursive is_filter() function. That would also work so long as the height of RevsetExpression tree is limited. I chose node insertion just for ease of snapshot testing. |
||
---|---|---|
.. | ||
src | ||
tests | ||
testutils | ||
build.rs | ||
Cargo.toml |