From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stephen Berman Newsgroups: gmane.emacs.bugs Subject: bug#17482: args-out-of-range when visiting foo.todo Date: Fri, 23 May 2014 18:59:46 +0200 Message-ID: <87ppj4e8hp.fsf@rosalinde.fritz.box> References: <87zjilzn73.fsf@rosalinde.fritz.box> <87r43xz4ts.fsf@rosalinde.fritz.box> <87lhu4xup7.fsf@rosalinde.fritz.box> <87bnv0xhf3.fsf@rosalinde.fritz.box> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1400864486 9972 80.91.229.3 (23 May 2014 17:01:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 23 May 2014 17:01:26 +0000 (UTC) Cc: 17482@debbugs.gnu.org To: Glenn Morris Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri May 23 19:01:19 2014 Return-path: Envelope-to: geb-bug-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 1WnsqL-00005u-GF for geb-bug-gnu-emacs@m.gmane.org; Fri, 23 May 2014 19:01:17 +0200 Original-Received: from localhost ([::1]:44871 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WnsqL-00011F-4x for geb-bug-gnu-emacs@m.gmane.org; Fri, 23 May 2014 13:01:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54663) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WnsqC-00010s-Nd for bug-gnu-emacs@gnu.org; Fri, 23 May 2014 13:01:14 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Wnsq7-0001Gh-2M for bug-gnu-emacs@gnu.org; Fri, 23 May 2014 13:01:08 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:59207) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wnsq6-0001Gd-Vt for bug-gnu-emacs@gnu.org; Fri, 23 May 2014 13:01:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Wnsq6-0003Af-DQ for bug-gnu-emacs@gnu.org; Fri, 23 May 2014 13:01:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stephen Berman Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 23 May 2014 17:01:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 17482 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 17482-submit@debbugs.gnu.org id=B17482.140086441112058 (code B ref 17482); Fri, 23 May 2014 17:01:02 +0000 Original-Received: (at 17482) by debbugs.gnu.org; 23 May 2014 17:00:11 +0000 Original-Received: from localhost ([127.0.0.1]:58083 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WnspC-00038J-TZ for submit@debbugs.gnu.org; Fri, 23 May 2014 13:00:11 -0400 Original-Received: from mout.gmx.net ([212.227.15.15]:61557) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Wnsp6-000376-9k for 17482@debbugs.gnu.org; Fri, 23 May 2014 13:00:04 -0400 Original-Received: from rosalinde.fritz.box ([89.245.71.228]) by mail.gmx.com (mrgmx001) with ESMTPSA (Nemesis) id 0Lev1D-1X5pRQ1gsB-00qmDx; Fri, 23 May 2014 18:59:51 +0200 In-Reply-To: <87bnv0xhf3.fsf@rosalinde.fritz.box> (Stephen Berman's message of "Wed, 14 May 2014 21:57:04 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) X-Provags-ID: V03:K0:MTRr1TeauGtdNJD6fjnQdSXLnAI8rY9QbBJ/JYCCZXQ7uKv3tza UKu8f57uKqDWwnXnRBRH1gHOjbzBX/1F1StEAxM32qXUeA9LPXhntzbh6nGNtdWCvXHnLcf /djZxo6V1ZV4t9Eg2hlvmYIMEaAG3zuANyS2QY6H/cyZtMMcBspzOsfpEkbrjvLyKEGxKl9 N1gaQT+ekwrowtC8VZOzQ== X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:89402 Archived-At: On Wed, 14 May 2014 21:57:04 +0200 Stephen Berman wrote: > On Wed, 14 May 2014 13:46:33 -0400 Glenn Morris wrote: > >> Stefan Monnier wrote: >> >>> Maybe a quick way to "reach" the design goal is to wrap the body of >>> todo-mode in a `with-demoted-errors'. >> >> It's better, but I think it's still not great if I visit blah.todo and >> get "args-out-of-range" as a message rather than an error. > > I agree. Moreover, if blah.todo is not empty but not a valid Todo file, > visiting it will raise a different error from a different part of the > code, so it would be necessary to have multiple uses of > `with-demoted-errors'. And there's still the issue of why *.todo files > not in `todo-directory' should be in Todo mode. And the only sensible > answer is: they shouldn't be. So I am convinced that todo-mode should > not use auto-mode-alist: it's not needed and it only causes problems. I > somehow became blinded by the idea that it's nice to be able to visit a > todo-mode file with `find-file' or from Dired and have it be in > todo-mode and display properly, but this was just a mistake and now I've > seen the light. So unless there's a really good reason not to, I'll go > ahead and excise the use of auto-mode-alist; I'll post a patch for > review before committing. > > Steve Berman On Wed, 14 May 2014 22:24:41 -0400 Stefan Monnier wrote: >> Ok, I understand (that also answers a question I was tempted to ask you >> about why SES files don't violate your design goals). But I would >> consider this to be a new feature (which I still have doubts about), >> which could be considered for the trunk, but not for emacs-24. In >> contrast, the use of auto-mode-alist is a bug-inducing misfeature and >> should be removed before the release. > > Sounds OK. The required changes to remove the use of auto-mode-alist amount mainly to calling the appropriate Todo mode function when visting a Todo file, if it isn't already in that mode, so in view of Stefan's approval of the plan not to use auto-mode-alist here, I've refrained from posting the patch and simply committed it. Glenn, if you want to test and (hopefully) confirm that this bug is fixed, I'll wait for your response; otherwise, I'll take the liberty of closing it in a day or two. Besides fixing this bug, in the process of making and testing the changes I found a handful of other bugs, which I've already fixed in a separate changeset (bzr 117142 in emacs-24). Steve Berman