aboutsummaryrefslogtreecommitdiff
path: root/test/functional/legacy/036_regexp_character_classes_spec.lua
diff options
context:
space:
mode:
authorMichael Ennen <mike.ennen@gmail.com>2016-07-19 23:24:42 -0700
committerJustin M. Keyes <justinkz@gmail.com>2016-08-01 03:59:04 -0400
commit6fe8c1d0513c0facefa9b80078792dba627ec7a7 (patch)
tree35ce7336e637c6193ed451ca88293b2256e9589c /test/functional/legacy/036_regexp_character_classes_spec.lua
parent23f591dba078fee16ab6e4debfcd051e799ca4f8 (diff)
downloadrneovim-6fe8c1d0513c0facefa9b80078792dba627ec7a7.tar.gz
rneovim-6fe8c1d0513c0facefa9b80078792dba627ec7a7.tar.bz2
rneovim-6fe8c1d0513c0facefa9b80078792dba627ec7a7.zip
vim-patch:7.4.1305 #5094
Problem: "\%1l^#.*" does not match on a line starting with "#". Solution: Do not clear the start-of-line flag. (Christian Brabandt) https://github.com/vim/vim/commit/7c29f387819b5817b003d2ba73e2b5cf3cb3d0dd Helped-by: jamessan Helped-by: mhinz
Diffstat (limited to 'test/functional/legacy/036_regexp_character_classes_spec.lua')
-rw-r--r--test/functional/legacy/036_regexp_character_classes_spec.lua11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/functional/legacy/036_regexp_character_classes_spec.lua b/test/functional/legacy/036_regexp_character_classes_spec.lua
index 3d5e69d1e5..9e67bb9429 100644
--- a/test/functional/legacy/036_regexp_character_classes_spec.lua
+++ b/test/functional/legacy/036_regexp_character_classes_spec.lua
@@ -268,4 +268,15 @@ describe('character classes in regexp', function()
ABCDEFGHIXYZ
ABCDEFGHIXYZ]])
end)
+ it([["\%1l^#.*" does not match on a line starting with "#". (vim-patch:7.4.1305)]], function()
+ source([[
+ 1 s/\%#=0\%1l^\t...//g
+ 2 s/\%#=1\%2l^\t...//g
+ 3 s/\%#=2\%3l^\t...//g
+ 4 s/\%#=0\%4l^\t...//g
+ 5 s/\%#=1\%5l^\t...//g
+ 6 s/\%#=2\%6l^\t...//g]])
+ diff(sixlines(string.sub(punct1, 1)..digits..punct2..upper..punct3..
+ lower..punct4..ctrl2..iso_text))
+ end)
end)