GNU bug report logs - #2681
23.0.91; incorrect line shown by lisp compiler

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Severity: minor; Reported by: Kenichi Handa <handa@HIDDEN>; merged with #8774, #9109, #22288, #24128, #24592; dated Mon, 16 Mar 2009 04:25:03 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.
Merged 2681 8774 9109 22288 24128 24592. Request was from npostavs@HIDDEN to control <at> debbugs.gnu.org. Full text available.
Disconnected #24449 from all other report(s). Request was from Glenn Morris <rgm@HIDDEN> to control <at> debbugs.gnu.org. Full text available.
Forcibly Merged 2681 8774 9109 22288 24128 24449. Request was from Glenn Morris <rgm@HIDDEN> to control <at> debbugs.gnu.org. Full text available.
Forcibly Merged 2681 8774 9109 22288 24449. Request was from Glenn Morris <rgm@HIDDEN> to control <at> debbugs.gnu.org. Full text available.
Merged 2681 8774 9109 22288. Request was from npostavs@HIDDEN to control <at> debbugs.gnu.org. Full text available.
Merged 2681 8774 22288. Request was from Noam Postavsky <npostavs@HIDDEN> to control <at> debbugs.gnu.org. Full text available.
bug Marked as found in versions 23.0.91. Request was from Noam Postavsky <npostavs@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 2681@HIDDEN:


Received: (at 2681) by emacsbugs.donarmstrong.com; 16 Mar 2009 10:03:58 +0000
From lekktu@HIDDEN Mon Mar 16 03:03:58 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: 
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=-3.0 required=4.0 tests=HAS_BUG_NUMBER autolearn=ham
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from nf-out-0910.google.com (nf-out-0910.google.com [64.233.182.185])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n2GA3tdl005366
	for <2681@HIDDEN>; Mon, 16 Mar 2009 03:03:56 -0700
Received: by nf-out-0910.google.com with SMTP id d3so755493nfc.31
        for <2681@HIDDEN>; Mon, 16 Mar 2009 03:03:54 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:mime-version:received:in-reply-to:references
         :date:message-id:subject:from:to:cc:content-type
         :content-transfer-encoding;
        bh=dqvJO3evXnSVgF4AvZmLhURF0VPHDbhen+dlvuQS7GY=;
        b=dGOK2M7nhnuj4z/F+OfRaUElfuZ/FSabDLvMf/q7U9nX9ZtuqHyxUKyuFBD7xIcekm
         L3So2DRywYsjIl33/0JsAsWH5cMhauN6qob7yDaxCGEYFayG0SU94GXTxIL875IuSOVR
         /bVjnnMgTsKzgbYLh1lLyxm47PcpfBYyHAg9o=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=mime-version:in-reply-to:references:date:message-id:subject:from:to
         :cc:content-type:content-transfer-encoding;
        b=q+vsz9sMHDFsXYyOSbCRBK9u3hED1JbYmVuBXlaKZW+rbBS8Z4bfFPRuw4UtaJHKtD
         EljG8pe+byvVl/94SrKiQNGciyVk+kFJ99Ix2zfDQaW/6FTB6prFmncBeYJUj0cBAUbJ
         mgYhYPl2n0TIgGG62xdzxWPA1bCl6US9xY6vs=
MIME-Version: 1.0
Received: by 10.210.113.16 with SMTP id l16mr3562187ebc.63.1237197834634; Mon, 
	16 Mar 2009 03:03:54 -0700 (PDT)
In-Reply-To: <E1Lj4Fg-0008JF-JP@etlken>
References: <E1Lj4Fg-0008JF-JP@etlken>
Date: Mon, 16 Mar 2009 11:03:54 +0100
Message-ID: <f7ccd24b0903160303i8cb13b0l5da0059a8eda9940@HIDDEN>
Subject: Re: bug#2681: 23.0.91; incorrect line shown by lisp compiler
From: Juanma Barranquero <lekktu@HIDDEN>
To: Kenichi Handa <handa@HIDDEN>
Cc: 2681 <at> debbugs.gnu.org
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit

On Mon, Mar 16, 2009 at 05:16, Kenichi Handa <handa@HIDDEN> wrote:

> In test:
> temp.el:4:11:Warning: `=' called with 1 arg, but requires 2
> temp.el:4:14:Warning: `length' called with 2 args, but requires 1
>
> But the bug is on 6th line, not the 4th line.

In a simpler test:

 (defun test (v)
   (or (= (length v 0))
       (= (length v) 1)))

produces

 test.el:2:8:Warning: `=' called with 1 arg, but requires 2
 test.el:3:11:Warning: `length' called with 2 args, but requires 1

but after changing the second `length'

 (defun test (v)
   (or (= (length v 0))
       (= (safe-length v) 1)))

the error output is correct:

 test.el:2:8:Warning: `=' called with 1 arg, but requires 2
 test.el:2:11:Warning: `length' called with 2 args, but requires 1

   Juanma




Acknowledgement sent to Juanma Barranquero <lekktu@HIDDEN>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs@HIDDEN>. Full text available.
Information forwarded to bug-submit-list@HIDDEN, Emacs Bugs <bug-gnu-emacs@HIDDEN>:
bug#2681; Package emacs. Full text available.

Message received at submit@HIDDEN:


Received: (at submit) by emacsbugs.donarmstrong.com; 16 Mar 2009 04:16:33 +0000
From handa@HIDDEN Sun Mar 15 21:16:32 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: 
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=0.0 required=4.0 tests=none autolearn=ham
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n2G4GTs1013235
	for <submit@HIDDEN>; Sun, 15 Mar 2009 21:16:31 -0700
Received: from mail.gnu.org ([199.232.76.166]:59435 helo=mx10.gnu.org)
	by fencepost.gnu.org with esmtp (Exim 4.67)
	(envelope-from <handa@HIDDEN>)
	id 1Lj4FY-0004HH-Ux
	for emacs-pretest-bug@HIDDEN; Mon, 16 Mar 2009 00:16:29 -0400
Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60)
	(envelope-from <handa@HIDDEN>)
	id 1Lj4FW-00083W-MT
	for emacs-pretest-bug@HIDDEN; Mon, 16 Mar 2009 00:16:27 -0400
Received: from mx1.aist.go.jp ([150.29.246.133]:43428)
	by monty-python.gnu.org with esmtp (Exim 4.60)
	(envelope-from <handa@HIDDEN>)
	id 1Lj4FW-00082i-38
	for emacs-pretest-bug@HIDDEN; Mon, 16 Mar 2009 00:16:26 -0400
Received: from rqsmtp1.aist.go.jp (rqsmtp1.aist.go.jp [150.29.254.115])
	by mx1.aist.go.jp  with ESMTP id n2G4GIUo029886
	for <emacs-pretest-bug@HIDDEN>; Mon, 16 Mar 2009 13:16:18 +0900 (JST)
	env-from (handa@HIDDEN)
Received: from smtp1.aist.go.jp
	by rqsmtp1.aist.go.jp  with ESMTP id n2G4GIrY015128
	for <emacs-pretest-bug@HIDDEN>; Mon, 16 Mar 2009 13:16:18 +0900 (JST)
	env-from (handa@HIDDEN)
Received: 
	by smtp1.aist.go.jp  with ESMTP id n2G4GHS2011975
	for <emacs-pretest-bug@HIDDEN>; Mon, 16 Mar 2009 13:16:17 +0900 (JST)
	env-from (handa@HIDDEN)
Received: from handa by etlken with local (Exim 4.69)
	(envelope-from <handa@HIDDEN>)
	id 1Lj4Fg-0008JF-JP
	for emacs-pretest-bug@HIDDEN; Mon, 16 Mar 2009 13:16:36 +0900
From: Kenichi Handa <handa@HIDDEN>
To: emacs-pretest-bug@HIDDEN
Subject: 23.0.91; incorrect line shown by lisp compiler
Message-Id: <E1Lj4Fg-0008JF-JP@etlken>
Date: Mon, 16 Mar 2009 13:16:36 +0900
X-detected-operating-system: by monty-python.gnu.org: Solaris 9

When I byte compile this file:
---~/temp.el------------------------------------------------
(defun test (vec)
  (cond	((= (length vec) 0)
	 (message "LEN=0"))
	((= (length vec) 1)
	 (message "LEN=1"))
	((= (length vec 2))
	 (message "LEN=2"))))
------------------------------------------------------------
The *Compile-Log* buffer shows these warnings:

Compiling file /home/handa/temp.el at Mon Mar 16 13:12:33 2009

In test:
temp.el:4:11:Warning: `=' called with 1 arg, but requires 2
temp.el:4:14:Warning: `length' called with 2 args, but requires 1

But the bug is on 6th line, not the 4th line.

---
Kenichi Handa
handa@HIDDEN




Acknowledgement sent to Kenichi Handa <handa@HIDDEN>:
New bug report received and forwarded. Copy sent to Emacs Bugs <bug-gnu-emacs@HIDDEN>. Full text available.
Report forwarded to bug-submit-list@HIDDEN, Emacs Bugs <bug-gnu-emacs@HIDDEN>:
bug#2681; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Wed, 5 Oct 2016 00:15:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.