That behavior is controlled by the ;
flag of 'cpoptions'. Execute
:verbose set cpo?
to see how yours are set.
This is a vi
-compatibility issue. If your Vim
is configured to be vi
-compatible, the ;
will be included in 'cpoptions' and you will get the behavior you observe. See
:help 'cpoptions' :help cpo-; :help 'compatible'
The solution to your problem depends on how you got Vim
into this vi-compatible state. One usually has to go to extra effort to do that, such as starting Vim
as "vim -u NONE", with -C
or with no .vimrc file in your home directory.
Edit:
This was a problem that was fixed in Vim 7.3.235 with the addition of the ;
flag to 'cpoptions'. In earlier versions, Vim
always behaves as described in dotancohen's question.