;;-*-mode:lisp;package:lambda-*- ;; (c) Copyright 1983 Lisp Machines, INC ;; ;; This is the minimal amount of LISP -> C translation needed ;; in order to run some diagnostics on the SDU. ;; 1/13/84 14:57:57 - George Carrette. ;; The lisp code must satisfy the following restrictions which I have ;; somewhat arbitrarily imposed for the purpose of this hack. ;; ;; (1) functions must take a fix number of arguments, and arguments ;; must (in C) be either strings or LONGS (32 bit quantities). ;; (2) the return value of a function must be a C int or LONG. ;; (3) If a function is to return a value it must be a PROG, and ;; use a RETURN statement. ;; (4) arguments to functions must be atomic or arithmetic expressions. ;; ;; Strings must have only ASCII printing characters in them, plus space, ;; and excluding doublequote. All integers will be translated as type LONG. ;; TO DO: Make sure this runs on TEST-DATA-PATH and FAST-ADDRESS-TEST-KERNAL ;; arguments long, a list of actors (replace with a string), ;; and a string for printing. ;; A switch for verbose output. ;; Command-line switch parsing and argument passing. (defmacro properties-for-c-translation (name description &body body) `(progn ,@(do ((l body (cddr l)) (v `((defprop ,name ,description c-properties-description)))) ((null l) (nreverse v)) (push `(defprop ,name ,(cadr l) ,(car l)) v)))) ;;(properties-for-c-translation foo "foo" ;; name-as-foo ...) ;; On the other hand, DEXTER says that these tests can be formalized ;; just like the UCODE ones. ;;(def-dp-test foo "who who who foo" ;; :read-function foo ;; :write-function bar ;; )