1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-04-06 14:22:31 -07:00
emacs/doc/lispref
Philipp Stephani 48ffef5ef4 Implement finalizers for module functions (Bug#30373)
* src/module-env-28.h: Add new module environment functions to
module environment for Emacs 28.

* src/emacs-module.h.in: Document that 'emacs_finalizer' also works
for function finalizers.

* src/emacs-module.c (CHECK_MODULE_FUNCTION): New function.
(struct Lisp_Module_Function): Add finalizer data member.
(module_make_function): Initialize finalizer.
(module_get_function_finalizer)
(module_set_function_finalizer): New module environment functions.
(module_finalize_function): New function.
(initialize_environment): Initialize new environment functions.

* src/alloc.c (cleanup_vector): Call potential module function
finalizer during garbage collection.

* test/data/emacs-module/mod-test.c (signal_error): New helper
function.
(memory_full): Use it.
(finalizer): New example function finalizer.
(Fmod_test_make_function_with_finalizer)
(Fmod_test_function_finalizer_calls): New test module functions.
(emacs_module_init): Define them.

* test/src/emacs-module-tests.el (module/function-finalizer): New unit
test.

* doc/lispref/internals.texi (Module Functions): Document new
functionality.
(Module Misc): Move description of 'emacs_finalizer' type to 'Module
Functions' node, and add a reference to it.

* etc/NEWS: Mention new functionality.
2020-01-03 19:24:10 +01:00
..
abbrevs.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
anti.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
back.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
backups.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
book-spine.texi Fix single-quoting style in PDF manuals 2015-05-01 12:06:38 -07:00
buffers.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
ChangeLog.1 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
commands.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
compile.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
control.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
customize.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
debugging.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
display.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
doclicense.texi Merge from Gnulib 2017-10-01 18:31:10 -07:00
edebug.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
elisp.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
errors.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
eval.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
files.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
frames.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
functions.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
gpl.texi Merge from Gnulib 2017-10-01 18:31:10 -07:00
hash.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
help.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
hooks.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
index.texi
internals.texi Implement finalizers for module functions (Bug#30373) 2020-01-03 19:24:10 +01:00
intro.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
keymaps.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
lay-flat.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
lists.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
loading.texi Merge from origin/emacs-27 2020-01-01 01:08:16 +00:00
macros.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
Makefile.in Update copyright year to 2020 2020-01-01 00:59:52 +00:00
maps.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
markers.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
minibuf.texi Merge from origin/emacs-27 2020-01-01 01:08:16 +00:00
modes.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
nonascii.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
numbers.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
objects.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
os.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
package.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
positions.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
processes.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
README Update copyright year to 2020 2020-01-01 00:59:52 +00:00
records.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
searching.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
sequences.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
spellfile Update lispref spellfile 2019-06-04 08:34:16 -07:00
streams.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
strings.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
symbols.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
syntax.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
text.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
threads.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
tips.texi Fix copyright years by hand 2020-01-01 01:01:53 +00:00
two-volume-cross-refs.txt Update copyright year to 2020 2020-01-01 00:59:52 +00:00
two-volume.make Update copyright year to 2020 2020-01-01 00:59:52 +00:00
variables.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00
windows.texi Update copyright year to 2020 2020-01-01 00:59:52 +00:00

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

Copyright (C) 2001-2020 Free Software Foundation, Inc.  -*- outline -*-
See the end of the file for license conditions.


README for the Emacs Lisp Reference Manual.

* This directory contains the texinfo source files for the Emacs Lisp
Reference Manual.

* Report bugs in the Lisp Manual (or in Emacs) using M-x report-emacs-bug.
To ask questions, use the help-gnu-emacs mailing list.

* The Emacs Lisp Reference Manual is quite large.  It totals around
1100 pages in smallbook format; the info files total around 3.0 megabytes.

* You can format this manual for Info, for printing hardcopy using TeX,
or for HTML.

* You can buy nicely printed copies from the Free Software Foundation.
Buying a manual from the Free Software Foundation helps support our GNU
development work.  See <https://shop.fsf.org/>.
(At time of writing, this manual is out of print.)

* The master file for formatting this manual for Tex is called 'elisp.texi'.
It contains @include commands to include all the chapters that make up
the manual.

* This distribution contains a Makefile that you can use with GNU Make.

** To make an Info file, you need to install Texinfo, then run 'make info'.

** Use 'make elisp.pdf' or 'make elisp.html' to create PDF or HTML versions.


This file is part of GNU Emacs.

GNU Emacs is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

GNU Emacs is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with GNU Emacs.  If not, see <https://www.gnu.org/licenses/>.