diff options
| author | Paul Eggert | 2011-06-15 11:57:45 -0700 |
|---|---|---|
| committer | Paul Eggert | 2011-06-15 11:57:45 -0700 |
| commit | a2a0186171731765ee67d24a29fb80f54cd874f0 (patch) | |
| tree | 7ca9924f10b11d9ed599cfcdf01102e5d6b4235f /src | |
| parent | dfc926249a7d14f037a01acba7a69339661e5107 (diff) | |
| download | emacs-a2a0186171731765ee67d24a29fb80f54cd874f0.tar.gz emacs-a2a0186171731765ee67d24a29fb80f54cd874f0.zip | |
* character.h, charset.h: Use verify_expr, not verify_true.
Diffstat (limited to 'src')
| -rw-r--r-- | src/character.h | 2 | ||||
| -rw-r--r-- | src/charset.h | 47 |
2 files changed, 25 insertions, 24 deletions
diff --git a/src/character.h b/src/character.h index a447ad40ac3..9a45e7f0033 100644 --- a/src/character.h +++ b/src/character.h | |||
| @@ -175,7 +175,7 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 175 | (p)[1] = (0x80 | (((c) >> 6) & 0x3F)), \ | 175 | (p)[1] = (0x80 | (((c) >> 6) & 0x3F)), \ |
| 176 | (p)[2] = (0x80 | ((c) & 0x3F)), \ | 176 | (p)[2] = (0x80 | ((c) & 0x3F)), \ |
| 177 | 3) \ | 177 | 3) \ |
| 178 | : (char_string (c, p) + !verify_true (sizeof (c) <= sizeof (unsigned)))) | 178 | : verify_expr (sizeof (c) <= sizeof (unsigned), char_string (c, p))) |
| 179 | 179 | ||
| 180 | /* Store multibyte form of byte B in P. The caller should allocate at | 180 | /* Store multibyte form of byte B in P. The caller should allocate at |
| 181 | least MAX_MULTIBYTE_LENGTH bytes area at P in advance. Returns the | 181 | least MAX_MULTIBYTE_LENGTH bytes area at P in advance. Returns the |
diff --git a/src/charset.h b/src/charset.h index 24f0fc46dec..c2a52a38e7e 100644 --- a/src/charset.h +++ b/src/charset.h | |||
| @@ -426,29 +426,30 @@ extern Lisp_Object charset_work; | |||
| 426 | /* Return a code point of CHAR in CHARSET. | 426 | /* Return a code point of CHAR in CHARSET. |
| 427 | Try some optimization before calling encode_char. */ | 427 | Try some optimization before calling encode_char. */ |
| 428 | 428 | ||
| 429 | #define ENCODE_CHAR(charset, c) \ | 429 | #define ENCODE_CHAR(charset, c) \ |
| 430 | ((ASCII_CHAR_P (c) && (charset)->ascii_compatible_p) \ | 430 | (verify_expr \ |
| 431 | ? (c) \ | 431 | (sizeof (c) <= sizeof (int), \ |
| 432 | : (!verify_true (sizeof (c) <= sizeof (int)) \ | 432 | (ASCII_CHAR_P (c) && (charset)->ascii_compatible_p \ |
| 433 | || (charset)->unified_p \ | 433 | ? (c) \ |
| 434 | || (charset)->method == CHARSET_METHOD_SUBSET \ | 434 | : ((charset)->unified_p \ |
| 435 | || (charset)->method == CHARSET_METHOD_SUPERSET) \ | 435 | || (charset)->method == CHARSET_METHOD_SUBSET \ |
| 436 | ? encode_char ((charset), (c)) \ | 436 | || (charset)->method == CHARSET_METHOD_SUPERSET) \ |
| 437 | : ((c) < (charset)->min_char || (c) > (charset)->max_char) \ | 437 | ? encode_char (charset, c) \ |
| 438 | ? (charset)->invalid_code \ | 438 | : (c) < (charset)->min_char || (c) > (charset)->max_char \ |
| 439 | : (charset)->method == CHARSET_METHOD_OFFSET \ | 439 | ? (charset)->invalid_code \ |
| 440 | ? ((charset)->code_linear_p \ | 440 | : (charset)->method == CHARSET_METHOD_OFFSET \ |
| 441 | ? (c) - (charset)->code_offset + (charset)->min_code \ | 441 | ? ((charset)->code_linear_p \ |
| 442 | : encode_char ((charset), (c))) \ | 442 | ? (c) - (charset)->code_offset + (charset)->min_code \ |
| 443 | : (charset)->method == CHARSET_METHOD_MAP \ | 443 | : encode_char (charset, c)) \ |
| 444 | ? (((charset)->compact_codes_p \ | 444 | : (charset)->method == CHARSET_METHOD_MAP \ |
| 445 | && CHAR_TABLE_P (CHARSET_ENCODER (charset))) \ | 445 | ? (((charset)->compact_codes_p \ |
| 446 | ? (charset_work = CHAR_TABLE_REF (CHARSET_ENCODER (charset), (c)), \ | 446 | && CHAR_TABLE_P (CHARSET_ENCODER (charset))) \ |
| 447 | (NILP (charset_work) \ | 447 | ? (charset_work = CHAR_TABLE_REF (CHARSET_ENCODER (charset), c), \ |
| 448 | ? (charset)->invalid_code \ | 448 | (NILP (charset_work) \ |
| 449 | : XFASTINT (charset_work))) \ | 449 | ? (charset)->invalid_code \ |
| 450 | : encode_char ((charset), (c))) \ | 450 | : XFASTINT (charset_work))) \ |
| 451 | : encode_char ((charset), (c))) | 451 | : encode_char (charset, c)) \ |
| 452 | : encode_char (charset, c)))) | ||
| 452 | 453 | ||
| 453 | 454 | ||
| 454 | /* Set to 1 when a charset map is loaded to warn that a buffer text | 455 | /* Set to 1 when a charset map is loaded to warn that a buffer text |