From: Ken Raeburn Date: Mon, 15 Jul 2002 02:13:38 +0000 (+0000) Subject: * lisp.h (STRING_SET_CHARS): New macro. X-Git-Tag: ttn-vms-21-2-B4~14136 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=7412b6fdd2a74fe49a4aa8fca84e4ef9afb5d548;p=emacs.git * lisp.h (STRING_SET_CHARS): New macro. (SCHARS, SBYTES): Produce rvalues. --- diff --git a/src/lisp.h b/src/lisp.h index 8c01d9c74de..ca8cd9835ee 100644 --- a/src/lisp.h +++ b/src/lisp.h @@ -543,8 +543,11 @@ extern Lisp_Object make_number (); #define SREF(string, index) XSTRING (string)->data[index] #define SDATA(string) XSTRING (string)->data -#define SCHARS(string) XSTRING (string)->size -#define SBYTES(string) STRING_BYTES (XSTRING (string)) +#define SCHARS(string) (XSTRING (string)->size + 0) +#define SBYTES(string) (STRING_BYTES (XSTRING (string)) + 0) + +#define STRING_SET_CHARS(string, newsize) \ + (XSTRING (string)->size = (newsize)) /* Basic data type for use of intervals. See the macros in intervals.h. */