diff options
| author | Mattias EngdegÄrd | 2023-05-18 17:33:15 +0200 |
|---|---|---|
| committer | Mattias EngdegÄrd | 2023-05-20 11:05:57 +0200 |
| commit | 0de472e04fb29581e8302b60fafc707b18d7cbf3 (patch) | |
| tree | 0d57b3f16fbd2baf536874a4d319b0f8b1ca1efe | |
| parent | bd6bba4780dcfdec97ab5e6469f7777c4b2a1b0d (diff) | |
| download | emacs-0de472e04fb29581e8302b60fafc707b18d7cbf3.tar.gz emacs-0de472e04fb29581e8302b60fafc707b18d7cbf3.zip | |
Use `delq` return value (bug#61730)
* lisp/calc/calc-graph.el (calc-graph-compute-2d):
* lisp/calendar/appt.el (appt-activate):
* lisp/progmodes/cc-styles.el (c-make-styles-buffer-local):
Make use of what `delq` returns, to stave off possible mistakes or at
least make clear that there isn't any.
| -rw-r--r-- | lisp/calc/calc-graph.el | 7 | ||||
| -rw-r--r-- | lisp/calendar/appt.el | 2 | ||||
| -rw-r--r-- | lisp/progmodes/cc-styles.el | 5 |
3 files changed, 8 insertions, 6 deletions
diff --git a/lisp/calc/calc-graph.el b/lisp/calc/calc-graph.el index 3de761e19f8..1b9d25daf3b 100644 --- a/lisp/calc/calc-graph.el +++ b/lisp/calc/calc-graph.el | |||
| @@ -598,9 +598,10 @@ | |||
| 598 | (math-build-var-name (car math-arglist)) | 598 | (math-build-var-name (car math-arglist)) |
| 599 | '(var DUMMY var-DUMMY))))) | 599 | '(var DUMMY var-DUMMY))))) |
| 600 | (setq calc-graph-ycache (assoc calc-graph-yvalue calc-graph-data-cache)) | 600 | (setq calc-graph-ycache (assoc calc-graph-yvalue calc-graph-data-cache)) |
| 601 | (delq calc-graph-ycache calc-graph-data-cache) | 601 | (setq calc-graph-data-cache |
| 602 | (nconc calc-graph-data-cache | 602 | (nconc (delq calc-graph-ycache calc-graph-data-cache) |
| 603 | (list (or calc-graph-ycache (setq calc-graph-ycache (list calc-graph-yvalue))))) | 603 | (list (or calc-graph-ycache |
| 604 | (setq calc-graph-ycache (list calc-graph-yvalue)))))) | ||
| 604 | (if (and (not (setq calc-graph-xvec (eq (car-safe calc-graph-xvalue) 'vec))) | 605 | (if (and (not (setq calc-graph-xvec (eq (car-safe calc-graph-xvalue) 'vec))) |
| 605 | calc-graph-refine (cdr (cdr calc-graph-ycache))) | 606 | calc-graph-refine (cdr (cdr calc-graph-ycache))) |
| 606 | (calc-graph-refine-2d) | 607 | (calc-graph-refine-2d) |
diff --git a/lisp/calendar/appt.el b/lisp/calendar/appt.el index 49597739446..11beee94e64 100644 --- a/lisp/calendar/appt.el +++ b/lisp/calendar/appt.el | |||
| @@ -707,7 +707,7 @@ ARG is positive, otherwise off." | |||
| 707 | (not appt-active))) | 707 | (not appt-active))) |
| 708 | (remove-hook 'write-file-functions #'appt-update-list) | 708 | (remove-hook 'write-file-functions #'appt-update-list) |
| 709 | (or global-mode-string (setq global-mode-string '(""))) | 709 | (or global-mode-string (setq global-mode-string '(""))) |
| 710 | (delq 'appt-mode-string global-mode-string) | 710 | (setq global-mode-string (delq 'appt-mode-string global-mode-string)) |
| 711 | (when appt-timer | 711 | (when appt-timer |
| 712 | (cancel-timer appt-timer) | 712 | (cancel-timer appt-timer) |
| 713 | (setq appt-timer nil)) | 713 | (setq appt-timer nil)) |
diff --git a/lisp/progmodes/cc-styles.el b/lisp/progmodes/cc-styles.el index fc4f723915c..e412a52cfb8 100644 --- a/lisp/progmodes/cc-styles.el +++ b/lisp/progmodes/cc-styles.el | |||
| @@ -658,8 +658,9 @@ any reason to call this function directly." | |||
| 658 | (let ((func (if this-buf-only-p | 658 | (let ((func (if this-buf-only-p |
| 659 | 'make-local-variable | 659 | 'make-local-variable |
| 660 | 'make-variable-buffer-local)) | 660 | 'make-variable-buffer-local)) |
| 661 | (varsyms (cons 'c-indentation-style (copy-alist c-style-variables)))) | 661 | (varsyms (cons 'c-indentation-style |
| 662 | (delq 'c-special-indent-hook varsyms) | 662 | (delq 'c-special-indent-hook |
| 663 | (copy-alist c-style-variables))))) | ||
| 663 | (mapc func varsyms) | 664 | (mapc func varsyms) |
| 664 | ;; Hooks must be handled specially | 665 | ;; Hooks must be handled specially |
| 665 | (if this-buf-only-p | 666 | (if this-buf-only-p |