|
Karsten Hopp |
a565d0 |
To: vim_dev@googlegroups.com
|
|
Karsten Hopp |
a565d0 |
Subject: Patch 7.3.1207
|
|
Karsten Hopp |
a565d0 |
Fcc: outbox
|
|
Karsten Hopp |
a565d0 |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
a565d0 |
Mime-Version: 1.0
|
|
Karsten Hopp |
a565d0 |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
a565d0 |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
a565d0 |
------------
|
|
Karsten Hopp |
a565d0 |
|
|
Karsten Hopp |
a565d0 |
Patch 7.3.1207
|
|
Karsten Hopp |
a565d0 |
Problem: New regexp engine: no match found on "#if FOO". (Lech Lorens)
|
|
Karsten Hopp |
a565d0 |
Solution: When adding a state gets skipped don't adjust the index.
|
|
Karsten Hopp |
a565d0 |
Files: src/regexp_nfa.c, src/testdir/test64.in, src/testdir/test64.ok
|
|
Karsten Hopp |
a565d0 |
|
|
Karsten Hopp |
a565d0 |
|
|
Karsten Hopp |
a565d0 |
*** ../vim-7.3.1206/src/regexp_nfa.c 2013-06-14 22:33:47.000000000 +0200
|
|
Karsten Hopp |
a565d0 |
--- src/regexp_nfa.c 2013-06-16 15:38:15.000000000 +0200
|
|
Karsten Hopp |
a565d0 |
***************
|
|
Karsten Hopp |
a565d0 |
*** 4210,4215 ****
|
|
Karsten Hopp |
a565d0 |
--- 4210,4217 ----
|
|
Karsten Hopp |
a565d0 |
|
|
Karsten Hopp |
a565d0 |
/* re-order to put the new state at the current position */
|
|
Karsten Hopp |
a565d0 |
count = l->n - tlen;
|
|
Karsten Hopp |
a565d0 |
+ if (count == 0)
|
|
Karsten Hopp |
a565d0 |
+ return; /* no state got added */
|
|
Karsten Hopp |
a565d0 |
if (count == 1)
|
|
Karsten Hopp |
a565d0 |
{
|
|
Karsten Hopp |
a565d0 |
/* overwrite the current state */
|
|
Karsten Hopp |
a565d0 |
*** ../vim-7.3.1206/src/testdir/test64.in 2013-06-15 15:09:44.000000000 +0200
|
|
Karsten Hopp |
a565d0 |
--- src/testdir/test64.in 2013-06-16 15:38:04.000000000 +0200
|
|
Karsten Hopp |
a565d0 |
***************
|
|
Karsten Hopp |
a565d0 |
*** 408,413 ****
|
|
Karsten Hopp |
a565d0 |
--- 408,415 ----
|
|
Karsten Hopp |
a565d0 |
:"""" Requiring lots of states.
|
|
Karsten Hopp |
a565d0 |
:call add(tl, [2, '[0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12}', " 12345678-1234-1234-1234-123456789012 ", "12345678-1234-1234-1234-123456789012", "1234-"])
|
|
Karsten Hopp |
a565d0 |
:"
|
|
Karsten Hopp |
a565d0 |
+ :"""" Skip adding state twice
|
|
Karsten Hopp |
a565d0 |
+ :call add(tl, [2, '^\%(\%(^\s*#\s*if\>\|#\s*if\)\)\(\%>1c.*$\)\@=', "#if FOO", "#if", ' FOO'])
|
|
Karsten Hopp |
a565d0 |
:"
|
|
Karsten Hopp |
a565d0 |
:"""" Run the tests
|
|
Karsten Hopp |
a565d0 |
:"
|
|
Karsten Hopp |
a565d0 |
*** ../vim-7.3.1206/src/testdir/test64.ok 2013-06-15 15:09:44.000000000 +0200
|
|
Karsten Hopp |
a565d0 |
--- src/testdir/test64.ok 2013-06-16 15:38:22.000000000 +0200
|
|
Karsten Hopp |
a565d0 |
***************
|
|
Karsten Hopp |
a565d0 |
*** 913,918 ****
|
|
Karsten Hopp |
a565d0 |
--- 913,921 ----
|
|
Karsten Hopp |
a565d0 |
OK 0 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12}
|
|
Karsten Hopp |
a565d0 |
OK 1 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12}
|
|
Karsten Hopp |
a565d0 |
OK 2 - [0-9a-zA-Z]\{8}-\([0-9a-zA-Z]\{4}-\)\{3}[0-9a-zA-Z]\{12}
|
|
Karsten Hopp |
a565d0 |
+ OK 0 - ^\%(\%(^\s*#\s*if\>\|#\s*if\)\)\(\%>1c.*$\)\@=
|
|
Karsten Hopp |
a565d0 |
+ OK 1 - ^\%(\%(^\s*#\s*if\>\|#\s*if\)\)\(\%>1c.*$\)\@=
|
|
Karsten Hopp |
a565d0 |
+ OK 2 - ^\%(\%(^\s*#\s*if\>\|#\s*if\)\)\(\%>1c.*$\)\@=
|
|
Karsten Hopp |
a565d0 |
multi-line tests
|
|
Karsten Hopp |
a565d0 |
OK 0 - ^.\(.\).\_..\1.
|
|
Karsten Hopp |
a565d0 |
OK 1 - ^.\(.\).\_..\1.
|
|
Karsten Hopp |
a565d0 |
*** ../vim-7.3.1206/src/version.c 2013-06-16 14:25:53.000000000 +0200
|
|
Karsten Hopp |
a565d0 |
--- src/version.c 2013-06-16 15:42:05.000000000 +0200
|
|
Karsten Hopp |
a565d0 |
***************
|
|
Karsten Hopp |
a565d0 |
*** 730,731 ****
|
|
Karsten Hopp |
a565d0 |
--- 730,733 ----
|
|
Karsten Hopp |
a565d0 |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
a565d0 |
+ /**/
|
|
Karsten Hopp |
a565d0 |
+ 1207,
|
|
Karsten Hopp |
a565d0 |
/**/
|
|
Karsten Hopp |
a565d0 |
|
|
Karsten Hopp |
a565d0 |
--
|
|
Karsten Hopp |
a565d0 |
hundred-and-one symptoms of being an internet addict:
|
|
Karsten Hopp |
a565d0 |
228. You spend Saturday night making the counter on your home page
|
|
Karsten Hopp |
a565d0 |
pass that 2000 mark.
|
|
Karsten Hopp |
a565d0 |
|
|
Karsten Hopp |
a565d0 |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
a565d0 |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
a565d0 |
\\\ an exciting new programming language -- http://www.Zimbu.org ///
|
|
Karsten Hopp |
a565d0 |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|