[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/parseclj 30c950a4ad 167/185: Use map-contains-key
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/parseclj 30c950a4ad 167/185: Use map-contains-key |
Date: |
Tue, 28 Dec 2021 14:05:33 -0500 (EST) |
branch: elpa/parseclj
commit 30c950a4ad42ada5f8b63045bc7567940f2f2987
Author: Arne Brasseur <arne@arnebrasseur.net>
Commit: Bozhidar Batsov <bozhidar@batsov.dev>
Use map-contains-key
---
parseclj.el | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/parseclj.el b/parseclj.el
index 3896c6b9ba..d10acaef4e 100644
--- a/parseclj.el
+++ b/parseclj.el
@@ -55,12 +55,10 @@ For example: (a-hash-table :foo 123 :bar 456)"
kv-pairs)
hash-map))
-(defun parseclj-alist-has-key? (coll k)
- "Check if the given association list COLL has a certain key K."
- (not (eq (map-elt coll k :not-found) :not-found)))
-
(defun parseclj-alist-assoc (coll k v)
- (if (parseclj-alist-has-key? coll k)
+ "Like parseclj-alist-assoc but actually works as advertised, not
+introducing duplicate keys"
+ (if (map-contains-key coll k)
(mapcar (lambda (entry)
(if (equal (car entry) k)
(cons k v)
- [nongnu] elpa/parseclj aeac6a1755 118/185: Fix code's organization for 2-item stack reduction, (continued)
- [nongnu] elpa/parseclj aeac6a1755 118/185: Fix code's organization for 2-item stack reduction, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj bad1fb8745 119/185: Merge pull request #12 from lambdaisland/nested-2-items-reduction, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj b377e12d7e 125/185: Add test case for invalid input error token, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj 903d60284e 130/185: Update the Travis CI badge, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj d691df5d63 131/185: Update the copyright years, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj acf4a29778 132/185: Update the README, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj d42b4ad744 144/185: Require a couple of dependencies to `parseclj-ast.el`, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj c32017ecc9 143/185: Merge pull request #20 from clojure-emacs/remove-parseedn, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj ece9648128 179/185: Merge pull request #33 from clojure-emacs/arne/remove-a-from-tests, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj c7f50e3414 178/185: Update CHANGELOG, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj 30c950a4ad 167/185: Use map-contains-key,
ELPA Syncer <=
- [nongnu] elpa/parseclj 0d157d759b 163/185: Merge branch 'master' into shebang-and-symbolic-values, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj 089160a487 169/185: Drop a.el dependency, bump copyright year, bump version, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj 93a0f43529 150/185: Merge pull request #21 from clojure-emacs/add-more-syntax-features, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj adb55fa579 183/185: Merge pull request #34 from clojure-emacs/cl-case-to-cond, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj dec638c5ca 153/185: Tweak the keywords, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj 5cf5cd5f53 182/185: Replace seq-doseq with mapcar... IDK, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj 3de700b057 154/185: Add a changelog, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj f5f7ec1660 173/185: Release v1.0.1, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj b34d3e13a2 156/185: Support eval #=(foo...) forms, ELPA Syncer, 2021/12/28
- [nongnu] elpa/parseclj d659079598 174/185: Remove the remaining a.el dependency from non-test code, ELPA Syncer, 2021/12/28