aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKenichi Handa1998-03-24 12:16:10 +0000
committerKenichi Handa1998-03-24 12:16:10 +0000
commitd8fc7ce4c112c91f112caa5695401513f3912701 (patch)
tree829b74996d32067650ccd01344b1ff1b7657d115 /src
parent2436e1803120b1833b8386543dc51212a0a3f489 (diff)
downloademacs-d8fc7ce4c112c91f112caa5695401513f3912701.tar.gz
emacs-d8fc7ce4c112c91f112caa5695401513f3912701.zip
Declarations changed.
(STRING_MULTIBYTE, STRING_BYTES, SET_STRING_BYTES): New definitions treating negative size_byte as a flag for unibyte.
Diffstat (limited to 'src')
-rw-r--r--src/lisp.h33
1 files changed, 29 insertions, 4 deletions
diff --git a/src/lisp.h b/src/lisp.h
index 14f14e9261d..30e9a8e60dc 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -545,9 +545,32 @@ struct Lisp_Buffer_Cons
545 int bufpos; 545 int bufpos;
546 }; 546 };
547 547
548#if 0
549
548/* Nonzero if STR is a multibyte string. */ 550/* Nonzero if STR is a multibyte string. */
549#define STRING_MULTIBYTE(STR) \ 551#define STRING_MULTIBYTE(STR) \
550 (XSTRING (STR)->size != XSTRING (STR)->size_byte) 552 (XSTRING (STR)->size_byte != XSTRING (STR)->size)
553
554/* Return the length in bytes of STR. */
555#define STRING_BYTES(STR) ((STR)->size_byte + 0)
556
557/* Set the length in bytes of STR. */
558#define SET_STRING_BYTES(STR, SIZE) ((STR)->size_byte = (SIZE))
559
560#else
561
562/* Nonzero if STR is a multibyte string. */
563#define STRING_MULTIBYTE(STR) \
564 (XSTRING (STR)->size_byte >= 0)
565
566/* Return the length in bytes of STR. */
567#define STRING_BYTES(STR) \
568 ((STR)->size_byte < 0 ? (STR)->size : (STR)->size_byte)
569
570/* Set the length in bytes of STR. */
571#define SET_STRING_BYTES(STR, SIZE) ((STR)->size_byte = (SIZE))
572
573#endif /* 0 */
551 574
552/* In a string or vector, the sign bit of the `size' is the gc mark bit */ 575/* In a string or vector, the sign bit of the `size' is the gc mark bit */
553 576
@@ -1731,7 +1754,7 @@ extern void modify_region P_ ((struct buffer *, int, int));
1731extern void prepare_to_modify_buffer P_ ((int, int, int *)); 1754extern void prepare_to_modify_buffer P_ ((int, int, int *));
1732extern void signal_before_change P_ ((int, int, int *)); 1755extern void signal_before_change P_ ((int, int, int *));
1733extern void signal_after_change P_ ((int, int, int)); 1756extern void signal_after_change P_ ((int, int, int));
1734extern void replace_range P_ ((int, int, Lisp_Object, int, int)); 1757extern void replace_range P_ ((int, int, Lisp_Object, int, int, int));
1735 1758
1736/* Defined in dispnew.c */ 1759/* Defined in dispnew.c */
1737EXFUN (Fding, 1); 1760EXFUN (Fding, 1);
@@ -1781,12 +1804,14 @@ EXFUN (Fmake_marker, 0);
1781EXFUN (Fmake_string, 2); 1804EXFUN (Fmake_string, 2);
1782extern Lisp_Object build_string P_ ((char *)); 1805extern Lisp_Object build_string P_ ((char *));
1783extern Lisp_Object make_string P_ ((char *, int)); 1806extern Lisp_Object make_string P_ ((char *, int));
1784extern Lisp_Object make__multibytestring P_ ((char *, int, int)); 1807extern Lisp_Object make_multibyte_string P_ ((char *, int, int));
1785extern Lisp_Object make_event_array P_ ((int, Lisp_Object *)); 1808extern Lisp_Object make_event_array P_ ((int, Lisp_Object *));
1786extern Lisp_Object make_uninit_string P_ ((int)); 1809extern Lisp_Object make_uninit_string P_ ((int));
1787extern Lisp_Object make_uninit_multibyte_string P_ ((int, int)); 1810extern Lisp_Object make_uninit_multibyte_string P_ ((int, int));
1811extern Lisp_Object make_string_from_bytes P_ ((char *, int, int));
1812extern Lisp_Object make_specified_string P_ ((char *, int, int, int));
1788EXFUN (Fpurecopy, 1); 1813EXFUN (Fpurecopy, 1);
1789extern Lisp_Object make_pure_string P_ ((char *, int, int)); 1814extern Lisp_Object make_pure_string P_ ((char *, int, int, int));
1790extern Lisp_Object pure_cons P_ ((Lisp_Object, Lisp_Object)); 1815extern Lisp_Object pure_cons P_ ((Lisp_Object, Lisp_Object));
1791extern Lisp_Object make_pure_vector P_ ((EMACS_INT)); 1816extern Lisp_Object make_pure_vector P_ ((EMACS_INT));
1792EXFUN (Fgarbage_collect, 0); 1817EXFUN (Fgarbage_collect, 0);