From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Phillip Lord Newsgroups: gmane.emacs.help Subject: Catching no generic method in EIEIO Date: Wed, 25 May 2016 17:03:07 +0100 Message-ID: <8760u2gm6c.fsf@russet.org.uk> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1464192242 10545 80.91.229.3 (25 May 2016 16:04:02 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 25 May 2016 16:04:02 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed May 25 18:03:52 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1b5bHj-0004cD-DJ for geh-help-gnu-emacs@m.gmane.org; Wed, 25 May 2016 18:03:51 +0200 Original-Received: from localhost ([::1]:33825 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5bHi-0002YJ-OE for geh-help-gnu-emacs@m.gmane.org; Wed, 25 May 2016 12:03:50 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48820) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5bH7-0002Wl-TL for help-gnu-emacs@gnu.org; Wed, 25 May 2016 12:03:14 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b5bH3-0001mq-Mq for help-gnu-emacs@gnu.org; Wed, 25 May 2016 12:03:12 -0400 Original-Received: from cloud103.planethippo.com ([31.216.48.48]:36620) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5bH3-0001mI-CX for help-gnu-emacs@gnu.org; Wed, 25 May 2016 12:03:09 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=russet.org.uk; s=default; h=Content-Type:MIME-Version:Message-ID:Date: Subject:To:From; bh=nK+DvO9yd3v5xnGvQ0vmbn1QqAJuF9mbxrbz8tW5Sf0=; b=AdStLpvEB 19b7s3miPy5RhSGoePobDNl6yczTSu7vFYOvVBVJAa1oOtEOlBmejCEjX0kuyZzhoB8MDi9MmSG6C D6eIB5Hch3h7fFU+qk0t0Txu9z6QxAnLaBjN/p02kqayewYnFhiD6xNHF4ifNPJ2a2fp1fCtwGY9n CEv0pToOaMX16QuMqjeuLzYS7pMBGrhvrvBa6IArVwACAi3kYvL+R9JPt7iR/mstSDeHSYsYvgzKY sd+zHc1qH5NJyoKHdHYyLlwTYk5kBR+ora9Z0x1EAwSu5JhH0+QFNgPChwtZgC+5bmgyGBTZqlXAM mDIjlb3dC2xJXIbtfrNhtvkNw==; Original-Received: from cpc1-benw10-2-0-cust373.gate.cable.virginm.net ([77.98.219.118]:37829 helo=russet.org.uk) by cloud103.planethippo.com with esmtpsa (TLSv1.2:DHE-RSA-AES128-SHA:128) (Exim 4.86_1) (envelope-from ) id 1b5bH2-0044x5-4a for help-gnu-emacs@gnu.org; Wed, 25 May 2016 17:03:08 +0100 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.94 (gnu/linux) X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - cloud103.planethippo.com X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - russet.org.uk X-Get-Message-Sender-Via: cloud103.planethippo.com: authenticated_id: phillip.lord@russet.org.uk X-Authenticated-Sender: cloud103.planethippo.com: phillip.lord@russet.org.uk X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 31.216.48.48 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:110110 Archived-At: Using EIEIO I can define a `slot-missing' method to catch "No Such Slot" errors for objects which do not have this slot. I've looked but as far as I can see, there is no ability to catch a missing implementation for a method. So: (defclass One()()) (defclass Two()()) (defmethod met((o One)) 'hello) (met (One)) (met (Two)) The last form crashes -- I could, of course, implement this using defmethod on Two, but I want to this for any method. Phil