[slime-devel] MOP problem with clisp
Thomas Schilling
tjs_ng at yahoo.de
Tue Sep 14 23:58:43 UTC 2004
Am Tue, 14 Sep 2004 19:50:24 +0200 schrieb Reini Urban <rurban at x-ray.at>:
> Thomas Schilling schrieb:
>> Reini Urban <rurban at x-ray.at> wrote:
>>> earlier slime's didn't have this problem.
>> Yes, that's due to the new inspector having not (yet) the CLISP
>> backend support. I already started working on it. I hope I can finish
>> it until tonight.
>> Anyway, if someone is already working at it please drop me a note to
>> avoid doing it twice.
>
> Okay, I'll wait then.
I think you unfortunately have to wait a little longer.
With this patch clisp at least starts up again though the inspector is not
yet usable. You maybe need to load it twice, I guess I had to put some
eval-when somewhere. But I need to sleep some time ... so HTH so far
*headsmashingagainstdeskwhileindexfingerpushesthemousebuttontosendthismail*
bye (*nooneknowswhichghostyhandwrotethis*)
,--- the patch: ---
Index: swank-clisp.lisp
===================================================================
RCS file: /project/slime/cvsroot/slime/swank-clisp.lisp,v
retrieving revision 1.34
diff -u -r1.34 swank-clisp.lisp
--- swank-clisp.lisp 28 Aug 2004 02:27:08 -0000 1.34
+++ swank-clisp.lisp 14 Sep 2004 23:54:07 -0000
@@ -32,6 +32,99 @@
(when (find-package "LINUX")
(pushnew :linux *features*)))
+(defun import-to-swank-mop (sym/sym-list)
+ (if (listp sym/sym-list)
+ (dolist (sym sym/sym-list)
+ (import-to-swank-mop sym))
+ (let* ((sym sym/sym-list)
+ (swank-mop-sym (find-symbol (symbol-name sym) :swank-mop)))
+ ;; 1) "delete" the symbol form the :swank-mop package
+ (when swank-mop-sym
+ (unintern swank-mop-sym :swank-mop))
+ (import sym :swank-mop)
+ (export sym :swank-mop))))
+
+(import-to-swank-mop
+ '(;; classes
+ cl:standard-generic-function
+ clos::standard-slot-definition
+ cl:method
+ cl:standard-class
+ ;; standard-class readers
+ clos::class-default-initargs
+ clos::class-direct-default-initargs
+ clos::class-direct-slots
+ clos::class-direct-subclasses
+ clos::class-direct-superclasses
+ clos:class-finalized-p
+ cl:class-name
+ clos::class-precedence-list
+ clos::class-prototype
+ clos::class-slots
+ ;; generic function readers
+ ;; DIFFERENT NAMES - implemented delegating methods below
+; clos:generic-function-argument-precedence-order
+; clos:generic-function-declarations
+; clos:generic-function-lambda-list
+; clos:generic-function-methods
+; clos:generic-function-method-class
+; clos:generic-function-method-combination
+; clos:generic-function-name
+ ;; method readers
+; clos::method-generic-function
+; clos::method-function
+; clos::method-lambda-list
+; clos::method-specializers
+; clos::method-qualifiers
+ ;; slot readers
+; clos::slot-definition-allocation
+; clos::slot-definition-initargs
+; clos::slot-definition-initform
+; clos::slot-definition-initfunction
+; clos::slot-definition-name
+; clos::slot-definition-type
+; clos::slot-definition-readers
+; clos::slot-definition-writers
+ ))
+
+(defun swank-mop:slot-definition-documentation (slot)
+ (clos::documentation slot t))
+
+(defmacro define-delegations (arglist &body from/to-pairs)
+ "Create simple wrappers for the specified functions. The pairs are from
of the
+form: (WRAPPER-NAME ACTUAL-FUNCTION). ARGLIST is the will be used as each
+function's arglist"
+ `(progn
+ ,@(mapcar (lambda (pair) `(defun ,(first pair) ,arglist (,(second
pair) , at arglist))) from/to-pairs)))
+
+(define-delegations (gf)
+ (swank-mop:generic-function-argument-precedence-order clos::gf-argorder)
+; (swank-mop:generic-function-declarations clos::gf-declarations)
+; (swank-mop:generic-function-lambda-list clos::gf-lambda-list)
+ (swank-mop:generic-function-methods clos::gf-methods)
+; (swank-mop:generic-function-method-class clos::gf-method-class)
+ (swank-mop:generic-function-method-combination
clos::gf-method-combination)
+; (swank-mop:generic-function-name clos::gf-name)
+ )
+
+(define-delegations (method)
+ (swank-mop:method-generic-function clos::std-method-gf)
+ (swank-mop:method-function clos::std-method-function)
+; (swank-mop:method-lambda-list clos::std-method-lambda-list)
+ (swank-mop:method-specializers clos::std-method-parameter-specializers)
+ (swank-mop:method-qualifiers clos::std-method-qualifiers))
+
+(define-delegations (slot-def)
+ (swank-mop:slot-definition-allocation clos::slotdef-allocation)
+ (swank-mop:slot-definition-initargs clos::slotdef-initargs)
+; (swank-mop:slot-definition-initform clos::slotdef-initform)
+ (swank-mop:slot-definition-initfunction clos::slotdef-initer)
+ (swank-mop:slot-definition-name clos::slotdef-name)
+; (swank-mop:slot-definition-type clos::slotdef-type)
+; (swank-mop:slot-definition-readers clos::slotdef-readers)
+; (swank-mop:slot-definition-writers clos::slotdef-writers)
+ )
+
#+linux
(defmacro with-blocked-signals ((&rest signals) &body body)
(ext:with-g
More information about the slime-devel
mailing list