mirror of
https://github.com/neovim/neovim.git
synced 2024-12-26 14:11:15 -07:00
fixup: use vim_snprintf, ASCII_ISALNUM
ASCII_ISALNUM is part of vim-patch:8.1.0540
This commit is contained in:
parent
b22ca804dd
commit
842e6fb92f
@ -1949,7 +1949,7 @@ static char_u *illegal_char(char_u *errbuf, size_t errbuflen, int c)
|
|||||||
if (errbuf == NULL) {
|
if (errbuf == NULL) {
|
||||||
return (char_u *)"";
|
return (char_u *)"";
|
||||||
}
|
}
|
||||||
snprintf((char *)errbuf, errbuflen, _("E539: Illegal character <%s>"),
|
vim_snprintf((char *)errbuf, errbuflen, _("E539: Illegal character <%s>"),
|
||||||
(char *)transchar(c));
|
(char *)transchar(c));
|
||||||
return errbuf;
|
return errbuf;
|
||||||
}
|
}
|
||||||
@ -2881,7 +2881,7 @@ ambw_end:
|
|||||||
|
|
||||||
if (!ascii_isdigit(*(s - 1))) {
|
if (!ascii_isdigit(*(s - 1))) {
|
||||||
if (errbuf != NULL) {
|
if (errbuf != NULL) {
|
||||||
snprintf((char *)errbuf, errbuflen,
|
vim_snprintf((char *)errbuf, errbuflen,
|
||||||
_("E526: Missing number after <%s>"),
|
_("E526: Missing number after <%s>"),
|
||||||
transchar_byte(*(s - 1)));
|
transchar_byte(*(s - 1)));
|
||||||
errmsg = errbuf;
|
errmsg = errbuf;
|
||||||
@ -3059,7 +3059,7 @@ ambw_end:
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (errbuf != NULL) {
|
if (errbuf != NULL) {
|
||||||
snprintf((char *)errbuf, errbuflen,
|
vim_snprintf((char *)errbuf, errbuflen,
|
||||||
_("E535: Illegal character after <%c>"),
|
_("E535: Illegal character after <%c>"),
|
||||||
*--s);
|
*--s);
|
||||||
errmsg = errbuf;
|
errmsg = errbuf;
|
||||||
@ -3354,7 +3354,7 @@ ambw_end:
|
|||||||
* '.encoding'.
|
* '.encoding'.
|
||||||
*/
|
*/
|
||||||
for (p = q; *p != NUL; p++) {
|
for (p = q; *p != NUL; p++) {
|
||||||
if (!ASCII_ISALPHA(*p) && *p != '-') {
|
if (!ASCII_ISALNUM(*p) && *p != '-') {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user