From 4cb692bec2d5d35cb21ed80e866d5cfb5961c91c Mon Sep 17 00:00:00 2001 From: Ingo Karkat Date: Thu, 25 Feb 2016 00:00:00 +0100 Subject: [PATCH] file creation --- autoload/ingo/compat/regexp.vim | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 autoload/ingo/compat/regexp.vim diff --git a/autoload/ingo/compat/regexp.vim b/autoload/ingo/compat/regexp.vim new file mode 100644 index 0000000..b66585f --- /dev/null +++ b/autoload/ingo/compat/regexp.vim @@ -0,0 +1,29 @@ +" ingo/compat/regexp.vim: Functions for regular expression compatibility. +" +" DEPENDENCIES: +" +" Copyright: (C) 2015 Ingo Karkat +" The VIM LICENSE applies to this script; see ':help copyright'. +" +" Maintainer: Ingo Karkat +" +" REVISION DATE REMARKS +" 1.024.001 20-Feb-2015 file creation + +if exists('+regexpengine') " {{{2 + " XXX: The new NFA-based regexp engine has a problem with non-greedy \s\{-} + " match together with the branches where only one is anchored; cp. + " http://article.gmane.org/gmane.editors.vim.devel/43712 + " XXX: The new NFA-based regexp engine has a problem with the /\@<= pattern + " in combination with a back reference \1; cp. + " http://article.gmane.org/gmane.editors.vim.devel/46596 + function! ingo#compat#regexp#GetOldEnginePrefix() + return '\%#=1' + endfunction +else + function! ingo#compat#regexp#GetOldEnginePrefix() + return '' + endfunction +endif + +" vim: set ts=8 sts=4 sw=4 noexpandtab ff=unix fdm=syntax :