othree / eregex.vim

Perl/Ruby style regexp notation for Vim
http://www.vim.org/scripts/script.php?script_id=3282
214 stars 18 forks source link

Can't reverse-search with a zero-width negative lookahead assertion #21

Open chocolateboy opened 8 years ago

chocolateboy commented 8 years ago

eregex.vim: e1692107da0b678001127e9cdcacf028f5c246a8 vim: 7.4 OS: Linux

I have a logfile that looks something like this:

host: example.com
action: frobnicate foo
status: OK

host: example.com
action: bamboozle baz
status: network error

I want to search for entries that don't have "status: OK" i.e. the errors. This works fine when searching from the top down e.g.

:M/status: (?!OK)

But it's not working for me at all with a reverse search. I navigate to the bottom of the document, enter:

:M?status: (?!OK)

And get the following error:

E486: Pattern not found: status: (
huyz commented 1 year ago

I get the same error when with a zero-width positive lookahead assertion. Works in forward search, but not backward search.

Silentdoer commented 1 year ago

hi, this has been fixed?