Thursday, March 24, 2016

Re: RFE: support POSIX standard and developing RE's



torsdag 24 mars 2016 skrev Christian Brabandt <cblists@256bit.org>:
On Do, 24 Mär 2016, L. A. Walsh wrote:

> Posix, has 2 official RE's  already, the modern REs( like in
> grep -E, (extended RE's)
> and "obsolete RE's" as found in ed, called "basic REs".
>
> Additionally for the past few years, more gnu utils (like grep -P)
> have started supporting a third type of RE's called
> PCRE [Perl Compatible RE's] that seem to be on their way
> to becoming a 3rd official type of RE.
>
> Would it be possible to add the 3 RE's (w/appropriate flags)
> to invoke those standardized expressions (not as a replacement
> for any of the existing RE's), but w/different flags.
>
> This would allow those who know the posix-compat RE's that
> are becoming more wide spread in usage, and would allow for
> easier, direct usage (cut&paste) of the alternate RE's specifically
> to make it easer to define these expressions in shell-vars and/or
> vim-macros to allow for easier portability and usability between
> vim and other posix & gnu utils?  Note in the past few years,
> the pcreRE's have also added python-specific features to the
> syntax to allow for easier porting of python features.
>
> Probably (or maybe) best of all, as all of these RE's are
> becoming more prevalent in posix, unix and linux environments,
> it would be a great benefit for people to be able to switch
> to alternate RE's based on familiarity and and the greater
> uniformity in these classes.
>
> Seems this would lower the learning curve for RE usage in
> vim where it often, idiosyncratically differs from such,
> requiring much trial and error and wasted time to get
> equivalent vim-compat-RE's that are equivalent to other
> industry standard RE's.
>
> Anyway, thought I'd mention this, since vim already has
> multiple incompatible RE's with existing standards and
> thought that providing a few "new POSIX-compat RE's" would
> only help in making vim easier to use.
>
> Thanks for your time!
> -linda

There is https://github.com/vim/vim/issues/99
You might want to check, if this works for you.

If I'm not mistaken that's "extended" as in /x,  a different sense from "extended" as in ERE.

i would like to have "extended as in /x" FWIW.
 

Best,
Christian
--
Mögest Du leben, solange Du willst - und wollen, solange Du lebst!

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments: