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

Frode Vatvedt Fjeld ffjeld at common-lisp.net
Mon Oct 11 13:52:19 UTC 2004


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

Modified Files:
	basic-macros.lisp 
Log Message:
Changed the signature of memref and (setf memref) to use keywords also
for the index and type arguments.

Date: Mon Oct 11 15:52:18 2004
Author: ffjeld

Index: movitz/losp/muerte/basic-macros.lisp
diff -u movitz/losp/muerte/basic-macros.lisp:1.41 movitz/losp/muerte/basic-macros.lisp:1.42
--- movitz/losp/muerte/basic-macros.lisp:1.41	Wed Sep 22 18:26:14 2004
+++ movitz/losp/muerte/basic-macros.lisp	Mon Oct 11 15:52:18 2004
@@ -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.41 2004/09/22 16:26:14 ffjeld Exp $
+;;;; $Id: basic-macros.lisp,v 1.42 2004/10/11 13:52:18 ffjeld Exp $
 ;;;;                
 ;;;;------------------------------------------------------------------
 
@@ -391,6 +391,13 @@
 				       (find-symbol (string slot-name) :movitz))))
      (:leal ((:ecx #.movitz::+movitz-fixnum-factor+) :edi ,(- (movitz::image-nil-word movitz::*image*)))
 	    :eax)))
+
+(define-compiler-macro movitz-type-slot-offset (type slot &environment env)
+  (if (not (and (movitz:movitz-constantp type env)
+		(movitz:movitz-constantp slot env)))
+      (error "Non-constant movitz-type-slot-offset call.")
+    (bt:slot-offset (intern (symbol-name (movitz:movitz-eval type env)) :movitz)
+		    (intern (symbol-name (movitz:movitz-eval slot env)) :movitz))))
 
 
 (define-compiler-macro not (x)





More information about the Movitz-cvs mailing list