Skip to content

Commit abe972a

Browse files
yuhan0bbatsov
authored andcommitted
Inline nrepl-dict predicates
1 parent 9db0cee commit abe972a

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

nrepl-dict.el

+3-4
Original file line numberDiff line numberDiff line change
@@ -45,12 +45,11 @@
4545
(maphash (lambda (k v) (nrepl-dict-put dict k v)) hash)
4646
dict))
4747

48-
(defun nrepl-dict-p (object)
48+
(defsubst nrepl-dict-p (object)
4949
"Return t if OBJECT is an nREPL dict."
50-
(and (listp object)
51-
(eq (car object) 'dict)))
50+
(eq (car-safe object) 'dict))
5251

53-
(defun nrepl-dict-empty-p (dict)
52+
(defsubst nrepl-dict-empty-p (dict)
5453
"Return t if nREPL dict DICT is empty."
5554
(null (cdr dict)))
5655

0 commit comments

Comments
 (0)