The docs for MultiPattern::reparse explain that the 'append' argument should be set to true if the new query string contains the old query string as a prefix.
However, it seems to me that this does not consider the case when there is a trailing \? I had to add this extra check downstream in nucleo_picker in order to get proper search results.
It seems plausible to me that this is also a bug in helix: https://github.com/helix-editor/helix/blob/db1d84256fbae21abb3ba46943fb1abb8e211355/helix-term/src/ui/picker.rs#L539
I guess either this is actually an error (and the reparse method should be fixed) or it should be clarified in the documentation that one also needs to check for the presence of a trailing \.
Edit: Seems to be a missing check here
|
if append |
|
&& old_status != Status::Rescore |
|
&& self.cols[column] |
|
.0 |
|
.atoms |
|
.last() |
|
.map_or(true, |last| !last.negative) |
The docs for
MultiPattern::reparseexplain that the 'append' argument should be set totrueif the new query string contains the old query string as a prefix.However, it seems to me that this does not consider the case when there is a trailing
\? I had to add this extra check downstream innucleo_pickerin order to get proper search results.It seems plausible to me that this is also a bug in
helix: https://github.com/helix-editor/helix/blob/db1d84256fbae21abb3ba46943fb1abb8e211355/helix-term/src/ui/picker.rs#L539I guess either this is actually an error (and the reparse method should be fixed) or it should be clarified in the documentation that one also needs to check for the presence of a trailing
\.Edit: Seems to be a missing check here
nucleo/src/pattern.rs
Lines 53 to 59 in d17e29a