1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 10:30:25 -08:00

Better Lisp_String comments

* src/lisp.h (struct Lisp_String): Comments improved.
* src/pdumper.c (dump_string): Update hash (comment change only).
This commit is contained in:
Mattias Engdegård 2022-10-08 16:24:40 +02:00
parent 71b3a37569
commit 9af63d2e8b
2 changed files with 10 additions and 5 deletions

View file

@ -1575,10 +1575,15 @@ struct Lisp_String
{
struct
{
ptrdiff_t size; /* MSB is used as the markbit. */
ptrdiff_t size_byte; /* Set to -1 for unibyte strings,
-2 for data in rodata,
-3 for immovable unibyte strings. */
/* Number of characters in string; MSB is used as the mark bit. */
ptrdiff_t size;
/* If nonnegative, number of bytes in the string (which is multibyte).
If negative, the string is unibyte:
-1 for data normally allocated
-2 for data in rodata (C string constants)
-3 for data that must be immovable (used for bytecode) */
ptrdiff_t size_byte;
INTERVAL intervals; /* Text properties in this string. */
unsigned char *data;
} s;

View file

@ -2067,7 +2067,7 @@ dump_interval_tree (struct dump_context *ctx,
static dump_off
dump_string (struct dump_context *ctx, const struct Lisp_String *string)
{
#if CHECK_STRUCTS && !defined (HASH_Lisp_String_C2CAF90352)
#if CHECK_STRUCTS && !defined (HASH_Lisp_String_03B2DF1C8E)
# error "Lisp_String changed. See CHECK_STRUCTS comment in config.h."
#endif
/* If we have text properties, write them _after_ the string so that