From: Kenichi Handa Date: Thu, 23 Oct 1997 12:01:50 +0000 (+0000) Subject: (CHAR_VALID_P): Renamed from VALID_CHAR_P, new X-Git-Tag: emacs-20.3~2922 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=15979e9ebcdeb0e622057faa81c935f98c67a80d;p=emacs.git (CHAR_VALID_P): Renamed from VALID_CHAR_P, new argument GENERICP. Call char_valid_p for a non-ASCII character. --- diff --git a/src/charset.h b/src/charset.h index 9923336ddec..1358a5be4dd 100644 --- a/src/charset.h +++ b/src/charset.h @@ -462,15 +462,12 @@ extern int width_by_char_head[256]; ? (c1) \ : MAKE_NON_ASCII_CHAR ((charset), (c1) & 0x7F, (c2) & 0x7F)) -/* 1 if C is in the range of possible character code Emacs can have. */ -#define VALID_CHAR_P(c) \ - ((c) >= 0 \ - && (SINGLE_BYTE_CHAR_P (c) \ - || ((c) < MIN_CHAR_COMPOSITION \ - ? ((c) & CHAR_FIELD1_MASK \ - ? (CHAR_FIELD2 (c) >= 32 && CHAR_FIELD3 (c) >= 32) \ - : (CHAR_FIELD2 (c) >= 16 && CHAR_FIELD3 (c) >= 32)) \ - : (c) < MIN_CHAR_COMPOSITION + n_cmpchars))) +/* If GENERICP is nonzero, return nonzero iff C is a valid normal or + generic character. If GENERICP is zero, return nonzero iff C is a + valid normal character. */ +#define CHAR_VALID_P(c, genericp) \ + ((c) >= 0 \ + && (SINGLE_BYTE_CHAR_P (c) || char_valid_p (c, genericp))) /* The charset of non-ASCII character C is stored in CHARSET, and the position-codes of C are stored in C1 and C2.