On Mi, 19 Dez 2012, Christian Brabandt wrote:
> > :ExplainPattern *
> > if the pattern is in the clipboard)
> >
> > (needless to say: suggestions welcome)
>
> Very nice.
Some observations:
You already parse \v \V \m and \M
but then you should also output the meaning of those atoms
:%>l doesn't seem to work correctly:
:ExplainPattern \%>1l\&\%<6l
match below line 1
\& AND branch
match above line 6
(obviously otherway around)
:ExplainPattern: \%>'a1
\%>'a1 literal string (5 atom(s))
(wrong, its 1 after mark a (2atoms)
Possible enhancements:
- maybe show captured string, if simple atom
\1 match first captured string
- possibly highlight matching patterns, so you can see, what
:ExplainPattern <pattern> matches in the current buffer)
- :ExplainPattern: \%x31
\%x31 match character specified with hex number 0x31
(display character)
Mit freundlichen Grüßen
Christian
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php