GNU bug report logs - #61629
master: Sometimes M-x imenu throws an error when there's a single function in the buffer.

Previous Next

Package: emacs;

Reported by: Alan Mackenzie <acm <at> muc.de>

Date: Sun, 19 Feb 2023 15:40:01 UTC

Severity: normal

Done: Alan Mackenzie <acm <at> muc.de>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 61629 in the body.
You can then email your comments to 61629 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#61629; Package emacs. (Sun, 19 Feb 2023 15:40:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Alan Mackenzie <acm <at> muc.de>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sun, 19 Feb 2023 15:40:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Alan Mackenzie <acm <at> muc.de>
To: bug-gnu-emacs <at> gnu.org
Subject: master: Sometimes M-x imenu throws an error when there's a single
 function in the buffer.
Date: Sun, 19 Feb 2023 15:39:13 +0000
Hello, Emacs.

On the master branch, the recipe below leads to an error being thrown
from imenu.

Awareness of this bug resulted from the thread Subject: Error in C++
Mode with Emacs 27.0.90, Date: Tue 24 Mar 2020, From: Angelo Graziosi.
This thread reported a bug in imenu, which never made it to debbugs, but
which was partially fixed.

Thanks to Dmitry Gutov, who made me aware of the bit that didn't get
fixed then.

To reproduce the error in the master branch:
(i) emacs -Q in a GUI environment.
(ii) Evaluate the following:

;; C/C++ modes
(defun my-c-mode ()
  "My customization for `c-mode' and `c++-mode'."
  ;; Add index of func. to menu bar
  (imenu-add-to-menubar "Functions"))

;; c++-mode
(add-hook 'c-mode-common-hook 'my-c-mode)

(setq imenu-auto-rescan t)
(setq imenu-use-popup-menu t)

(iii) Type the following into an empty C++ buffer called graziosi.cc:

int main ()
{
    return 0;
}

(iv) M-x imenu<RET>.

This throws the error "Wrong type argument: seqencep, #<marker at 1 in
graziosi.cc>".  This is a bug.

-- 
Alan Mackenzie (Nuremberg, Germany).




Reply sent to Alan Mackenzie <acm <at> muc.de>:
You have taken responsibility. (Sun, 19 Feb 2023 16:18:02 GMT) Full text and rfc822 format available.

Notification sent to Alan Mackenzie <acm <at> muc.de>:
bug acknowledged by developer. (Sun, 19 Feb 2023 16:18:02 GMT) Full text and rfc822 format available.

Message #10 received at 61629-done <at> debbugs.gnu.org (full text, mbox):

From: Alan Mackenzie <acm <at> muc.de>
To: 61629-done <at> debbugs.gnu.org
Subject: Re: bug#61629: master: Sometimes M-x imenu throws an error when
 there's a single function in the buffer.
Date: Sun, 19 Feb 2023 16:17:03 +0000
Bug fixed in master.

On Sun, Feb 19, 2023 at 15:39:13 +0000, Alan Mackenzie wrote:
> On the master branch, the recipe below leads to an error being thrown
> from imenu.

> Awareness of this bug resulted from the thread Subject: Error in C++
> Mode with Emacs 27.0.90, Date: Tue 24 Mar 2020, From: Angelo Graziosi.
> This thread reported a bug in imenu, which never made it to debbugs, but
> which was partially fixed.

> Thanks to Dmitry Gutov, who made me aware of the bit that didn't get
> fixed then.

> To reproduce the error in the master branch:
> (i) emacs -Q in a GUI environment.
> (ii) Evaluate the following:

> ;; C/C++ modes
> (defun my-c-mode ()
>   "My customization for `c-mode' and `c++-mode'."
>   ;; Add index of func. to menu bar
>   (imenu-add-to-menubar "Functions"))

> ;; c++-mode
> (add-hook 'c-mode-common-hook 'my-c-mode)

> (setq imenu-auto-rescan t)
> (setq imenu-use-popup-menu t)

> (iii) Type the following into an empty C++ buffer called graziosi.cc:

> int main ()
> {
>     return 0;
> }

> (iv) M-x imenu<RET>.

> This throws the error "Wrong type argument: seqencep, #<marker at 1 in
> graziosi.cc>".  This is a bug.

-- 
Alan Mackenzie (Nuremberg, Germany).






Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#61629; Package emacs. (Sun, 19 Feb 2023 17:51:02 GMT) Full text and rfc822 format available.

Message #13 received at 61629 <at> debbugs.gnu.org (full text, mbox):

From: Dmitry Gutov <dgutov <at> yandex.ru>
To: 61629 <at> debbugs.gnu.org, acm <at> muc.de
Subject: Re: bug#61629: master: Sometimes M-x imenu throws an error when
 there's a single function in the buffer.
Date: Sun, 19 Feb 2023 19:50:08 +0200
On 19/02/2023 18:17, Alan Mackenzie wrote:
> Bug fixed in master.

Thanks, Alan!




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 20 Mar 2023 11:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 87 days ago.

Previous Next


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