From 920b3c2591a686a5aa45f8265d34fa71a97f9f9c Mon Sep 17 00:00:00 2001 From: Stelian Ionescu Date: Tue, 25 Jan 2011 23:21:32 +0100 Subject: [PATCH] Add type BOOLEAN and its constructor to IOLIB.CL --- src/iolib.base.asd | 3 ++- src/new-cl/pkgdcl.lisp | 5 +++-- src/new-cl/types.lisp | 12 ++++++++++++ 3 files changed, 17 insertions(+), 3 deletions(-) create mode 100644 src/new-cl/types.lisp diff --git a/src/iolib.base.asd b/src/iolib.base.asd index 8e3bdf3..99b3bf8 100644 --- a/src/iolib.base.asd +++ b/src/iolib.base.asd @@ -18,7 +18,8 @@ (:file "pkgdcl" :depends-on ("conduits" #+scl "scl-gray-streams")) (:file "gray-streams" :depends-on ("pkgdcl" #+scl "scl-gray-streams")) - (:file "definitions" :depends-on ("pkgdcl"))) + (:file "definitions" :depends-on ("pkgdcl")) + (:file "types" :depends-on ("pkgdcl"))) :perform (asdf:compile-op :before (o c) (funcall (find-symbol (string '#:load-gray-streams) :iolib.conf))) diff --git a/src/new-cl/pkgdcl.lisp b/src/new-cl/pkgdcl.lisp index 292b58b..4816850 100644 --- a/src/new-cl/pkgdcl.lisp +++ b/src/new-cl/pkgdcl.lisp @@ -32,8 +32,9 @@ (:extend/excluding :common-lisp #:export #:unexport #:defpackage #:delete-package #:rename-package - #:defconstant) - (:export #:defconstant) + #:defconstant + #:boolean) + (:export #:defconstant #:boolean) (:extend/excluding :iolib.internal.conduits #:recompute-conduits) (:import-from ,#1# ,@#2#) diff --git a/src/new-cl/types.lisp b/src/new-cl/types.lisp new file mode 100644 index 0000000..988ce9c --- /dev/null +++ b/src/new-cl/types.lisp @@ -0,0 +1,12 @@ +;;;; -*- Mode: Lisp; indent-tabs-mode: nil -*- +;;; +;;; --- Type definitions and constructors +;;; + +(in-package :iolib.common-lisp) + +(deftype boolean () + 'cl:boolean) + +(defun boolean (x) + (if x t nil)) -- 2.11.4.GIT