minor fixes involving is_byte()
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2262 35c25a1d-7b9e-4130-9fde-d3aeb78583b8master
parent
8eb9c029be
commit
9b95ca8c29
|
@ -36,7 +36,7 @@ CVS code -
|
||||||
buffered input and output, the first steps toward
|
buffered input and output, the first steps toward
|
||||||
wide/multibyte character input and output, and verbatim input
|
wide/multibyte character input and output, and verbatim input
|
||||||
of double-byte Unicode characters instead of single-byte ASCII
|
of double-byte Unicode characters instead of single-byte ASCII
|
||||||
characters. New functions is_byte_char(), get_buffer(),
|
characters. New functions is_byte(), get_buffer(),
|
||||||
get_buffer_len(), buffer_to_keys(), unget_input(),
|
get_buffer_len(), buffer_to_keys(), unget_input(),
|
||||||
get_input(), parse_kbinput(), and parse_verbatim_kbinput();
|
get_input(), parse_kbinput(), and parse_verbatim_kbinput();
|
||||||
new macro charcpy(); changes to do_char() (renamed to
|
new macro charcpy(); changes to do_char() (renamed to
|
||||||
|
|
|
@ -500,7 +500,7 @@ int regexec_safe(const regex_t *preg, const char *string, size_t nmatch,
|
||||||
int regexp_bol_or_eol(const regex_t *preg, const char *string);
|
int regexp_bol_or_eol(const regex_t *preg, const char *string);
|
||||||
#endif
|
#endif
|
||||||
int num_of_digits(int n);
|
int num_of_digits(int n);
|
||||||
bool is_byte(int c);
|
bool is_byte(unsigned int c);
|
||||||
bool parse_num(const char *str, ssize_t *val);
|
bool parse_num(const char *str, ssize_t *val);
|
||||||
size_t move_left(const char *buf, size_t pos);
|
size_t move_left(const char *buf, size_t pos);
|
||||||
size_t move_right(const char *buf, size_t pos);
|
size_t move_right(const char *buf, size_t pos);
|
||||||
|
|
|
@ -67,9 +67,9 @@ int num_of_digits(int n)
|
||||||
return i;
|
return i;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool is_byte(int c)
|
bool is_byte(unsigned int c)
|
||||||
{
|
{
|
||||||
return ((unsigned int)c == (unsigned char)c);
|
return (c == (unsigned char)c);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Read a ssize_t from str, and store it in *val (if val is not NULL).
|
/* Read a ssize_t from str, and store it in *val (if val is not NULL).
|
||||||
|
|
Loading…
Reference in New Issue