From 565055e95cdf51f597d8e5b794e2b46efe36d854 Mon Sep 17 00:00:00 2001 From: "Basil L. Contovounesios" Date: Sat, 9 Jan 2021 20:58:51 +0000 Subject: [PATCH] * dash.el (---truthy?): Simplify. --- dash.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dash.el b/dash.el index 0097b42..0251288 100644 --- a/dash.el +++ b/dash.el @@ -860,9 +860,10 @@ See also: `-last-item'." "Counts the number of items in LIST where (PRED item) is non-nil." (--count (funcall pred it) list)) -(defun ---truthy? (val) +(defun ---truthy? (obj) + "Return OBJ as a boolean value (t or nil)." (declare (pure t) (side-effect-free t)) - (not (null val))) + (and obj t)) (defmacro --any? (form list) "Anaphoric form of `-any?'."