GNU bug report logs -
#42397
[PATCH 00/14] Use outline headings and some cosmetics
Previous Next
Reported by: Jonas Bernoulli <jonas <at> bernoul.li>
Date: Thu, 16 Jul 2020 14:48:02 UTC
Severity: normal
Tags: patch
Fixed in version 28.1
Done: Stefan Kangas <stefankangas <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
In this case we can greatly increase readability by using `cl-case'
instead of `cond'.
---
lisp/epg.el | 19 +++++++------------
1 file changed, 7 insertions(+), 12 deletions(-)
diff --git a/lisp/epg.el b/lisp/epg.el
index 5b90bc290a..65decf3cf5 100644
--- a/lisp/epg.el
+++ b/lisp/epg.el
@@ -404,18 +404,13 @@ epg-signature-to-string
(pubkey-algorithm (epg-signature-pubkey-algorithm signature))
(key-id (epg-signature-key-id signature)))
(concat
- (cond ((eq (epg-signature-status signature) 'good)
- "Good signature from ")
- ((eq (epg-signature-status signature) 'bad)
- "Bad signature from ")
- ((eq (epg-signature-status signature) 'expired)
- "Expired signature from ")
- ((eq (epg-signature-status signature) 'expired-key)
- "Signature made by expired key ")
- ((eq (epg-signature-status signature) 'revoked-key)
- "Signature made by revoked key ")
- ((eq (epg-signature-status signature) 'no-pubkey)
- "No public key for "))
+ (cl-case (epg-signature-status signature)
+ (good "Good signature from ")
+ (bad "Bad signature from ")
+ (expired "Expired signature from ")
+ (expired-key "Signature made by expired key ")
+ (revoked-key "Signature made by revoked key ")
+ (no-pubkey "No public key for "))
key-id
(if user-id
(concat " "
--
2.28.0
This bug report was last modified 4 years and 342 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.