On 09/07/10 22:08, Bram Moolenaar wrote:
ZyX (?) wrote:
I need to test whether character is in range [\u00A0-\uD7FF] (actual
collection has more items, see printable characters definition in YAML
1.2 RFC), but this throws «Invalid range» error. After some
experiments, I found that character ranges that are wider then 0x100
also result in error:
:echo ''=~'[\uD6FE-\uD7FF]'
E16: Invalid range
0
:echo ''=~'[\uD6FF-\uD7FF]'
0
:echo ''=~'[\uD6FE-\uD7FE]'
0
Tested on latest vim 7.3. This should be either fixed or at least
mentioned in documentation.
It's a known limitation. I thought it was mentioned somewhere, can't
find it now. I'll add a comment.
It has been discussed on the list (vim_dev? vim_multibyte?) some time
ago, and IIRC a [] range in a pattern can be at most 257 codepoints
long, but I can't find it back in the help.
Best regards,
Tony.
--
"What I've done, of course, is total garbage."
-- R. Willard, Pure Math 430a
--
You received this message from the "vim_dev" 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