[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] trunk r117467: * lisp.h (toplevel): Add compile-time asser
From: |
Dmitry Antipov |
Subject: |
[Emacs-diffs] trunk r117467: * lisp.h (toplevel): Add compile-time assert to verify suitable member layout |
Date: |
Wed, 02 Jul 2014 15:23:16 +0000 |
User-agent: |
Bazaar (2.6b2) |
------------------------------------------------------------
revno: 117467
revision-id: address@hidden
parent: address@hidden
committer: Dmitry Antipov <address@hidden>
branch nick: trunk
timestamp: Wed 2014-07-02 19:22:49 +0400
message:
* lisp.h (toplevel): Add compile-time assert to verify suitable member layout
in Lisp_Sub_Char_Table.
modified:
src/ChangeLog changelog-20091113204419-o5vbwnq5f7feedwu-1438
src/lisp.h lisp.h-20091113204419-o5vbwnq5f7feedwu-253
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2014-07-02 14:00:41 +0000
+++ b/src/ChangeLog 2014-07-02 15:22:49 +0000
@@ -6,6 +6,8 @@
(enum char_table_specials): Rename from CHAR_TABLE_STANDARD_SLOTS.
Add SUB_CHAR_TABLE_OFFSET member.
(make_uninit_sub_char_table): New function.
+ (toplevel): Add compile-time assert to verify suitable member layout
+ in Lisp_Sub_Char_Table.
* alloc.c (mark_char_table): Add extra argument to denote char table
subtype. Adjust to match new layout of sub char-table.
(mark_object): Always mark sub char-tables with mark_char_table.
=== modified file 'src/lisp.h'
--- a/src/lisp.h 2014-07-02 03:26:19 +0000
+++ b/src/lisp.h 2014-07-02 15:22:49 +0000
@@ -1561,7 +1561,11 @@
- CHAR_TABLE_STANDARD_SLOTS);
}
-
+/* Make sure that sub char-table contents slot
+ is aligned on a multiple of Lisp_Objects. */
+verify ((offsetof (struct Lisp_Sub_Char_Table, contents)
+ - offsetof (struct Lisp_Sub_Char_Table, depth)) % word_size == 0);
+
/***********************************************************************
Symbols
***********************************************************************/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] trunk r117467: * lisp.h (toplevel): Add compile-time assert to verify suitable member layout,
Dmitry Antipov <=