From 7dcf04ad1295e4c19d0ad48b1b8cc4533cb8dd1e Mon Sep 17 00:00:00 2001 From: Mark Wooding Date: Sun, 30 Apr 2006 13:29:58 +0100 Subject: [PATCH] base: Provide fixnump function. CMU CL already implements fixnump in the extensions package Provide it explicitly here anyway, for other implementations. Quite why this function isn't in the Common Lisp spec anyway is still a mystery. --- mdw-base.lisp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/mdw-base.lisp b/mdw-base.lisp index 269b398..0b68b8d 100644 --- a/mdw-base.lisp +++ b/mdw-base.lisp @@ -37,7 +37,10 @@ #:with-gensyms #:let*/gensyms #:with-places #:locp #:locf #:ref #:with-locatives #:update-place #:update-place-after - #:incf-after #:decf-after)) + #:incf-after #:decf-after + #:fixnump) + #+cmu (:import-from #:extensions #:fixnump)) + (in-package #:mdw.base) ;;;-------------------------------------------------------------------------- @@ -124,6 +127,13 @@ (and decls (list (cons 'declare decls))) forms)))))))) +#-cmu +(progn + (declaim (inline fixnump)) + (defun fixnump (object) + "Answer non-nil if OBJECT is a fixnum, or nil if it isn't." + (typep object 'fixnum))) + ;;;-------------------------------------------------------------------------- ;;; Generating symbols. -- 2.11.0