Mercurial > vim
comparison src/normal.c @ 268:8e3c690f1f3c
updated for version 7.0072
author | vimboss |
---|---|
date | Wed, 18 May 2005 22:10:28 +0000 |
parents | f146656fb903 |
children | fb70e333c94e |
comparison
equal
deleted
inserted
replaced
267:ca33bc409682 | 268:8e3c690f1f3c |
---|---|
3927 int t; | 3927 int t; |
3928 int save_p_ws; | 3928 int save_p_ws; |
3929 int save_p_scs; | 3929 int save_p_scs; |
3930 char_u *ptr; | 3930 char_u *ptr; |
3931 | 3931 |
3932 if ((len = find_ident_under_cursor(&ptr, FIND_IDENT)) == 0 || | 3932 if ((len = find_ident_under_cursor(&ptr, FIND_IDENT)) == 0 |
3933 (pat = alloc(len + 5)) == NULL) | 3933 || (pat = alloc(len + 7)) == NULL) |
3934 { | 3934 { |
3935 clearopbeep(oap); | 3935 clearopbeep(oap); |
3936 return; | 3936 return; |
3937 } | 3937 } |
3938 sprintf((char *)pat, vim_iswordp(ptr) ? "\\<%.*s\\>" : "%.*s", len, ptr); | 3938 |
3939 /* Put "\V" before the pattern to avoid that the special meaning of "." | |
3940 * and "~" causes trouble. */ | |
3941 sprintf((char *)pat, vim_iswordp(ptr) ? "\\V\\<%.*s\\>" : "\\V%.*s", | |
3942 len, ptr); | |
3939 old_pos = curwin->w_cursor; | 3943 old_pos = curwin->w_cursor; |
3940 save_p_ws = p_ws; | 3944 save_p_ws = p_ws; |
3941 save_p_scs = p_scs; | 3945 save_p_scs = p_scs; |
3942 p_ws = FALSE; /* don't wrap around end of file now */ | 3946 p_ws = FALSE; /* don't wrap around end of file now */ |
3943 p_scs = FALSE; /* don't switch ignorecase off now */ | 3947 p_scs = FALSE; /* don't switch ignorecase off now */ |