mirror of
https://github.com/vim/vim.git
synced 2025-10-05 05:34:07 -04:00
patch 8.2.4693: new regexp does not accept pattern "\%>0v"
Problem: new regexp does not accept pattern "\%>0v". Solution: Do accept digit zero.
This commit is contained in:
@@ -91,16 +91,29 @@ func Test_multi_failure()
|
||||
set re=0
|
||||
endfunc
|
||||
|
||||
func Test_column_failure()
|
||||
func Test_column_success_failure()
|
||||
new
|
||||
call setline(1, 'xbar')
|
||||
|
||||
set re=1
|
||||
%s/\%>0v./A/
|
||||
call assert_equal('Abar', getline(1))
|
||||
call assert_fails('/\%v', 'E71:')
|
||||
call assert_fails('/\%>v', 'E71:')
|
||||
call assert_fails('/\%c', 'E71:')
|
||||
call assert_fails('/\%<c', 'E71:')
|
||||
call assert_fails('/\%l', 'E71:')
|
||||
set re=2
|
||||
%s/\%>0v./B/
|
||||
call assert_equal('Bbar', getline(1))
|
||||
call assert_fails('/\%v', 'E1273:')
|
||||
call assert_fails('/\%>v', 'E1273:')
|
||||
call assert_fails('/\%c', 'E1273:')
|
||||
call assert_fails('/\%<c', 'E1273:')
|
||||
call assert_fails('/\%l', 'E1273:')
|
||||
|
||||
set re=0
|
||||
bwipe!
|
||||
endfunc
|
||||
|
||||
func Test_recursive_addstate()
|
||||
|
Reference in New Issue
Block a user