aboutsummaryrefslogtreecommitdiffstats
path: root/src/buffer.c
diff options
context:
space:
mode:
authorStefan Kangas2024-07-24 00:09:49 +0200
committerStefan Kangas2024-08-22 00:51:55 +0200
commit7c8e28607b78b371598df58de96c3c3362ad6002 (patch)
treee0bb4c571d18bd6e3b3fe31fab461642636a5f03 /src/buffer.c
parent46f3452b30f39a69f610faab58c1490b34dd367d (diff)
downloademacs-7c8e28607b78b371598df58de96c3c3362ad6002.tar.gz
emacs-7c8e28607b78b371598df58de96c3c3362ad6002.zip
Prefer static_assert to verify
Although static_assert is C11-specific, and Emacs remains on C99, it has been backported to older compilers by Gnulib. Gnulib has already changed to prefer static_assert, and we can do the same. * lib-src/asset-directory-tool.c (main_2): * src/alloc.c (BLOCK_ALIGN, aligned_alloc, lisp_align_malloc) (vectorlike_nbytes, allocate_pseudovector): * src/android.c (android_globalize_reference, android_set_dashes): * src/android.h: * src/androidfont.c (androidfont_draw, androidfont_text_extents): * src/androidvfs.c: * src/bidi.c (BIDI_CACHE_MAX_ELTS_PER_SLOT, bidi_find_bracket_pairs): * src/buffer.c (init_buffer_once): * src/casefiddle.c (do_casify_multibyte_string): * src/dispnew.c (scrolling_window, scrolling): * src/editfns.c (styled_format): * src/emacs-module.c (module_extract_big_integer): * src/fileio.c (Fdo_auto_save): * src/fns.c (next_almost_prime, hash_string): * src/fringe.c (init_fringe): * src/keyboard.h (kbd_buffer_store_event_hold): * src/keymap.c: * src/lisp.h (memclear, reduce_emacs_uint_to_hash_hash, modiff_incr): * src/lread.c (skip_lazy_string): * src/pdumper.c (dump_bignum, Fdump_emacs_portable) (dump_do_dump_relocation, pdumper_load): * src/process.c (make_process, Fmake_process, connect_network_socket): * src/regex-emacs.c: * src/sort.c (tim_sort): * src/sysdep.c (init_random, SSIZE_MAX): * src/thread.c: * src/timefns.c (trillion_factor): * src/unexelf.c: * src/xterm.c (x_send_scroll_bar_event): Prefer static_assert to Gnulib verify. Remove import of verify.h, except when used for other reasons.
Diffstat (limited to 'src/buffer.c')
-rw-r--r--src/buffer.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/buffer.c b/src/buffer.c
index 78f1d977221..90c5efdfbf7 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -27,8 +27,6 @@ along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>. */
27#include <stdlib.h> 27#include <stdlib.h>
28#include <unistd.h> 28#include <unistd.h>
29 29
30#include <verify.h>
31
32#include "lisp.h" 30#include "lisp.h"
33#include "intervals.h" 31#include "intervals.h"
34#include "process.h" 32#include "process.h"
@@ -4860,7 +4858,7 @@ init_buffer_once (void)
4860 The local flag bits are in the local_var_flags slot of the buffer. */ 4858 The local flag bits are in the local_var_flags slot of the buffer. */
4861 4859
4862 /* Nothing can work if this isn't true. */ 4860 /* Nothing can work if this isn't true. */
4863 { verify (sizeof (EMACS_INT) == word_size); } 4861 { static_assert (sizeof (EMACS_INT) == word_size); }
4864 4862
4865 Vbuffer_alist = Qnil; 4863 Vbuffer_alist = Qnil;
4866 current_buffer = 0; 4864 current_buffer = 0;