aboutsummaryrefslogtreecommitdiffstats
path: root/src/coding.h
diff options
context:
space:
mode:
authorKenichi Handa1997-07-25 07:46:51 +0000
committerKenichi Handa1997-07-25 07:46:51 +0000
commit4dad0cbaf539f74948282a00546a001947b5c600 (patch)
tree68cbe4864db18ec3591b1a4e311093b45775a13f /src/coding.h
parent71a4b3e854d09ed68b568b2dd8d9166d238ce4f1 (diff)
downloademacs-4dad0cbaf539f74948282a00546a001947b5c600.tar.gz
emacs-4dad0cbaf539f74948282a00546a001947b5c600.zip
(CODING_REQUIRE_TEXT_CONVERSION,
CODING_REQUIRE_EOL_CONVERSION, CODING_REQUIRE_CONVERSION): Deleted. (CODING_REQUIRE_NO_CONVERSION): New macro. (CODING_MAY_REQUIRE_NO_CONVERSION): New macro.
Diffstat (limited to 'src/coding.h')
-rw-r--r--src/coding.h29
1 files changed, 13 insertions, 16 deletions
diff --git a/src/coding.h b/src/coding.h
index 43d10e403f6..46002ad6255 100644
--- a/src/coding.h
+++ b/src/coding.h
@@ -309,22 +309,19 @@ struct coding_system
309 int carryover_size; 309 int carryover_size;
310}; 310};
311 311
312/* Return 1 if the coding-system CODING requires conversion of 312/* Return 1 if coding system CODING never requires any code conversion. */
313 representation of a visible character (text). */ 313#define CODING_REQUIRE_NO_CONVERSION(coding) \
314#define CODING_REQUIRE_TEXT_CONVERSION(coding) \ 314 (((coding)->type == coding_type_no_conversion \
315 ((coding)->type != coding_type_no_conversion \ 315 || (coding)->type == coding_type_emacs_mule) \
316 && (coding)->type != coding_type_emacs_mule) 316 && (coding)->eol_type == CODING_EOL_LF)
317 317
318/* Return 1 if the coding-system CODING requires conversion of the 318/* Return 1 if coding system CODING may not require code conversion. */
319 format of end-of-line. */ 319#define CODING_MAY_REQUIRE_NO_CONVERSION(coding) \
320#define CODING_REQUIRE_EOL_CONVERSION(coding) \ 320 (((coding)->type == coding_type_no_conversion \
321 ((coding)->eol_type != CODING_EOL_UNDECIDED \ 321 || (coding)->type == coding_type_emacs_mule \
322 && (coding)->eol_type != CODING_EOL_LF) 322 || (coding)->type == coding_type_undecided) \
323 323 && ((coding)->eol_type == CODING_EOL_LF \
324/* Return 1 if the coding-system CODING requires some conversion. */ 324 || (coding)->eol_type == CODING_EOL_UNDECIDED))
325#define CODING_REQUIRE_CONVERSION(coding) \
326 (CODING_REQUIRE_TEXT_CONVERSION (coding) \
327 || CODING_REQUIRE_EOL_CONVERSION (coding))
328 325
329/* Index for each coding category in `coding_category_table' */ 326/* Index for each coding category in `coding_category_table' */
330#define CODING_CATEGORY_IDX_EMACS_MULE 0 327#define CODING_CATEGORY_IDX_EMACS_MULE 0