[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: call-next-method in CLOS



    Date: Fri, 29 Oct 1993 14:45 EDT
    From: haible@ma2s2.mathematik.uni-karlsruhe.de (Bruno Haible)
    Brian Dennis <xjam@ginkgo.CS.Berkeley.EDU> writes:
    > Any quick fixes and/or clarifications?
    Try this one:
    *** clue/shells.lsp%    Fri Oct 29 19:33:11 1993
    --- clue/shells.lsp     Fri Oct 29 19:33:11 1993
    ***************
    *** 127,135 ****
  
      (defmethod (setf contact-state) :around (new-state (shell override-shell))
	;; :iconic is equivalent to :withdrawn for override-shell
    !   (call-next-method
    !     (if (eq :iconic new-state) :withdrawn new-state)
    !     shell))
  
    --- 127,135 ----
  
      (defmethod (setf contact-state) :around (new-state (shell override-shell))
	;; :iconic is equivalent to :withdrawn for override-shell
    !   (if (eq :iconic new-state)
    !     ((setf contact-state) :withdrawn shell)
    !     (call-next-method)))
  
    One such a usage of CALL-NEXT-METHOD also appeared in the Apply2C compiler,
    and it could be patched away like this one. As long as no package
    really needs CALL-NEXT-METHOD with arguments, I won't implement it.
			Bruno Haible
			haible@ma2s2.mathematik.uni-karlsruhe.de

To be fair, you should point out that this changes the operation of
(setf contact-state) for override-shell, specifically for any subclass
of override-shell with daemon methods on (setf contact-state).
		- Pat