summaryrefslogtreecommitdiff
path: root/src/memory.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/memory.zig')
-rw-r--r--src/memory.zig4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/memory.zig b/src/memory.zig
index 7b6ee2c0..abfd40f6 100644
--- a/src/memory.zig
+++ b/src/memory.zig
@@ -17,6 +17,9 @@ pub const limits = struct {
pub const wrap_rows = if (board) 128 else 256;
pub const undo_max = if (board) 16 else 256;
pub const message_log = if (board) 16 else 128;
+ /// ranges one selection holds; helix has no limit, and a `%s` over a
+ /// file's words wants hundreds
+ pub const selections = if (board) 64 else 1024;
/// /log's ring, which records whether or not anyone reads it.
pub const log_bytes: usize = if (board) 4 * KiB else 64 * KiB;
pub const max_tag_tail: usize = if (board) 512 else 4096;
@@ -187,6 +190,7 @@ test "memory limits preserve desktop capacities" {
try std.testing.expectEqual(256, limits.wrap_rows);
try std.testing.expectEqual(256, limits.undo_max);
try std.testing.expectEqual(128, limits.message_log);
+ try std.testing.expectEqual(1024, limits.selections);
try std.testing.expectEqual(@as(usize, 4096), limits.max_tag_tail);
try std.testing.expectEqual(@as(usize, 4095), limits.host_path_cap);
try std.testing.expectEqual(config.embed_sources, limits.embedded_sources);