0

I have a file with the following lines:

a=117
a=100
a=101

When I try searching using /a=10*, it correctly matches all of those lines.

But when I try searching using /a=10+, it does not match any of those lines, even though it should match the last 2 lines.

Why doesn't the + regular expression quantifier work when searching?

3

In Vim you need a backslash before the +. So the following works:

/a=10\+

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.