From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lennart Borgman Newsgroups: gmane.emacs.devel Subject: Re: Errors in interactive commands Date: Wed, 3 Aug 2011 17:01:17 +0200 Message-ID: References: <87livbbta9.fsf@gmail.com> <4E38E70B.7030802@online.de> <87aabrhs2o.fsf@uwakimon.sk.tsukuba.ac.jp> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1312383708 22833 80.91.229.12 (3 Aug 2011 15:01:48 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 3 Aug 2011 15:01:48 +0000 (UTC) Cc: =?UTF-8?Q?Andreas_R=C3=B6hler?= , "Stephen J. Turnbull" , emacs-devel@gnu.org, Andreas Schwab , Antoine Levitt To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Aug 03 17:01:43 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Qocx4-0008Ns-Ca for ged-emacs-devel@m.gmane.org; Wed, 03 Aug 2011 17:01:42 +0200 Original-Received: from localhost ([::1]:58725 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qocx3-0002pr-U5 for ged-emacs-devel@m.gmane.org; Wed, 03 Aug 2011 11:01:41 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:37705) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qocx2-0002p3-0n for emacs-devel@gnu.org; Wed, 03 Aug 2011 11:01:40 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qocx0-0002PC-Fx for emacs-devel@gnu.org; Wed, 03 Aug 2011 11:01:39 -0400 Original-Received: from mail-ew0-f41.google.com ([209.85.215.41]:33308) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qocx0-0002MZ-BH for emacs-devel@gnu.org; Wed, 03 Aug 2011 11:01:38 -0400 Original-Received: by ewy9 with SMTP id 9so515178ewy.0 for ; Wed, 03 Aug 2011 08:01:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; bh=dpPV+kZr8UI/0RoWioQKc/osMML+4oOGmjtE/1EgOE0=; b=mRPx970tXp1jtmpvgtPBwMjrXt5U8v5JEd3SACm9Gd/lGENB1X9xOlPyMSa2NqIqiq teSDl1quEHEzqIOAHzvplE3eeB6T/m7KxzAMjkKbRfMtsXVk04VAU7ketco03Cec+U9I nk1NXnrv8kuiR7S30LopgmSmB1vJWR/n5SFBs= Original-Received: by 10.213.22.68 with SMTP id m4mr2398629ebb.125.1312383697202; Wed, 03 Aug 2011 08:01:37 -0700 (PDT) Original-Received: by 10.213.35.65 with HTTP; Wed, 3 Aug 2011 08:01:17 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.215.41 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:142818 Archived-At: On Wed, Aug 3, 2011 at 16:41, Stefan Monnier wro= te: >>> Examples such like this one is why I propose using something like >>> (throw 'command-level) instead of raising an error. >> How would that change anything, apart from breaking code that tries to >> catch the error? =C2=A0Raising an error throws to top-level by default >> anyway. > > Exactly. =C2=A0I think signalling errors is not a bad approach, tho it sh= ould > be improved to use `user-error' rather than just `error' for cases which > are normally associated with user errors (which are usually listed in > debug-ignored-errors). =C2=A0This way we won't need as many regexps in > debug-ignored-errors. My bad, I misremembered. Yes, changing the errors in commands called interactively to user-error is what we discussed. Is user-error implemented now? Should user-error be raised even when the commands are not called interactively? (Otherwise a macro handling this could perhaps be good.)