aboutsummaryrefslogtreecommitdiffstats
path: root/src/window.c
diff options
context:
space:
mode:
authorPip Cet2024-07-14 10:45:50 +0000
committerPip Cet2024-07-20 15:17:50 +0000
commit6068cf00cddcd9f81a1390e7b4b8ecb02e285696 (patch)
tree6b9a1a5d484834063547115a6574f6ba209dd859 /src/window.c
parent4b1e9ffbc4a68565c55f63a56bff173641a187be (diff)
downloademacs-6068cf00cddcd9f81a1390e7b4b8ecb02e285696.tar.gz
emacs-6068cf00cddcd9f81a1390e7b4b8ecb02e285696.zip
Turn union vectorlike_header into struct vectorlike_header
This makes it feasible to add GC header members to this struct; keeping it as a union and merely turning its contents into a struct would have been misleading and required more difficult changes. * src/lisp.h (struct vectorlike_header): New type. Adjust comments. (union vectorlike_header): Remove. (PSEUDOVECTORP): (XSETPVECTYPESIZE): (struct Lisp_Vector): (PSEUDOVECTOR_TYPEP): (struct Lisp_Bool_Vector): (struct Lisp_Char_Table): (struct Lisp_Sub_Char_Table): (struct Lisp_Subr): (struct Lisp_Obarray): (struct Lisp_Weak_Hash_Table): (struct Lisp_Hash_Table): (struct Lisp_Marker): (struct Lisp_Overlay) (struct Lisp_Misc_Ptr): (struct Lisp_Sqlite): (struct Lisp_User_Ptr): (struct Lisp_Finalizer): (vectorlike_nbytes): * src/alloc.c (pseudovector_nbytes): (vectorlike_nbytes): (vectorlike_marked_p): (set_vectorlike_marked): (mark_vectorlike): * src/androidterm.h (struct scroll_bar): * src/bignum.h (struct Lisp_Bignum): * src/buffer.h (struct buffer): * src/comp.c (helper_PSEUDOVECTOR_TYPEP_XUNTAG): * src/comp.h (struct Lisp_Native_Comp_Unit): * src/emacs-module.c (struct Lisp_Module_Function): * src/emacs-module.h.in (struct module_global_reference): * src/font.h (struct font_spec, struct font_entity) (struct font): * src/frame.h (struct frame): * src/haikuterm.h (struct scroll_bar): Adjust * src/pdumper.c (_dump_object_start_pseudovector): (START_DUMP_PVEC): (finish_dump_pvec): (dump_pseudovector_lisp_fields): (dump_vectorlike_generic): (fill_pseudovec): (dump_nilled_pseudovec): * src/pgtkterm.h (struct scroll_bar): * src/process.h (struct Lisp_Process): * src/termhooks.h (struct terminal): * src/thread.h (struct thread_state): (struct Lisp_Mutex): (struct Lisp_CondVar): * src/treesit.h (struct Lisp_TS_Parser) (struct Lisp_TS_Node): (struct Lisp_TS_Query): * src/w32term.h (struct scroll_bar): * src/window.c (make_parent_window): (struct save_window_data): (struct saved_window): * src/window.h (struct window): * src/xterm.h (struct scroll_bar): * src/xwidget.h (struct xwidget): (struct xwidget_view): Replace `union vectorlike_header' by `struct vectorlike_header' throughout. * doc/lispref/internals.texi: Fix references.
Diffstat (limited to 'src/window.c')
-rw-r--r--src/window.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/window.c b/src/window.c
index 70472749e74..1f25724e348 100644
--- a/src/window.c
+++ b/src/window.c
@@ -4392,8 +4392,8 @@ make_parent_window (Lisp_Object window, bool horflag)
4392 4392
4393 o = XWINDOW (window); 4393 o = XWINDOW (window);
4394 p = allocate_window (); 4394 p = allocate_window ();
4395 memcpy ((char *) p + sizeof (union vectorlike_header), 4395 memcpy ((char *) p + sizeof (struct vectorlike_header),
4396 (char *) o + sizeof (union vectorlike_header), 4396 (char *) o + sizeof (struct vectorlike_header),
4397 word_size * VECSIZE (struct window)); 4397 word_size * VECSIZE (struct window));
4398 /* P's buffer slot may change from nil to a buffer... */ 4398 /* P's buffer slot may change from nil to a buffer... */
4399 adjust_window_count (p, 1); 4399 adjust_window_count (p, 1);
@@ -7061,7 +7061,7 @@ from the top of the window. */)
7061 7061
7062struct save_window_data 7062struct save_window_data
7063 { 7063 {
7064 union vectorlike_header header; 7064 struct vectorlike_header header;
7065 Lisp_Object selected_frame; 7065 Lisp_Object selected_frame;
7066 Lisp_Object current_window; 7066 Lisp_Object current_window;
7067 Lisp_Object f_current_buffer; 7067 Lisp_Object f_current_buffer;
@@ -7090,7 +7090,7 @@ struct save_window_data
7090/* This is saved as a Lisp_Vector. */ 7090/* This is saved as a Lisp_Vector. */
7091struct saved_window 7091struct saved_window
7092{ 7092{
7093 union vectorlike_header header; 7093 struct vectorlike_header header;
7094 7094
7095 Lisp_Object window, buffer, start, pointm, old_pointm; 7095 Lisp_Object window, buffer, start, pointm, old_pointm;
7096 Lisp_Object pixel_left, pixel_top, pixel_height, pixel_width; 7096 Lisp_Object pixel_left, pixel_top, pixel_height, pixel_width;