Bug#400771: Syntax highlighting causes Vim to hang

Bram Moolenaar Bram at moolenaar.net
Mon Jun 18 20:50:24 UTC 2007


James -

> Bram,
> 
> Given the attached Makefile.am, it is possible to get Vim to hang in an
> infinite loop while doing syntax highlighting.  This seems to be
> dependant on the height of the Vim window as I am able to reproduce it
> with 'lines' set to certain values but not others.
> 
> vim -u NONE Makefile.am
> :set lines=3D24
> :set ruler  (not necessary but it is useful to see what line the cursor
>              is on when Vim starts to hang)
> :setf automake
> :syn on
> j   (press and hold until you reach the end of the file, using G will
>      not work)
> k   (press and hold until Vim hangs or you reach the top of the file.
>      If Vim did not hang, repeat the previous and current steps.  This
>      reliably hangs for me when the cursor gets to line 38)
> 
> You are able to press <C-c> to break out of the loop that Vim is in but
> moving around via j/k is more likely to cause the hang now.

I can reproduce it.  Looks like a hang or very slow pattern matching in
the syntax syncing stuff.  One more for the todo list.

- Bram

-- 
       Bravely bold Sir Robin, rode forth from Camelot,
       He was not afraid to die, Oh Brave Sir Robin,
       He was not at all afraid to be killed in nasty ways
       Brave, brave, brave, brave Sir Robin.
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

 /// Bram Moolenaar -- Bram at Moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\        download, build and distribute -- http://www.A-A-P.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///




More information about the pkg-vim-maintainers mailing list