diff options
author | Mattias EngdegÄrd <mattiase@acm.org> | 2023-02-17 14:38:50 +0100 |
---|---|---|
committer | Mattias EngdegÄrd <mattiase@acm.org> | 2023-02-17 14:52:54 +0100 |
commit | d5bf26f488b7968feed9f43e612a90da2aab15a8 (patch) | |
tree | f31f3a743eef072012597f812fd2e5635c170de7 /lisp/env.el | |
parent | 7ab6c6ac8334f80a2effcb9d66d2c57810c9a73e (diff) | |
download | emacs-d5bf26f488b7968feed9f43e612a90da2aab15a8.tar.gz |
Move side-effect-free and pure declarations to function definitions
Some Lisp functions still had their `side-effect-free` and `pure`
properties declared in byte-opt.el; do it at their definition instead.
The lists in byte-opt.el now only contain functions implemented in C
and function aliases.
* lisp/emacs-lisp/byte-opt.el (side-effect-free-fns)
(side-effect-and-error-free-fns, pure-fns):
Remove functions whose properties are now declared elsewhere
and some obsolete entries.
* lisp/custom.el (custom-variable-p):
* lisp/emacs-lisp/lisp.el (buffer-end):
* lisp/emacs-lisp/regexp-opt.el (regexp-opt):
* lisp/env.el (getenv):
* lisp/simple.el (count-lines, mark, string-empty-p, lax-plist-get):
* lisp/subr.el (ignore, always, zerop, fixnump, bignump, lsh, last)
(eventp, mouse-movement-p, log10, memory-limit, string-greaterp)
(interactive-p):
* lisp/window.el (get-lru-window, get-largest-window, (window-edges)
(window-body-edges, window-pixel-edges, window-body-pixel-edges)
(window-absolute-pixel-edges, window-absolute-body-pixel-edges)
(one-window-p):
Declare functions `side-effect-free` and/or `pure` as appropriate.
Diffstat (limited to 'lisp/env.el')
-rw-r--r-- | lisp/env.el | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lisp/env.el b/lisp/env.el index 33c02f6f920..a9d1d27e1ee 100644 --- a/lisp/env.el +++ b/lisp/env.el @@ -205,6 +205,7 @@ Otherwise, this function searches `process-environment' for VARIABLE. If it is not found there, then it continues the search in the environment list of the selected frame." (interactive (list (read-envvar-name "Get environment variable: " t))) + (declare (side-effect-free t)) (let ((value (getenv-internal (if (multibyte-string-p variable) (encode-coding-string variable locale-coding-system) |