Repository navigation
diffr: index the plugin cursor - #1011
Merged
Merged
Conversation
sidkmenon
added this pull request to stack #1012
October 8, 2026 05:23
sidkmenon
force-pushed
the
sm/diffr-leaf-pair
branch
from
October 8, 2026 05:30
21c280b to
e547ef9
Compare
sidkmenon
removed this pull request from stack #1012
October 8, 2026 05:30
sidkmenon
changed the base branch from
codex/reapply-diffr-after-release
to
sm/diffr-leaf-pair-wire
October 8, 2026 05:30
sidkmenon
added this pull request to stack #1015
October 8, 2026 05:31
thesiti92
approved these changes
Oct 8, 2026
sidkmenon
force-pushed
the
sm/diffr-leaf-pair
branch
from
October 8, 2026 15:55
e547ef9 to
2064e64
Compare
`has_changes`, `is_one_sided` and change coverage asked whether a leaf is paired by collecting every alignment id on the other side, once per call. `paired_leaf` searched the other side for the matching leaf. They now read the leaf's `pair`. Test fixtures name pairs from their alignment ids. AI-assisted: developed with Claude Code. Agent-Session: fb96350b-c19e-48f0-b364-31e9ad2b72f4 Agent-Session: 01a1196d-bad4-7f61-bafc-f63d12217676 Agent-Session: 7d7ac281-cc4b-4437-9e1e-3872651e8bcf Agent-Session: a7af3b88-3bb7-48a2-ae20-7626a83628a1 Agent-Session: 01a11aca-5007-7b80-ad35-c0a0f746a05d Agent-Session: 01a11c34-48e4-7ec1-bb72-2c496acb90dc Agent-Session: 01a11c3d-70b4-7df1-be1a-f0e12840fadf
Every lookup by id searched both trees. The cursor now keeps each region's side, parent and path from its side's root, so a lookup is a probe and a descent. `cut` and `join` rewrite the entries of the regions they move. The sides become private so nothing else can move a region; the plugin host takes them back with `into_sides`. No behavior change. AI-assisted: developed with Claude Code. Agent-Session: fb96350b-c19e-48f0-b364-31e9ad2b72f4 Agent-Session: 01a1196d-bad4-7f61-bafc-f63d12217676 Agent-Session: 7d7ac281-cc4b-4437-9e1e-3872651e8bcf Agent-Session: a7af3b88-3bb7-48a2-ae20-7626a83628a1 Agent-Session: 01a11aca-5007-7b80-ad35-c0a0f746a05d Agent-Session: 01a11c34-48e4-7ec1-bb72-2c496acb90dc Agent-Session: 01a11c3d-70b4-7df1-be1a-f0e12840fadf
`linked_regions`, `set_collapsed` and `link` walked both trees to find the regions in a fold state. The cursor now keeps the regions of each fold state, and `cut`, `join` and `link` update it. AI-assisted: developed with Claude Code. Agent-Session: fb96350b-c19e-48f0-b364-31e9ad2b72f4 Agent-Session: 01a1196d-bad4-7f61-bafc-f63d12217676 Agent-Session: 7d7ac281-cc4b-4437-9e1e-3872651e8bcf Agent-Session: a7af3b88-3bb7-48a2-ae20-7626a83628a1 Agent-Session: 01a11aca-5007-7b80-ad35-c0a0f746a05d Agent-Session: 01a11c34-48e4-7ec1-bb72-2c496acb90dc Agent-Session: 01a11c3d-70b4-7df1-be1a-f0e12840fadf
sidkmenon
force-pushed
the
sm/diffr-leaf-pair
branch
from
October 8, 2026 16:16
2064e64 to
b8c2c93
Compare
milanb17
added a commit
that referenced
this pull request
Oct 9, 2026
Consume the cursor with into_sides after shaping, matching the native host in PR #1011. AI-assisted with Codex. Agent-Session: 01a1197a-7e1b-7742-a9bd-04ed4353bed1 Agent-Session: 01a11e9f-d478-7a50-b799-c97cc8a58020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The plugin cursor searched both trees on most calls. Three commits:
pair, from diffr: give each leaf the id of its partner on the other side #1014) instead of rebuilding the other side's alignment ids per call.cutandjoinkeep it current. No behavior change.linked_regions,set_collapsedandlink.cargo bench --bench engine(#1013), before → after:shape/pr998/contextengine/pr998/defaultengine/pr998/no_contextTests: diffr-core cursor, present and protocol units; plugin tests; context goldens for rust, go, typescript and tsx. The full
cargo testsuite was not run.