From c120dbc73a0c7f17f6dab190544c0b43f56ec206 Mon Sep 17 00:00:00 2001 From: Andrea Corallo Date: Fri, 24 Apr 2020 19:23:34 +0100 Subject: [PATCH] * lisp/subr.el (subr-primitive-p): New inline function. --- lisp/subr.el | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lisp/subr.el b/lisp/subr.el index 006766587bc..1dd768c3a61 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -233,6 +233,11 @@ value of last one, or nil if there are none. (declare (indent 1) (debug t)) (cons 'if (cons cond (cons nil body)))) +(defsubst subr-primitive-p (object) + "Return t if OBJECT is a built-in primitive function." + (and (subrp object) + (not (subr-native-elisp-p object)))) + (defsubst xor (cond1 cond2) "Return the boolean exclusive-or of COND1 and COND2. If only one of the arguments is non-nil, return it; otherwise -- 2.39.5