On 05/08/10 01:36, Bee wrote:
[^\s]\+ not same as [^\t ]\+
vim 7.2.446 MacOS terminal
[^\s]\+ matches everything except "\" and "s"
Might make sense if "\s" was not special (?magic)
I would think it should match all non-whitespace
I tried the following thinking it was my .vimrc, but same result.
vim -N -i NONE -u NONE
I have not found any reference that "\s" cannot be used within [...]
similar to "\t"
Is this a bug? or feature?
-Bill
In addition to all the wise answers you already got, note that to search
for one or more non-space non-tabs non-linebreaks (in short, a WORD),
you should normally use \S\+ which, according to the note at the bottom
of the list at ":help whitespace", is faster than using a [] collection.
Similarly, to search for one or more spaces, tabs and/or linebreaks, (a
WORD separator of the kind HTML compresses to one space) you would use
\_s\+ (which is also faster than the equivalent \_[ \t]\+ ).
Best regards,
Tony.
--
Females are strictly forbidden to appear unshaven in public.
[real standing law in New Mexico, United States of America]
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php