1 To: vim_dev@googlegroups.com
4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
11 Problem: On a 64 bit system "syn sync fromstart" is very slow. (Bjorn
13 Solution: Store the state when starting to parse from the first line.
17 *** ../mercurial/vim73/src/syntax.c 2011-05-25 17:56:23.000000000 +0200
18 --- src/syntax.c 2011-06-19 04:47:08.000000000 +0200
21 if (INVALID_STATE(¤t_state))
23 syn_sync(wp, lnum, last_valid);
24 ! first_stored = current_lnum + syn_block->b_syn_sync_minlines;
27 first_stored = current_lnum;
29 if (INVALID_STATE(¤t_state))
31 syn_sync(wp, lnum, last_valid);
32 ! if (current_lnum == 1)
33 ! /* First line is always valid, no matter "minlines". */
36 ! /* Need to parse "minlines" lines before state can be considered
37 ! * valid to store. */
38 ! first_stored = current_lnum + syn_block->b_syn_sync_minlines;
41 first_stored = current_lnum;
42 *** ../vim-7.3.225/src/version.c 2011-06-19 04:31:54.000000000 +0200
43 --- src/version.c 2011-06-19 04:49:53.000000000 +0200
47 { /* Add new patch number below this line */
53 Press any key to continue, press any other key to quit.
55 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
56 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
57 \\\ an exciting new programming language -- http://www.Zimbu.org ///
58 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///