Commit graph

279 commits

Author SHA1 Message Date
Stefan Monnier
8b6c6cffd1 trusted-content: Adjust the last patch based on preliminary feedback
* lisp/files.el (trusted-content): Rename from `trusted-files`.
Update all references.

* lisp/progmodes/elisp-mode.el (lisp-interaction-mode):
* lisp/ielm.el (inferior-emacs-lisp-mode):
* lisp/simple.el (read--expression): Set `trusted-content` since
these buffers contain code that the user presumably intends to run anyway.
(elisp--safe-macroexpand-all): Make the warning more discreet.
2024-12-15 17:05:55 -05:00
Stefan Monnier
b5158bd191 elisp-mode.el: Disable Flymake byte-compile backend in untrusted files
To address serious security issues (CVE-2024-53920), disable
`elisp-flymake-byte-compile` except in those files explicitly
specified as "trusted".

For that introduce a new custom var `trusted-files` and new
function `trusted-content-p`.

While at it, similarly skip the implicit macroexpansion done during
completion if the current file is not trusted.

* lisp/files.el (trusted-files): New variable.
(trusted-content-p): New function.

* lisp/progmodes/elisp-mode.el (elisp--safe-macroexpand-all):
New function, extracted from `elisp--local-variables`.
Use `trusted-content-p`.
(elisp--local-variables): Use it.
(elisp-flymake-byte-compile): Disable according to `trusted-content-p`.
2024-12-14 09:48:36 -05:00
Stefan Monnier
bf8c9f702b (eval-last-sexp): Fix bug#71774
* lisp/progmodes/elisp-mode.el (eval-last-sexp): Set `values` only
when `eval-expression-debug-on-error` is nil.
2024-06-27 14:43:32 -04:00
Eli Zaretskii
82a31e27e6 Fix printing the result by 'eval-print-last-sexp'
* lisp/progmodes/elisp-mode.el (elisp--eval-last-sexp): Record the
desired output stream before evaluating the expression.
(Bug#70931)
2024-05-18 12:55:34 +03:00
Stefan Monnier
648b7bf7e2 (emacs-lisp-mode-syntax-table): Fix bug#24542
* lisp/progmodes/elisp-mode.el (emacs-lisp-mode-syntax-table):
Remove `p` from the flags of `@`.
2024-04-12 13:28:45 -04:00
Mattias Engdegård
b436f430e3 Don't hide flymake diagnostics on empty first line (bug#70310)
A diagnostic first in the buffer, typically the lexical cookie warning,
got lost if that line was empty.

* lisp/progmodes/elisp-mode.el (elisp-flymake--byte-compile-done):
Make sure the location interval doesn't go beyond the buffer bounds.
2024-04-11 13:55:39 +02:00
Mattias Engdegård
cda5155c61 Inhibit flymake lexical cookie warning in *scratch* (bug#70068)
Add a hack to prevent flymake from complaining about a missing lexical
cookie when enabled in *scratch*.

* lisp/emacs-lisp/bytecomp.el
(bytecomp--inhibit-lexical-cookie-warning): New variable.
(byte-compile-file): Use it to gate the warning.
* lisp/progmodes/elisp-mode.el (elisp-flymake-byte-compile):
Set the inhibitor when spawning a check in lisp-interaction-mode.
2024-04-09 10:56:44 +02:00
Stefan Monnier
9a801f0b46 * lisp/progmodes/elisp-mode.el (eval-last-sexp, eval-defun): Fix thinko 2024-02-24 17:52:14 -05:00
Stefan Monnier
84f72f19e5 elisp-mode.el: Use handler-bind instead of debug-on-error
* lisp/progmodes/elisp-mode.el (elisp-enable-lexical-binding):
Don't get fooled by a global binding of `lexical-binding` to t.
(elisp--eval-last-sexp-fake-value): Delete var.
(elisp--eval-defun): Don't let-bind `debug-on-error` since it's
already arranged by the only caller.
(eval-last-sexp, eval-defun): Use `handler-bind` instead of
`debug-on-error`.
2024-02-23 16:46:01 -05:00
Eli Zaretskii
b54db9c9ac ; * lisp/progmodes/elisp-mode.el (emacs-lisp-native-compile): Fix typo. 2024-02-14 05:24:36 +02:00
Eli Zaretskii
10bf810e84 Fix left-over from renaming 'comp-*' functions
* lisp/progmodes/elisp-mode.el (comp--write-bytecode-file): Call
this instead of 'comp-write-bytecode-file', its old name.
Reported by Arthur Miller <arthur.miller@live.com>.
2024-02-13 21:59:03 +02:00
Stefan Monnier
a33f3947ea * lisp/progmodes/elisp-mode.el (elisp-completion-at-point): Fix bug#68514
Redo the commit 0db2126d71 to try and avoid selecting more than
a mere symbol.
2024-01-18 14:05:16 -05:00
Po Lu
ecf08f0621 Merge from savannah/emacs-29
dc4e6b1329 ; Update copyright years in more files
64b3777631 ; Run set-copyright from admin.el
8e1c56ae46 ; Add 2024 to copyright years

# Conflicts:
#	doc/misc/modus-themes.org
#	doc/misc/texinfo.tex
#	etc/NEWS
#	etc/refcards/ru-refcard.tex
#	etc/themes/modus-operandi-theme.el
#	etc/themes/modus-themes.el
#	etc/themes/modus-vivendi-theme.el
#	lib/alloca.in.h
#	lib/binary-io.h
#	lib/c-ctype.h
#	lib/c-strcasecmp.c
#	lib/c-strncasecmp.c
#	lib/careadlinkat.c
#	lib/cloexec.c
#	lib/close-stream.c
#	lib/diffseq.h
#	lib/dup2.c
#	lib/filemode.h
#	lib/fpending.c
#	lib/fpending.h
#	lib/fsusage.c
#	lib/getgroups.c
#	lib/getloadavg.c
#	lib/gettext.h
#	lib/gettime.c
#	lib/gettimeofday.c
#	lib/group-member.c
#	lib/malloc.c
#	lib/md5-stream.c
#	lib/md5.c
#	lib/md5.h
#	lib/memmem.c
#	lib/memrchr.c
#	lib/nanosleep.c
#	lib/save-cwd.h
#	lib/sha1.c
#	lib/sig2str.c
#	lib/stdlib.in.h
#	lib/strtoimax.c
#	lib/strtol.c
#	lib/strtoll.c
#	lib/time_r.c
#	lib/xalloc-oversized.h
#	lisp/auth-source-pass.el
#	lisp/emacs-lisp/lisp-mnt.el
#	lisp/emacs-lisp/timer.el
#	lisp/info-look.el
#	lisp/jit-lock.el
#	lisp/loadhist.el
#	lisp/mail/rmail.el
#	lisp/net/ntlm.el
#	lisp/net/webjump.el
#	lisp/progmodes/asm-mode.el
#	lisp/progmodes/project.el
#	lisp/progmodes/sh-script.el
#	lisp/textmodes/flyspell.el
#	lisp/textmodes/reftex-toc.el
#	lisp/textmodes/reftex.el
#	lisp/textmodes/tex-mode.el
#	lisp/url/url-gw.el
#	m4/alloca.m4
#	m4/clock_time.m4
#	m4/d-type.m4
#	m4/dirent_h.m4
#	m4/dup2.m4
#	m4/euidaccess.m4
#	m4/fchmodat.m4
#	m4/filemode.m4
#	m4/fsusage.m4
#	m4/getgroups.m4
#	m4/getloadavg.m4
#	m4/getrandom.m4
#	m4/gettime.m4
#	m4/gettimeofday.m4
#	m4/gnulib-common.m4
#	m4/group-member.m4
#	m4/inttypes.m4
#	m4/malloc.m4
#	m4/manywarnings.m4
#	m4/mempcpy.m4
#	m4/memrchr.m4
#	m4/mkostemp.m4
#	m4/mktime.m4
#	m4/nproc.m4
#	m4/nstrftime.m4
#	m4/pathmax.m4
#	m4/pipe2.m4
#	m4/pselect.m4
#	m4/pthread_sigmask.m4
#	m4/readlink.m4
#	m4/realloc.m4
#	m4/sig2str.m4
#	m4/ssize_t.m4
#	m4/stat-time.m4
#	m4/stddef_h.m4
#	m4/stdint.m4
#	m4/stdio_h.m4
#	m4/stdlib_h.m4
#	m4/stpcpy.m4
#	m4/strnlen.m4
#	m4/strtoimax.m4
#	m4/strtoll.m4
#	m4/time_h.m4
#	m4/timegm.m4
#	m4/timer_time.m4
#	m4/timespec.m4
#	m4/unistd_h.m4
#	m4/warnings.m4
#	nt/configure.bat
#	nt/preprep.c
#	test/lisp/register-tests.el
2024-01-02 10:28:14 +08:00
Po Lu
8e1c56ae46 ; Add 2024 to copyright years 2024-01-02 09:47:10 +08:00
Eli Zaretskii
1be6204473 Merge from origin/emacs-29
a475165738 * doc/man/emacsclient.1: Fix --tramp option.
1e5357d3d1 * doc/man/emacsclient.1: Add missing sections (bug#66598)
fba7b9db39 Add explanation for extra parentheses in ELisp Introduction
7723282682 Add sample code to the "let*" section in "forward-paragraph"
7a00ca92c1 Fix treesit test (bug#67117)
d220893216 Fix c++-ts-mode indentation (bug#67975)
d386a8aa43 Recommend customizing eglot for python-base-mode
bd0c758971 Improve documentation of new native-compilation commands
1ad126c0f2 ; Fix typo
77678244b8 doc/lispintro: Don't mention `set` (bug#67734)
cb3684e9df Fix script for some characters
2922d683b7 ; * src/treesit.c (treesit_traverse_child_helper): Fix co...
7b315e8a5c Fix an issue when searching subtree backward (bug#67117)
03625c2fef Fix passive mode for tnftp client in ange-ftp.el.
b6429b1c1c ; Improve documentation of ispell.el's dictionary database
75cc159341 ; * etc/PROBLEMS: Update the "GnuPG hangs" entry.
67d9af1c07 Fix using disabled command without a docstring
f68f350023 Improve documentation of text properties handling when ya...
06c399914f Eglot: Add Uiua language server
2023-12-23 06:30:40 -05:00
Eli Zaretskii
bd0c758971 Improve documentation of new native-compilation commands
* lisp/progmodes/elisp-mode.el (emacs-lisp-mode-menu)
(emacs-lisp-native-compile, emacs-lisp-native-compile-and-load):
Doc fixes.

* doc/lispref/compile.texi (Native-Compilation Functions):
Document 'emacs-lisp-native-compile' and
'emacs-lisp-native-compile-and-load'.
2023-12-22 16:49:49 +02:00
Juri Linkov
1cb738a482 * lisp/progmodes/elisp-mode.el (elisp--local-variables): Remove `debug'.
Remove symbol `debug' from the condition-case handler of `error'
that was added in commit f931cebce7
since it interferes on completing in an incomplete elisp form (bug#66979).
2023-11-09 09:35:23 +02:00
Jens Schmidt
86e8f31505 Silence macro expansion during completion at point
* lisp/emacs-lisp/macroexp.el (macroexp-inhibit-compiler-macros): Add
variable.
(macroexp--compiler-macro): Inspect that new variable and, if it is
non-nil, return the input form unchanged.
* lisp/progmodes/elisp-mode.el (elisp--local-variables): Silence
messages.  Avoid compiler macros.  (Bug#58148)
2023-10-05 14:00:36 -04:00
Jens Schmidt
6cf7e676e9 Silence macro expansion during completion at point
To keep risk in the current release branch low, do not avoid compiler
macros as suggested by Stefan in the bug, but rather suppress all errors.

* lisp/progmodes/elisp-mode.el (elisp--local-variables): Silence
messages.  Suppress all errors during macro expansion.  (Bug#58148)

Do not merge to master.
2023-10-05 14:00:20 -04:00
Alan Mackenzie
f931cebce7 Insert symbol `debug' into two condition-case handlers
This fixes bug#65622.  Also correct a mismatch between a
function to which advice is added, and that from which it is
removed.

* lisp/emacs-lisp/macroexp.el (internal-macroexpand-for-load):
Add a `debug' to the condition-case handler for `error', so
that a useful backtrace will be produced on a macro expansion
error.

* lisp/progmodes/elisp-mode.el (elisp--local-variables): Add
`debug' to a condition-case handler, as above.  In the
advice-remove call, give the same function, macroexpand-1, as
in the corresponding advice-add call.
2023-09-20 15:51:17 +00:00
Stefan Monnier
ecb1e6c713 (elisp--local-variables): Fix recent regression
While at it, make it work when completing code within `eval-when-compile`
and friends, where it failed in sometimes spectacular ways.

* lisp/progmodes/elisp-mode.el (elisp--local-macroenv): New var.
(elisp--local-variables): Use it.  Also, advice `macroexpand-1` since
`macroexpand-all` doesn't use `macroexpand` any more.
(prin1-char): Remove redundant "" arg.
(elisp--eval-defun-1): Align the `eval` call to what's used in
`custom-initialize-set`.
2023-08-26 15:44:28 -04:00
Eli Zaretskii
3fc9793a26 Merge from origin/emacs-29
842dbf500e * Fix `batch-byte+native-compile' target directory.
8dbd5aa1ee Avoid crashes in 'display_count_lines' when current buffe...
47b4f4cf78 ; * doc/emacs/mini.texi (Completion Commands): Fix a typo...
78999d5213 Update csharp tree-sitter support due to upstream changes
556cb01b48 Substitute command keys in 'ielm-header' at use time
99367078e5 ; * etc/PROBLEMS: Add entry about XIM problems (bug#65205).
03e897c08f Fix rare crashes in redisplay due to problems with fontsets
b1ba06a1e4 Fix a typo in 'leuven-dark-theme.el'
e80a9dcabb ; * admin/git-bisect-start: Update failing commits
9091f42784 ; * admin/git-bisect-start: Update failing commits
344ac529ca ; * etc/PROBLEMS: Fix typo.
bccf848b26 Adapt Tramp test
71bc060e40 Properly expand the JSX indentation rules in 'js-ts-mode'
889cfb42ed * Add `emacs-lisp-native-compile' to easy-menu.
4535aafa8a * lisp/progmodes/elisp-mode.el (emacs-lisp-mode-menu): Si...
173af0cad5 * Introduce `emacs-lisp-native-compile'.
063d7d89d7 Fix the -x switch in non-X builds
5a7fb0b39b Document that `set-mouse-color' does not work everywhere
d06fc72496 ; * doc/emacs/dired.texi (Misc Dired Features): Fix last ...
97b8ac376b Fix the effects and documentation of 'dired-free-space'
75c72e59f6 ; Fix typo
6d11b7b300 Fix cross-reference to eldoc in eglot manual
913e50aba6 Add native-compilation to Emacs Lisp mode menu
b93107c20b Fix emacs-lisp-native-compile-and-load eln target directo...
2023-08-12 13:50:38 -04:00
Andrea Corallo
889cfb42ed * Add `emacs-lisp-native-compile' to easy-menu.
* lisp/progmodes/elisp-mode.el (emacs-lisp-mode-menu): Add menu
item for emacs-lisp-native-compile.
2023-08-10 10:39:14 +02:00
Andrea Corallo
4535aafa8a * lisp/progmodes/elisp-mode.el (emacs-lisp-mode-menu): Simplify condition. 2023-08-10 10:34:01 +02:00
Andrea Corallo
173af0cad5 * Introduce `emacs-lisp-native-compile'.
* lisp/progmodes/elisp-mode.el (emacs-lisp-native-compile): New command.
(emacs-lisp-native-compile-and-load): Make use of.
2023-08-10 10:32:02 +02:00
Eli Zaretskii
913e50aba6 Add native-compilation to Emacs Lisp mode menu
* lisp/progmodes/elisp-mode.el (emacs-lisp-mode-menu): Add menu
item for emacs-lisp-native-compile-and-load.
2023-08-09 17:35:24 +03:00
Mattias Engdegård
6b9510d94f Prefix syntax for ,@ in elisp-mode (bug#44418)
* lisp/progmodes/elisp-mode.el (elisp-mode-syntax-propertize):
Use prefix syntax for ,@ to avoid the @ becoming part of a symbol
that follows.
* test/lisp/emacs-lisp/edebug-tests.el (edebug-tests-with-normal-env):
Propertise inserted Lisp code to keep the test working.
2023-06-21 18:00:26 +02:00
Eli Zaretskii
acfd261a61 Merge from origin/emacs-29
0d8b69e0ad Don't ding when completion succeeded
f11e2d3699 ; * admin/git-bisect-start: Update failing commits
9855a3ea74 ; * src/xdisp.c (redisplay_tool_bar): Fix a typo in a com...
f4ee696b88 Improve documentation of color-related functions
90eadc3e23 Revert "* package.el (package--get-activatable-pkg): Pref...
65f355ea0a ; Update my mail address
a3a69ec234 Fix connection-local user options handling (bug#63300)
240803cc3e Document 'startup-redirect-eln-cache'
026afb2298 ; * etc/PROBLEMS: Entry about crashes due to anti-virus (...
bcc222251e Fix `emacs-lisp-native-compile-and-load' for C-h f (bug#5...
07c8211ca3 Add 'infer' as a keyword to typescript-ts-mode (bug#63880)
dd2d8ff2f5 ; * etc/NEWS: Mention the issue with PGTK on WSL (bug#633...
fa8135f891 Revert changes to the order in which package descs are lo...
27fcfa2c0a ; * etc/NEWS: Improve instructions for grammar libraries.
2a84ab905c Handle point in last file-name component in minibuffer co...
05f25238b7 Merge branch 'emacs-29' of git.savannah.gnu.org:/srv/git/...
4bc043ff45 Avoid asking redundant question in emacsbug.el
2eadf328d0 * test/infra/Dockerfile.emba (emacs-base): Don't install ...
583ba1db7e typescript-ts-mode: Add a rule for function_signature

# Conflicts:
#	etc/NEWS
#	lisp/minibuffer.el
2023-06-10 06:42:43 -04:00
Andrea Corallo
bcc222251e Fix `emacs-lisp-native-compile-and-load' for C-h f (bug#58314)
* lisp/emacs-lisp/comp.el (comp-write-bytecode-file): New function
spilling code from `batch-byte+native-compile'.
(batch-byte+native-compile): Make use of.
* lisp/progmodes/elisp-mode.el
(emacs-lisp-native-compile-and-load): Produce the elc file and ask
to have it loaded.
2023-06-06 12:21:43 +02:00
Stefan Kangas
8179555730 Merge from origin/emacs-29
bd07cec844 Fix regression in Fido mode (bug#62015)
0e3c7ac13d * Fix `emacs-lisp-native-compile-and-load' for (bug#61917)
4a7e657389 * lisp/emacs-lisp/comp.el (comp-prettyformat-insn): Fix (...
8a8a994cfa Revert "Fix configuration of webp libraries"
de4277af00 Fix configuration of webp libraries
2023-03-07 06:30:10 +01:00
Andrea Corallo
0e3c7ac13d * Fix `emacs-lisp-native-compile-and-load' for (bug#61917)
* lisp/progmodes/elisp-mode.el (emacs-lisp-native-compile-and-load):
Don't load if no compialtion happened.
2023-03-06 17:29:36 +01:00
Stefan Kangas
580bb8f46c Merge from origin/emacs-29
3cae0e3d96 python-ts-mode: Fix single-quote string fontification
68d753e371 ; * etc/NEWS: Fix typos.
ab0cc4e781 Fix infloop in bidi.c
3b8b23f66d ; Fix doc string of 'emacs-lisp-byte-compile'

# Conflicts:
#	etc/NEWS
2023-02-26 06:30:12 +01:00
Eli Zaretskii
3b8b23f66d ; Fix doc string of 'emacs-lisp-byte-compile'
* lisp/progmodes/elisp-mode.el (emacs-lisp-byte-compile): Doc
fix.  (Bug#61784)
2023-02-25 15:51:04 +02:00
Eric Abrahamsen
cac13e3605 Help Elisp xref recognize defclass parent classes
* lisp/progmodes/elisp-mode.el (elisp--xref-infer-namespace):
Handle defclass parents (bug#61640).

* test/lisp/progmodes/elisp-mode-tests.el (elisp-mode-infer-namespace):
New case in the test.
2023-02-20 03:01:41 +02:00
Andrea Corallo
8d8464bd5a Rename native-comp-deferred-compilation into native-comp-jit-compilation
* src/comp.c (maybe_defer_native_compilation, syms_of_comp):
	Rename native-comp-deferred-compilation into
	native-comp-jit-compilation.

	* lisp/subr.el (native-comp-deferred-compilation): Mark
	native-comp-deferred-compilation as obsolete.

	* lisp/startup.el (native-comp-deferred-compilation)
	(normal-top-level): Rename native-comp-deferred-compilation into
	native-comp-jit-compilation.

	* lisp/progmodes/elisp-mode.el
	(emacs-lisp-native-compile-and-load): Likewise.

	* lisp/emacs-lisp/generate-lisp-file.el
	(generate-lisp-file-trailer): Likewise.
2023-02-13 17:04:22 +01:00
Andrea Corallo
c0681cd347 Revert "Add new variable 'inhibit-native-compilation'"
This reverts commit 5fec9182db.
2023-02-13 10:19:31 +01:00
Andrea Corallo
3969a34fa1 Revert "Rename to inhibit-automatic-native-compilation"
This reverts commit f97993ee66.
2023-02-13 10:15:33 +01:00
Eli Zaretskii
cae528457c ; Add 2023 to copyright years. 2023-01-01 05:31:12 -05:00
Juri Linkov
4bc9fe33af Rename 'elisp-eval-buffer' to 'elisp-eval-region-or-buffer' (bug#59350)
* lisp/progmodes/elisp-mode.el (elisp-eval-region-or-buffer):
Rename recently added command 'elisp-eval-buffer' to support active region.
(emacs-lisp-mode-map, lisp-interaction-mode-map): Rebind 'C-c C-e'
from elisp-eval-buffer to elisp-eval-region-or-buffer.
2022-11-20 20:10:45 +02:00
Stefan Kangas
ba485eb949 ; Fix typos 2022-11-18 16:02:19 +01:00
Eli Zaretskii
5df1fd19ba ; * lisp/progmodes/elisp-mode.el (eval-defun): Doc fix. 2022-11-17 12:34:06 +02:00
Eli Zaretskii
69d1278527 ; Fix some doc strings in elisp-mode.el
* lisp/progmodes/elisp-mode.el (elisp-enable-lexical-binding)
(elisp--local-variables-1, elisp--expect-function-p)
(eval-print-last-sexp, eval-last-sexp, elisp--eval-defun-1)
(eval-defun, elisp--eldoc-last-data, elisp-eldoc-funcall)
(elisp-eldoc-var-docstring)
(elisp-eldoc-var-docstring-with-value)
(elisp-get-fnsym-args-string)
(elisp--highlight-function-argument): Doc fixes.
2022-11-15 19:58:52 +02:00
Stefan Monnier
13d6e8fa54 cl-generic: Fix advertised-calling-convention declarations
* lisp/emacs-lisp/cl-generic.el (cl-generic-define-method):
Preserve the `advertised-calling-convention`, if any (bug#58563).

* lisp/subr.el (declare): Warn when we hit this.

* lisp/emacs-lisp/byte-run.el (get-advertised-calling-convention): New fun.
* lisp/progmodes/elisp-mode.el (elisp-get-fnsym-args-string):
* lisp/help-fns.el (help-fns--signature):
* lisp/emacs-lisp/bytecomp.el (byte-compile-fdefinition): Use it.

* test/lisp/emacs-lisp/cl-generic-tests.el (cl-generic-tests--acc): New fun.
(cl-generic-tests--advertised-calling-convention-bug58563): New test.
2022-10-16 12:01:47 -04:00
Lars Ingebrigtsen
f97993ee66 Rename to inhibit-automatic-native-compilation
* src/comp.c (maybe_defer_native_compilation):
(syms_of_comp):
* lisp/subr.el (native-comp-deferred-compilation):
* lisp/startup.el (inhibit-native-compilation):
(normal-top-level):
* lisp/progmodes/elisp-mode.el (emacs-lisp-native-compile-and-load):
* lisp/emacs-lisp/comp.el (comp-trampoline-compile):
* etc/NEWS:
* doc/lispref/compile.texi (Native-Compilation Variables): Rename
inhibit-native-compilation to inhibit-automatic-native-compilation.
2022-10-03 19:50:03 +02:00
Lars Ingebrigtsen
5fec9182db Add new variable 'inhibit-native-compilation'
* doc/lispref/compile.texi (Native-Compilation Variables):
Document it.

* lisp/startup.el (normal-top-level): Set
inhibit-native-compilation from environment variable.

* lisp/subr.el (native-comp-deferred-compilation): Make obsolete.

* lisp/emacs-lisp/comp.el (comp-trampoline-compile): Don't write
trampolines to disk.

* lisp/progmodes/elisp-mode.el
(emacs-lisp-native-compile-and-load): Adjust.

* src/comp.c (syms_of_comp): New variable
inhibit-native-compilation.
(maybe_defer_native_compilation): Use it.
2022-10-03 15:26:13 +02:00
Daniel Martín
dbec115948 Fix instrumented eval-defun not printing "Edebug:" to the echo area
* lisp/progmodes/elisp-mode.el (elisp--eval-defun): Determine if we're
instrumenting a function and call eval-region with PRINTFLAG set to
nil if so (Bug#50245).

* test/lisp/progmodes/elisp-mode-tests.el
(eval-defun-prints-edebug-when-instrumented): Add a new test.
2022-08-25 14:37:36 +02:00
Stefan Monnier
3b72b47cbd * lisp/progmodes/elisp-mode.el (elisp--local-variables-1): Fix bug#50034
Don't burp if the arg list of a function is not actually a list.
2022-08-23 10:16:05 -04:00
Stefan Kangas
b7e867b841 Make point-at-eol and point-at-bol obsolete
* lisp/subr.el (point-at-eol, point-at-bol): Make XEmacs compat
aliases obsolete in favor of `pos-bol'/'line-beginning-position' or
'pos-eol'/'line-end-position'.  Update callers.
Ref: https://lists.gnu.org/r/emacs-devel/2022-08/msg00853.html
2022-08-23 04:54:57 +02:00
Lars Ingebrigtsen
3a4c408a7b Fix elisp-byte-compile-buffer requirements
* lisp/progmodes/elisp-mode.el (elisp-byte-compile-buffer):
Require bytecomp so that byte-compile-dest-file-function is
defined.  (The byte compiler didn't catch this, because it's
defined in bytecomp.)
2022-07-01 13:19:31 +02:00
Lars Ingebrigtsen
a6a92b8e4d Also add elisp-eval/byte-compile-buffer to lisp-interaction-mode
* lisp/progmodes/elisp-mode.el (lisp-interaction-mode-map): Also
add elisp-eval-buffer and elisp-byte-compile-buffer to this map.
2022-06-30 14:46:04 +02:00