Merge pull request #6514 from jamessan/gcc-7-fixes

Fix GCC 7 issues
This commit is contained in:
James McCoy
2017-05-13 07:51:01 -04:00
committed by GitHub
15 changed files with 70 additions and 12 deletions

View File

@@ -275,4 +275,16 @@ describe('character classes in regexp', function()
diff(sixlines(string.sub(punct1, 1)..digits..punct2..upper..punct3..
lower..punct4..ctrl2..iso_text))
end)
it('does not convert character class ranges to an incorrect class', function()
source([[
1 s/\%#=0[0-z]//g
2 s/\%#=1[0-z]//g
3 s/\%#=2[0-z]//g
4 s/\%#=0[^0-z]//g
5 s/\%#=1[^0-z]//g
6 s/\%#=2[^0-z]//g
]])
diff(string.rep(ctrl1..punct1..punct4..ctrl2..iso_text..'\n', 3)
..string.rep(digits..punct2..upper..punct3..lower..'\n', 3))
end)
end)