Article View: comp.lang.clos
Article #85no-applicable-method
From: Mohammed M. Hakim
Date: Thu, 16 Apr 1992 00:43
Date: Thu, 16 Apr 1992 00:43
24 lines
1259 bytes
1259 bytes
Suppose I want to write a no-applicable-method that can be used to delegate messages to an object's prototype, I'll have something that looks like this: (defclass foo () ((prototype))) (defmethod no-applicable-method ((gf standard-generic-function) &rest args) (let ((prototype (prototype (first args)))) (if prototype (apply gf prototype (cdr args)) (call-next-method)))) This seems to work fine. However, it blows up when it is used with a writer method (setf . .), because for (setf . .) the first argument in &rest passed to no-applicable-method is the value of the slot not the object instance. Is there a better way to do this. Also, how can I do this for multiple qualified arguments? Maher Hakim Carnegie Mellon University
Technical Details
Message-ID:
<odvAqcy00iQQRD=Fo6@andrew.cmu.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!spool.mu.edu!yale.edu!jvnc.net!rutgers!rochester!cantaloupe.srv.cs.cmu.edu!crabapple.srv.cs.cmu.edu!andrew.cmu.edu!mh5l+Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!spool.mu.edu!yale.edu!jvnc.net!rutgers!rochester!cantaloupe.srv.cs.cmu.edu!crabapple.srv.cs.cmu.edu!andrew.cmu.edu!mh5l+ From: mh5l+@andrew.cmu.edu (Mohammed M. Hakim) Newsgroups: comp.lang.clos Subject: no-applicable-method Message-ID: <odvAqcy00iQQRD=Fo6@andrew.cmu.edu> Date: 16 Apr 92 00:43:20 GMT Article-I.D.: andrew.odvAqcy00iQQRD=Fo6 Organization: Doctoral student, Civil Engineering, Carnegie Mellon, Pittsburgh, PA Lines: 24