[movitz-cvs] CVS update: movitz/losp/muerte/basic-macros.lisp

Frode Vatvedt Fjeld ffjeld at common-lisp.net
Sat Aug 20 20:25:09 UTC 2005


Update of /project/movitz/cvsroot/movitz/losp/muerte
In directory common-lisp.net:/tmp/cvs-serv26092

Modified Files:
	basic-macros.lisp 
Log Message:
Added macro check-the, which combindes 'the' and 'check-type'.

Date: Sat Aug 20 22:25:09 2005
Author: ffjeld

Index: movitz/losp/muerte/basic-macros.lisp
diff -u movitz/losp/muerte/basic-macros.lisp:1.62 movitz/losp/muerte/basic-macros.lisp:1.63
--- movitz/losp/muerte/basic-macros.lisp:1.62	Sun Aug 14 18:39:39 2005
+++ movitz/losp/muerte/basic-macros.lisp	Sat Aug 20 22:25:09 2005
@@ -9,7 +9,7 @@
 ;;;; Created at:    Wed Nov  8 18:44:57 2000
 ;;;; Distribution:  See the accompanying file COPYING.
 ;;;;                
-;;;; $Id: basic-macros.lisp,v 1.62 2005/08/14 16:39:39 ffjeld Exp $
+;;;; $Id: basic-macros.lisp,v 1.63 2005/08/20 20:25:09 ffjeld Exp $
 ;;;;                
 ;;;;------------------------------------------------------------------
 
@@ -1193,6 +1193,11 @@
 
 (define-compiler-macro sti ()
   `(with-inline-assembly (:returns :nothing) (:sti)))
+
+
+(defmacro check-the (type form)
+  (let ((x (gensym "check-the-")))
+    `(the ,type (let ((,x ,form)) (check-type ,x ,type) ,x))))
 
 (require :muerte/setf)
 




More information about the Movitz-cvs mailing list