From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: More over-engineering Date: Sat, 28 Nov 2015 11:22:01 -0500 Message-ID: References: <83si3rqp96.fsf@gnu.org> <83r3jbqluj.fsf@gnu.org> <83io4mr27s.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1448727752 9088 80.91.229.3 (28 Nov 2015 16:22:32 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 28 Nov 2015 16:22:32 +0000 (UTC) Cc: aurelien.aptel+emacs@gmail.com, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Nov 28 17:22:21 2015 Return-path: Envelope-to: ged-emacs-devel@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 1a2iGS-0004t7-Do for ged-emacs-devel@m.gmane.org; Sat, 28 Nov 2015 17:22:20 +0100 Original-Received: from localhost ([::1]:32964 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a2iGV-00074W-GH for ged-emacs-devel@m.gmane.org; Sat, 28 Nov 2015 11:22:23 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35146) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a2iGH-00074G-1r for emacs-devel@gnu.org; Sat, 28 Nov 2015 11:22:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a2iGG-0002zI-A4 for emacs-devel@gnu.org; Sat, 28 Nov 2015 11:22:09 -0500 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:50836) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a2iGC-0002yy-82; Sat, 28 Nov 2015 11:22:04 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A0A1FgA731xV/yr292hcgxCEAoVVwwsEAgKBPDwRAQEBAQEBAYEKQQWDXQEBBFYjEAs0EhQYDSSIP88jAQEBBwEBAQEeizqFBQeELQWMMKhUI4QWIIJ4AQEB X-IPAS-Result: A0A1FgA731xV/yr292hcgxCEAoVVwwsEAgKBPDwRAQEBAQEBAYEKQQWDXQEBBFYjEAs0EhQYDSSIP88jAQEBBwEBAQEeizqFBQeELQWMMKhUI4QWIIJ4AQEB X-IronPort-AV: E=Sophos;i="5.13,465,1427774400"; d="scan'208";a="179645941" Original-Received: from 104-247-246-42.cpe.teksavvy.com (HELO fmsmemgm.homelinux.net) ([104.247.246.42]) by ironport2-out.teksavvy.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 28 Nov 2015 11:22:02 -0500 Original-Received: by fmsmemgm.homelinux.net (Postfix, from userid 20848) id DAA3EAE07A; Sat, 28 Nov 2015 11:22:01 -0500 (EST) In-Reply-To: <83io4mr27s.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 28 Nov 2015 09:51:35 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.181 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:195464 Archived-At: >> >> How 'bout the other question: what happens if we don't use that macro? >> > I assumed that question was rhetorical. >> No, I'm really curious why all functions need to do that. > Because they want to catch all non-local exits. Those macros are the > implementation of what was discussed in the other thread all over. So it is not protecting something inside those functions, but rather just trying to hide the non-local exits from the caller? I can understand having a safe_funcall since that can be very useful when you don't know what the funcall will do (e.g. a hook), but for "primitives" where the set of possible non-local exits are well known, catching all non-local exits unconditionally seems hard to justify. It really seems like it would be saner to export the error catching functionality as a separate function and then let every module use it when it needs it. Stefan