aboutsummaryrefslogtreecommitdiffstats
path: root/src/pdumper.c
diff options
context:
space:
mode:
authorPip Cet2025-01-18 20:55:18 +0000
committerPip Cet2025-01-18 20:55:18 +0000
commit2ecb34990a92d45ae2845244f4ccfc96ffe04829 (patch)
treeb924bc2fd058cbc93d5896821fb614e0c9294dfd /src/pdumper.c
parentaa07e94439c663f768c32a689d14506d25a7a5bc (diff)
downloademacs-scratch/no-purespace.tar.gz
emacs-scratch/no-purespace.zip
Use #$ for lambda fixups in native compilation data vectorsscratch/no-purespace
The "#$" syntax is recognized by Fread, which substitutes Vload_file_name in its place. If Vload_file_name is bound appropriately, no other value can produce an object EQ to the one produced by "#$". We use this to check the data vector for entries that we know should have been initialized: if the value is still equal to what we bound Vload_file_name to when it was read, it wasn't initialized, and we abort. * lisp/emacs-lisp/comp.el (comp--#$): New defvar. (comp--finalize-container): Use it. * src/comp.c (ABI_VERSION): Bump. (emit_static_object): Ensure 'comp--#$' prints as "#$". (load_static_obj): Ensure '#$' reads as Vcomp__hashdollar. (check_comp_unit_relocs): Adjust assertion. (syms_of_comp): Define 'comp--#$'. * src/pdumper.c (dump_do_dump_relocation): Adjust assertion.
Diffstat (limited to 'src/pdumper.c')
-rw-r--r--src/pdumper.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pdumper.c b/src/pdumper.c
index d45bbc84bba..a27df8d96d4 100644
--- a/src/pdumper.c
+++ b/src/pdumper.c
@@ -5504,7 +5504,7 @@ dump_do_dump_relocation (const uintptr_t dump_base,
5504 XSETSUBR (tem, subr); 5504 XSETSUBR (tem, subr);
5505 Lisp_Object *fixup = 5505 Lisp_Object *fixup =
5506 &(comp_u->data_relocs[XFIXNUM (lambda_data_idx)]); 5506 &(comp_u->data_relocs[XFIXNUM (lambda_data_idx)]);
5507 eassert (EQ (*fixup, Q__lambda_fixup)); 5507 eassert (EQ (*fixup, Vcomp__hashdollar));
5508 *fixup = tem; 5508 *fixup = tem;
5509 Fputhash (tem, Qt, comp_u->lambda_gc_guard_h); 5509 Fputhash (tem, Qt, comp_u->lambda_gc_guard_h);
5510 } 5510 }