GNU bug report logs - #18321
24.4.50; EIEIO and (defmethod (setf ...))

Previous Next

Package: emacs;

Reported by: Tom Tromey <tom <at> tromey.com>

Date: Sun, 24 Aug 2014 05:10:02 UTC

Severity: wishlist

Found in version 24.4.50

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


Message #10 received at 18321-done <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Tom Tromey <tom <at> tromey.com>
Cc: 18321-done <at> debbugs.gnu.org
Subject: Re: bug#18321: 24.4.50; EIEIO and (defmethod (setf ...))
Date: Tue, 05 May 2015 14:33:25 -0400
> I was hoping this would work:
>
> (defclass hibob ()
>   ((click-callback :initform nil)
>    (icon :initform "" :accessor hibob-icon)))
>
> (defmethod (setf hibob-icon) :after (newval (obj hibob))
>   (setq zzzz newval))
>
> This works in Common Lisp and is quite handy.

IIUC this should now work if you use cl-defmethod.


        Stefan




This bug report was last modified 10 years and 103 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.