Re:Text Showdown: Gap Buffers vs. Ropes
by celeritascelery on Tuesday October 10, 2023 @01:11AM
(#37828714)
It’s not quite that simple, but folks are working on it.
https://github.com/rust-lang/regex/issues/425#issuecomment-1...
https://github.com/helix-editor/helix/pull/211#issuecomment-...
Re:Text Showdown: Gap Buffers vs. Ropes
by alpaca128 on Tuesday October 10, 2023 @05:39AM
(#37830091)
Maybe not in the general case for arbitrary abstracted datastructures, but I have done it in a basic test to see if it's viable for my use-case, which is why I made that claim at all.
Re:Text Showdown: Gap Buffers vs. Ropes
by burntsushi on Tuesday October 10, 2023 @10:46AM
(#37832789)
Note that the lazy DFA and its lower level APIs exists now and threads this needle.
Unless you don't mind implementing a couple dozen lines yourself. The regex_automata crate allows you to directly access the DFA, so with iteration through the rope and a bit of state tracking you can already do this, just not as convenient (yet) as a single method call.