From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcin Borkowski Subject: Is this (error (error ...)) form intentional? Date: Sat, 19 Mar 2016 11:28:12 +0100 Message-ID: <8737rmg3sz.fsf@mbork.pl> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:33978) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahE7N-0004hD-EH for emacs-orgmode@gnu.org; Sat, 19 Mar 2016 06:28:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ahE7K-0006rV-9G for emacs-orgmode@gnu.org; Sat, 19 Mar 2016 06:28:25 -0400 Received: from mail.mojserwer.eu ([2a01:5e00:2:52::8]:46902) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahE7K-0006rO-1q for emacs-orgmode@gnu.org; Sat, 19 Mar 2016 06:28:22 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.mojserwer.eu (Postfix) with ESMTP id C3B08A2A4AF for ; Sat, 19 Mar 2016 11:28:19 +0100 (CET) Received: from mail.mojserwer.eu ([127.0.0.1]) by localhost (mail.mojserwer.eu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Km+GdurY3UFL for ; Sat, 19 Mar 2016 11:28:16 +0100 (CET) Received: from localhost (125-38.echostar.pl [213.156.125.38]) by mail.mojserwer.eu (Postfix) with ESMTPSA id 47571A2A4AB for ; Sat, 19 Mar 2016 11:28:16 +0100 (CET) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Org-Mode mailing list >From org.el: --8<---------------cut here---------------start------------->8--- (defun org-back-to-heading (&optional invisible-ok) "Call `outline-back-to-heading', but provide a better error message." (condition-case nil (outline-back-to-heading invisible-ok) (error (error "Before first headline at position %d in buffer %s" (point) (current-buffer))))) --8<---------------cut here---------------end--------------->8--- Frankly, I don't see the point of nesting `error'. Best, -- Marcin Borkowski http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski Faculty of Mathematics and Computer Science Adam Mickiewicz University