Vim syntax file does not match \ zs

I am trying to get some performance improvements by changing this line in the fsharp syntax file (from this plugin) from:

syn match    fsharpModule     "\%(\<open\s\+\)\@<=[a-zA-Z.]\+"  

to

syn match    fsharpModule     "\%(\<open\s\+\)\zs[a-zA-Z.]\+"

since the documents in the \\ <= "construct indicate that:

For speed, it is often much better to avoid this multi. Try using "\ zs" instead of | / \ zs |.

However, this does not work, and for

no highligting,
open SomeModule  

How can it be? Performing a regular search in vim (with /) praises SomeModule for both the first and second matching patterns.

+4
source share
2 answers

Vim docs \@<= \zs , \@<=. , , ?

syn match    fsharpModule     "\<open\s\+\zs[a-zA-Z.]\+"
+2

:help syn-mult-line, \zs :

. . "\ zs" , .

, @<= - .

0

Source: https://habr.com/ru/post/1694975/


All Articles