Commit Graph

1110 Commits

Author SHA1 Message Date
51bce52ea4 add from/toList conversion functions for testing persistent-vector.sml 2025-12-09 10:44:43 +00:00
cd8958cced implement a function to delete from persistent-vector.sml 2025-12-09 10:31:31 +00:00
69fcbfc35d add function to decrement indices in persistent-vector.sml 2025-12-09 10:07:46 +00:00
d52c350a90 formatting for persistent-vector.sml (absolutely no changes other than formatting) 2025-12-08 22:40:38 +00:00
2ba18a38b0 entirely done with first pass implementing persistent-vector.sml's 'prependJoin' helper function. 2025-12-08 22:37:13 +00:00
0c668c9f14 almost done implementing persistent-vector.sml's 'prependJoin' helper function. (BRANCH case is fully implemented, but I need to implement the LEAF case next.) 2025-12-08 22:23:01 +00:00
b6cad904f9 implement function to join when left has greater depth than right. (I need to implement a function to join when right is greater than left though. 2025-12-08 10:57:00 +00:00
3aab8698ed begin coding function to join two 'PersistentVector.t's. 2025-12-07 04:12:39 +00:00
0650b372b2 complete first pass of implementing 'splitRight' in persistent-vector.sml 2025-12-07 03:43:15 +00:00
3318501c00 in persistent-vector.sml's 'splitRight' function, make sure we decrement the remaining size table that remains after the split. 2025-12-07 03:22:38 +00:00
470d36f82b delete insert function and helper functions in persistent-vector.sml, due to a simpler approach: for insertion, we will split the vector into left and right halves, then append the new element to the left half, then concat both halves together again. This is similar to the approach for RRB trees. 2025-12-06 02:19:42 +00:00
ca5baf8fd7 progress with ''helpInset' function in persistent-vector.sml: BRANCH case is fully implemented, and need to impelement LEAF case next 2025-12-06 00:28:29 +00:00
db459d59ad progress reimplementing 'helpInsert' in persistent-vector.sml by adding a helper function for creating a vector when the current node is split 2025-12-05 18:53:02 +00:00
1f5cf157b1 progress reimplementing 'helpInsert' so that it is aware of rope-like metadata 2025-12-05 13:32:16 +00:00
343951948c begin reimplementing persistent-vector.sml's 'helpInsert' function so that it uses rope-like metadata 2025-12-05 10:11:06 +00:00
237d9f8a38 formatting for fcore/persistent-vector.sml 2025-12-03 11:06:08 +00:00
0625c33bec modify next/prev match functions to index using rope-like metadata 2025-12-03 11:00:02 +00:00
22aa18699e modify PersistentVector.nextMatch and relevant functions so that they index using the roles of rope-like metadata 2025-12-03 10:18:44 +00:00
bd3d5ef54c pull in changes from brolib-sml to receive new version of LineGap module containing bug fixes. These bug fixes special case going to line 0 or convert line 0 to idx 0, as previous implementations did not work correctly when provided with 0 as a value. 2025-12-03 00:37:27 +00:00
e7a08e27af fix compiler error (was using curent module's name to refer to a function from current module, which is not supported in SML) 2025-12-03 00:34:30 +00:00
7a8961af9c special case LineGap.goToLine, when the line requested to go to is 0. When this happens, we call 'LineGap.goToStart'. 2025-12-03 00:31:57 +00:00
4925bcd370 for LineGap.lineNumberToIdx function, add a branch at the start checking if we are trying to get the idx corresponding to line number 0. This is needed by the current implementation because the 'lineNumberToIdxLeft' function uses (findLine - 1) in the implementation, and (0 - 1) is an invalid line idx as it is below 0. 2025-12-02 23:49:29 +00:00
137cbfee19 fix bug when saving search from NORMAL_SEARCH_MODE. Previously, when pressing <Enter> to save the search, the tempSearchList (which searches against a subset of the buffer's text instead of all of it, to ensure we do not spend too much time was spent while the user was entering the regex/search string) was being saved instead of the newly built searchList (which executes the DFA against all of the text) 2025-12-02 17:55:25 +00:00
fde27123cf begin adjusting persistent-vector.sml so that it uses rope-like metadata, meaning relative index offsets to support efficient arbitrary insertion/deletion 2025-12-02 08:53:23 +00:00
6fba536f6f when insert forces persistent-vector.sml to split, distribute half of nodes to left side and half of nodes to right side. (We avoid repeated tiny vectors this way, which reduces tree height and maintains balance.) 2025-12-01 14:24:41 +00:00
328a4e76f1 done implementing 'helpInsert' (both leaf and branch caases)for persistent-vector.sml 2025-12-01 13:51:12 +00:00
17fdeff9ae almost done implementing 'helpInsert' for LEAF case of persistent-vector.sml 2025-12-01 13:40:53 +00:00
94a3d8eeb4 done implementing 'helpInsert' for BRANCH case (need to imlement the LEAF case next) 2025-12-01 13:09:46 +00:00
780aefae34 begin implementing function to insert into PersistentVector.t 2025-12-01 12:24:45 +00:00
8fdc710db4 begin parsing right-arrow in normal mode, for normal mode commands 2025-11-25 21:37:09 +00:00
d60e8bf7aa add todo note to implement yh/yj/yk/yl motions (yank according to h/j/k/l motions) 2025-11-23 23:44:24 +00:00
eefe5221ba begin parsing left arrow in normal mode 2025-11-23 23:19:31 +00:00
4126c833d1 add functions to replace start and end leaves in rrb_rope.sml 2025-10-23 06:41:21 +01:00
6f406069a8 add function to split right of vector 2025-10-23 06:33:48 +01:00
f9f602bb9f add function to split left side of tree, given an index 2025-10-23 06:23:30 +01:00
7c9d47346e begin implementing clojure-style vector first as a rope implementation of radix-relaxed balanced trees 2025-10-23 05:11:57 +01:00
995ee01470 begin adding tests for 'diw' (delete-inside-word) motion 2025-10-19 21:55:55 +01:00
308c28c709 done adding tests for 'dT<char>' motion 2025-10-19 14:52:04 +01:00
766945ac88 remove some dead code 2025-10-19 14:32:57 +01:00
7d1272180b remove 'Cursor.tillPrevChr', replacing usages of that function with 'Cursor.toPrevChr' 2025-10-19 14:30:26 +01:00
60ec24453f reimplement 'yt<char>' motion to use 'Cursor.toNextChr' 2025-10-18 19:55:53 +01:00
9f53c5549a rename 'Cursor.toNextChrNew' function to 'Cursor.toNextChr', and update usages to change the name as well. 2025-10-18 15:17:26 +01:00
e07f21d6f4 remove usages of 'Cursor.toNextChr' and delete it 2025-10-18 15:14:41 +01:00
ee96419901 repace usage of 'Cursor.toNextChr' with 'Cursor.toNextChrNew' ins make-normal-delete.sml 2025-10-18 15:07:14 +01:00
d7adae374f reimplement 'dt' motion 2025-10-18 14:59:37 +01:00
bc44c7bcd0 add another test for 'df<char>' motion, checking that we leave a newline behind if the whole buffer is deleted 2025-10-18 14:29:20 +01:00
5d00da2cbb reimplement 'df' motion as per previous commits, and add a new test for 'df' motion to check that cursor does not land on a 'newline following a non-newline' position, after deleting using 'df<char>' 2025-10-18 14:24:16 +01:00
239aaacfc5 reimplement 't' movement motion the same way that 'f' movement motion was reimplemented in previous commit 2025-10-18 14:05:25 +01:00
e44eae6d46 reimplement 'f' move motion more efficiently, not leaving the LineGap.t data structure while iterating to next count 2025-10-18 14:01:06 +01:00
597b5beb3d add tests (some of Which currently fail) for 'dF<char>' motion 2025-10-18 13:37:42 +01:00