From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chong Yidong Newsgroups: gmane.emacs.devel Subject: Re: Nonsensical byte compiler warning. Date: Thu, 05 Apr 2007 14:01:07 -0400 Message-ID: <87bqi2bt0c.fsf@stupidchicken.com> References: <85ps6okoe5.fsf@lola.goethe.zz> <87lkhcj791.fsf@stupidchicken.com> <87tzvwvj6c.fsf@gmx.at> <861wj04qcq.fsf@lola.quinscape.zz> <873b3gpn4u.fsf@gmx.at> <86fy7g34tk.fsf@lola.quinscape.zz> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1175796001 20796 80.91.229.12 (5 Apr 2007 18:00:01 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 5 Apr 2007 18:00:01 +0000 (UTC) Cc: acm@muc.de, markus.triska@gmx.at, emacs-devel@gnu.org To: rms@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Apr 05 19:59:52 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HZWFT-00080l-B4 for ged-emacs-devel@m.gmane.org; Thu, 05 Apr 2007 19:59:51 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HZWIr-0001nF-Hm for ged-emacs-devel@m.gmane.org; Thu, 05 Apr 2007 14:03:21 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HZWIA-0001D0-Lc for emacs-devel@gnu.org; Thu, 05 Apr 2007 14:02:38 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HZWI9-0001BC-55 for emacs-devel@gnu.org; Thu, 05 Apr 2007 14:02:38 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HZWI9-0001Ar-0B for emacs-devel@gnu.org; Thu, 05 Apr 2007 14:02:37 -0400 Original-Received: from cyd.mit.edu ([18.19.1.138]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1HZWEi-0004r6-9X; Thu, 05 Apr 2007 13:59:04 -0400 Original-Received: by cyd.mit.edu (Postfix, from userid 1000) id 0A06E4E46E; Thu, 5 Apr 2007 14:01:08 -0400 (EDT) In-Reply-To: (Richard Stallman's message of "Thu\, 05 Apr 2007 02\:52\:45 -0400") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.97 (gnu/linux) X-detected-kernel: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:69090 Archived-At: Richard Stallman writes: > > The line number is that of the first form of the function the > > questionable code is in. That makes sense, since the problem is in > > that function. It is *not* the call of char-before that's bogus. It's > > that its return value isn't used in the caller, c-end-of-defun. Any > > line of that function could contain the oversight. What line number > > would in your view make more sense to report? > > The line number of the call to char-before, of course. The line > number of the whole enclosing function is plain useless. > > I agree. > > I don't know how hard it will be to make this useful line number > appear, but someone should investigate and _try_ to fix it. > Let's have no more of the argument that this is not a bug! After looking at this, I don't think it is practical to fix the line number. However, I changed the warning to print the entire form, which should make it much easier to figure out where the problematic code is (in this case, even if the form has been changed by previous optimizations, it shouldn't be too difficult to figure out what the original form was).