annotate src/testdir/test101.in @ 6948:50dfc96920a8

Added tag v7-4-792 for changeset 1efa7c2b9368
author Bram Moolenaar <bram@vim.org>
date Tue, 21 Jul 2015 15:48:27 +0200
parents 01c668384bcc
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5458
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
1 Test for v:hlsearch vim: set ft=vim :
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
2
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
3 STARTTEST
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
4 :" Last abc: Q
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
5 :so small.vim
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
6 :new
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
7 :call setline(1, repeat(['aaa'], 10))
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
8 :set hlsearch nolazyredraw
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
9 :let r=[]
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
10 :command -nargs=0 -bar AddR :call add(r, [screenattr(1, 1), v:hlsearch])
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
11 /aaa
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
12 :AddR
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
13 :nohlsearch
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
14 :AddR
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
15 :let v:hlsearch=1
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
16 :AddR
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
17 :let v:hlsearch=0
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
18 :AddR
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
19 :set hlsearch
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
20 :AddR
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
21 :let v:hlsearch=0
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
22 :AddR
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
23 n:AddR
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
24 :let v:hlsearch=0
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
25 :AddR
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
26 /
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
27 :AddR
6413
01c668384bcc updated for version 7.4.537
Bram Moolenaar <bram@vim.org>
parents: 5458
diff changeset
28 :set nohls
01c668384bcc updated for version 7.4.537
Bram Moolenaar <bram@vim.org>
parents: 5458
diff changeset
29 /
01c668384bcc updated for version 7.4.537
Bram Moolenaar <bram@vim.org>
parents: 5458
diff changeset
30 :AddR
5458
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
31 :let r1=r[0][0]
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
32 :" I guess it is not guaranteed that screenattr outputs always the same character
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
33 :call map(r, 'v:val[1].":".(v:val[0]==r1?"highlighted":"not highlighted")')
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
34 :try
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
35 : let v:hlsearch=[]
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
36 :catch
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
37 : call add(r, matchstr(v:exception,'^Vim(let):E\d\+:'))
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
38 :endtry
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
39 :bwipeout!
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
40 :$put=r
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
41 :call garbagecollect(1)
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
42 :"
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
43 :/^start:/,$wq! test.out
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
44 :" vim: et ts=4 isk-=\:
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
45 :call getchar()
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
46 ENDTEST
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
47
6ae816249627 updated for version 7.4.079
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
48 start: