summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/ex_docmd.c5
-rw-r--r--src/testdir/Make_amiga.mak3
-rw-r--r--src/testdir/Make_dos.mak2
-rw-r--r--src/testdir/Make_ming.mak2
-rw-r--r--src/testdir/Make_os2.mak2
-rw-r--r--src/testdir/Make_vms.mms4
-rw-r--r--src/testdir/Makefile2
-rw-r--r--src/testdir/test103.in37
-rw-r--r--src/testdir/test103.ok2
-rw-r--r--src/version.c2
10 files changed, 54 insertions, 7 deletions
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index 1c700d473..ff5a6df9a 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -8570,6 +8570,11 @@ ex_operators(eap)
beginline(BL_SOL | BL_FIX);
}
+#if defined(FEAT_VISUAL)
+ if (VIsual_active)
+ end_visual_mode();
+#endif
+
switch (eap->cmdidx)
{
case CMD_delete:
diff --git a/src/testdir/Make_amiga.mak b/src/testdir/Make_amiga.mak
index c1d4e9d21..0fd1e8689 100644
--- a/src/testdir/Make_amiga.mak
+++ b/src/testdir/Make_amiga.mak
@@ -34,7 +34,7 @@ SCRIPTS = test1.out test3.out test4.out test5.out test6.out \
test81.out test82.out test83.out test84.out test88.out \
test89.out test90.out test91.out test92.out test93.out \
test94.out test95.out test96.out test97.out test98.out \
- test99.out test100.out test101.out test102.out
+ test99.out test100.out test101.out test102.out test103.out
.SUFFIXES: .in .out
@@ -153,3 +153,4 @@ test99.out: test99.in
test100.out: test100.in
test101.out: test101.in
test102.out: test102.in
+test103.out: test103.in
diff --git a/src/testdir/Make_dos.mak b/src/testdir/Make_dos.mak
index 40e040419..05e142247 100644
--- a/src/testdir/Make_dos.mak
+++ b/src/testdir/Make_dos.mak
@@ -33,7 +33,7 @@ SCRIPTS = test3.out test4.out test5.out test6.out test7.out \
test84.out test85.out test86.out test87.out test88.out \
test89.out test90.out test91.out test92.out test93.out \
test94.out test95.out test96.out test98.out test99.out \
- test100.out test101.out test102.out
+ test100.out test101.out test102.out test103.out
SCRIPTS32 = test50.out test70.out
diff --git a/src/testdir/Make_ming.mak b/src/testdir/Make_ming.mak
index 16944fe0e..da6d5e8dc 100644
--- a/src/testdir/Make_ming.mak
+++ b/src/testdir/Make_ming.mak
@@ -53,7 +53,7 @@ SCRIPTS = test3.out test4.out test5.out test6.out test7.out \
test84.out test85.out test86.out test87.out test88.out \
test89.out test90.out test91.out test92.out test93.out \
test94.out test95.out test96.out test98.out test99.out \
- test100out test101.out test102.out
+ test100out test101.out test102.out test103.out
SCRIPTS32 = test50.out test70.out
diff --git a/src/testdir/Make_os2.mak b/src/testdir/Make_os2.mak
index 38b566292..7af826d36 100644
--- a/src/testdir/Make_os2.mak
+++ b/src/testdir/Make_os2.mak
@@ -35,7 +35,7 @@ SCRIPTS = test1.out test3.out test4.out test5.out test6.out \
test81.out test82.out test83.out test84.out test88.out \
test89.out test90.out test91.out test92.out test93.out \
test94.out test95.out test96.out test98.out test99.out \
- test100.out test101.out test102.out
+ test100.out test101.out test102.out test103.out
.SUFFIXES: .in .out
diff --git a/src/testdir/Make_vms.mms b/src/testdir/Make_vms.mms
index 359f4cb24..370406145 100644
--- a/src/testdir/Make_vms.mms
+++ b/src/testdir/Make_vms.mms
@@ -4,7 +4,7 @@
# Authors: Zoltan Arpadffy, <arpadffy@polarhome.com>
# Sandor Kopanyi, <sandor.kopanyi@mailbox.hu>
#
-# Last change: 2013 Nov 12
+# Last change: 2013 Nov 21
#
# This has been tested on VMS 6.2 to 8.3 on DEC Alpha, VAX and IA64.
# Edit the lines in the Configuration section below to select.
@@ -79,7 +79,7 @@ SCRIPT = test1.out test2.out test3.out test4.out test5.out \
test82.out test83.out test84.out test88.out test89.out \
test90.out test91.out test92.out test93.out test94.out \
test95.out test96.out test97.out test98.out test99.out \
- test100.out test101.out test102.out
+ test100.out test101.out test102.out test103.out
# Known problems:
# Test 30: a problem around mac format - unknown reason
diff --git a/src/testdir/Makefile b/src/testdir/Makefile
index afff50979..bae4f44ff 100644
--- a/src/testdir/Makefile
+++ b/src/testdir/Makefile
@@ -30,7 +30,7 @@ SCRIPTS = test1.out test2.out test3.out test4.out test5.out test6.out \
test84.out test85.out test86.out test87.out test88.out \
test89.out test90.out test91.out test92.out test93.out \
test94.out test95.out test96.out test97.out test98.out \
- test99.out test100.out test101.out test102.out
+ test99.out test100.out test101.out test102.out test103.out
SCRIPTS_GUI = test16.out
diff --git a/src/testdir/test103.in b/src/testdir/test103.in
new file mode 100644
index 000000000..7c7591e3b
--- /dev/null
+++ b/src/testdir/test103.in
@@ -0,0 +1,37 @@
+Test for visual mode not being reset causing E315 error.
+STARTTEST
+:so small.vim
+:enew
+:let g:msg="Everything's fine."
+:function! TriggerTheProblem()
+: " At this point there is no visual selection because :call reset it.
+: " Let's restore the selection:
+: normal gv
+: '<,'>del _
+: try
+: exe "normal \<Esc>"
+: catch /^Vim\%((\a\+)\)\=:E315/
+: echom 'Snap! E315 error!'
+: let g:msg='Snap! E315 error!'
+: endtry
+:endfunction
+:enew
+:setl buftype=nofile
+:call append(line('$'), 'Delete this line.')
+:"
+:"
+:" NOTE: this has to be done by a call to a function because executing :del the
+:" ex-way will require the colon operator which resets the visual mode thus
+:" preventing the problem:
+:"
+GV:call TriggerTheProblem()
+:%del _
+:call append(line('$'), g:msg)
+:w! test.out
+:brewind
+ENDTEST
+
+STARTTEST
+:qa!
+ENDTEST
+
diff --git a/src/testdir/test103.ok b/src/testdir/test103.ok
new file mode 100644
index 000000000..9ea6dd6ee
--- /dev/null
+++ b/src/testdir/test103.ok
@@ -0,0 +1,2 @@
+
+Everything's fine.
diff --git a/src/version.c b/src/version.c
index 739b63e63..505e227f9 100644
--- a/src/version.c
+++ b/src/version.c
@@ -739,6 +739,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 98,
+/**/
97,
/**/
96,