summaryrefslogtreecommitdiff
path: root/src/normal.zig
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-09-28 16:24:59 -0300
committerGabriel Schneider <[email protected]>2026-10-01 00:12:15 -0300
commit7ce5d94b5d48b68c86d015060ebcabe63e299e1a (patch)
treeddfbe4e1ac160cbd780c28751b5421ceca648d39 /src/normal.zig
parent3992e9def8692710590deacbc20bd925e0f8d64a (diff)
downloadpardes-7ce5d94b5d48b68c86d015060ebcabe63e299e1a.tar.gz
pardes-7ce5d94b5d48b68c86d015060ebcabe63e299e1a.zip
A selection holds up to 1024 ranges on the desktop, 64 on the board
The limit was 64 everywhere, which helix-golf's enumerate_and_align outgrows (%s |\d+ makes 121 ranges). It is now memory.limits.selections, per platform, and the counts that hold it are u16. The ranges stay inline in each Text, so a pane grows by about 80 KiB on the desktop (three texts and the regex prompt's snapshot); the Pane size budget in Terminal.zig moves from 128 to 160 KiB and says why. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'src/normal.zig')
-rw-r--r--src/normal.zig2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/normal.zig b/src/normal.zig
index 542c9fb3..98ba80d6 100644
--- a/src/normal.zig
+++ b/src/normal.zig
@@ -771,7 +771,7 @@ test "flat text movement and selection replay need no scratch rows" {
pane.body.sels[0] = .{ .row = 3072, .col = 0, .arow = 3072, .acol = 0 };
handleNormal(p, &pane.body, .{ .cp = 'l' });
handleNormal(p, &pane.body, .{ .cp = 'j' });
- try std.testing.expectEqual(@as(u8, 1), pane.body.nsel);
+ try std.testing.expectEqual(@as(u16, 1), pane.body.nsel);
try std.testing.expectEqual(@as(i32, 1025), pane.body.cur_row);
try std.testing.expectEqual(@as(i32, 1), pane.body.cur_col);
try std.testing.expectEqual(@as(i32, 3073), pane.body.sels[0].row);