aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Eggert2017-04-17 07:56:08 -0700
committerPaul Eggert2017-04-17 07:56:29 -0700
commit630df0587e1069b2cd2f2536d5fb61175adac3a2 (patch)
treef8ba2266c78f2d9d6cf0c4c36ec7297cfab370ce /src
parentedc63bf94f3cd3f52fab86fe7b92a3ec6a19de40 (diff)
downloademacs-630df0587e1069b2cd2f2536d5fb61175adac3a2.tar.gz
emacs-630df0587e1069b2cd2f2536d5fb61175adac3a2.zip
* src/lisp.h (STRING_SET_CHARS): Simplify assertion.
Diffstat (limited to 'src')
-rw-r--r--src/lisp.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lisp.h b/src/lisp.h
index e0bad58f758..daf57ed906f 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -1371,8 +1371,9 @@ STRING_SET_CHARS (Lisp_Object string, ptrdiff_t newsize)
1371{ 1371{
1372 /* This function cannot change the size of data allocated for the 1372 /* This function cannot change the size of data allocated for the
1373 string when it was created. */ 1373 string when it was created. */
1374 eassert ((STRING_MULTIBYTE (string) && newsize <= SBYTES (string)) 1374 eassert (STRING_MULTIBYTE (string)
1375 || (!STRING_MULTIBYTE (string) && newsize == SCHARS (string))); 1375 ? newsize <= SBYTES (string)
1376 : newsize == SCHARS (string));
1376 XSTRING (string)->size = newsize; 1377 XSTRING (string)->size = newsize;
1377} 1378}
1378 1379