[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#42397: [PATCH v2 06/16] Merge two conditions and fix indentation
From: |
Jonas Bernoulli |
Subject: |
bug#42397: [PATCH v2 06/16] Merge two conditions and fix indentation |
Date: |
Mon, 10 Aug 2020 23:14:20 +0200 |
The motivation behind this change is that the indentation of some
lines was outright wrong. If we address that issue, then we might
as well also address the issue that some code is needlessly nested
an additional level. That we can fix by merging the conditions.
By doing these two changes in on commit we have to change the fewest
lines. Even though we are moving to using just spaces for indentation
of the modified lines, other lines in the same function are left alone
and continue to us tabs+spaces for indentation. That is not "wrong",
but just the style we are slowly migrating away from when touching
lines for other reasons.
Discussed in bug#42397.
* lisp/emacs-lisp/eldoc.el (eldoc-minibuffer-message): Merge two
conditions and fix indentation.
---
lisp/emacs-lisp/eldoc.el | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/lisp/emacs-lisp/eldoc.el b/lisp/emacs-lisp/eldoc.el
index 19b3bd78ae..4825b5c5e6 100644
--- a/lisp/emacs-lisp/eldoc.el
+++ b/lisp/emacs-lisp/eldoc.el
@@ -289,13 +289,13 @@ eldoc-minibuffer-message
(or (window-in-direction 'above (minibuffer-window))
(minibuffer-selected-window)
(get-largest-window)))
- (when mode-line-format
- (unless (and (listp mode-line-format)
- (assq 'eldoc-mode-line-string mode-line-format))
+ (when (and mode-line-format
+ (not (and (listp mode-line-format)
+ (assq 'eldoc-mode-line-string
mode-line-format))))
(setq mode-line-format
(list "" '(eldoc-mode-line-string
(" " eldoc-mode-line-string " "))
- mode-line-format))))
+ mode-line-format)))
(setq eldoc-mode-line-string
(when (stringp format-string)
(apply #'format-message format-string args)))
--
2.28.0
- bug#42397: [PATCH v2 00/16] Use outline headings and some cosmetics, Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 01/16] ; * lisp/epg.el (epg-signature-to-string): Use cl-case., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 02/16] ; * lisp/epg.el (epg-signature-to-string): Tiny refactor., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 04/16] * lisp/epa.el (epa--derived-mode-p): Remove unnecessary alias., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 05/16] Split EasyPG libraries into outline sections, Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 06/16] Merge two conditions and fix indentation,
Jonas Bernoulli <=
- bug#42397: [PATCH v2 03/16] ; * lisp/epg.el (epg-no-data-reason-alist): Fix typo in message., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 07/16] * lisp/progmodes/compile.el: Remove unnecessary comments., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 08/16] ; * lisp/whitespace.el: Capitalize "Code" section heading., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 09/16] * lisp/mail/smtpmail.el: Use outline headings., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 11/16] * lisp/obsolete/longlines.el: Use proper outline headings., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 10/16] * test/src/emacs-module-tests.el: Use proper outline headings., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 15/16] ; * lisp/emacs-lisp/autoload.el: Begin summary line with three semicolons., Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 16/16] Update section heading conventions for libraries, Jonas Bernoulli, 2020/08/10
- bug#42397: [PATCH v2 13/16] * lisp/font-lock.el: Split the Commentary into subsections., Jonas Bernoulli, 2020/08/10