From unknown Sun Jun 15 08:42:58 2025 X-Loop: help-debbugs@gnu.org Subject: bug#61629: master: Sometimes M-x imenu throws an error when there's a single function in the buffer. Resent-From: Alan Mackenzie Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 Feb 2023 15:40:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 61629 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 61629@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.167682116111599 (code B ref -1); Sun, 19 Feb 2023 15:40:01 +0000 Received: (at submit) by debbugs.gnu.org; 19 Feb 2023 15:39:21 +0000 Received: from localhost ([127.0.0.1]:49504 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTlmb-000311-89 for submit@debbugs.gnu.org; Sun, 19 Feb 2023 10:39:21 -0500 Received: from lists.gnu.org ([209.51.188.17]:49542) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTlmZ-00030r-7A for submit@debbugs.gnu.org; Sun, 19 Feb 2023 10:39:19 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pTlmY-0002Hf-Pl for bug-gnu-emacs@gnu.org; Sun, 19 Feb 2023 10:39:18 -0500 Received: from mx3.muc.de ([193.149.48.5]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pTlmW-0008BD-UT for bug-gnu-emacs@gnu.org; Sun, 19 Feb 2023 10:39:18 -0500 Received: (qmail 68813 invoked by uid 3782); 19 Feb 2023 16:39:14 +0100 Received: from acm.muc.de (pd953a64b.dip0.t-ipconnect.de [217.83.166.75]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Sun, 19 Feb 2023 16:39:14 +0100 Received: (qmail 8798 invoked by uid 1000); 19 Feb 2023 15:39:13 -0000 Date: Sun, 19 Feb 2023 15:39:13 +0000 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Submission-Agent: TMDA/1.3.x (Ph3nix) From: Alan Mackenzie X-Primary-Address: acm@muc.de Received-SPF: pass client-ip=193.149.48.5; envelope-from=acm@muc.de; helo=mx3.muc.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.4 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) 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. This throws the error "Wrong type argument: seqencep, #". This is a bug. -- Alan Mackenzie (Nuremberg, Germany). From unknown Sun Jun 15 08:42:58 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Alan Mackenzie Subject: bug#61629: closed (Re: bug#61629: master: Sometimes M-x imenu throws an error when there's a single function in the buffer.) Message-ID: References: X-Gnu-PR-Message: they-closed 61629 X-Gnu-PR-Package: emacs Reply-To: 61629@debbugs.gnu.org Date: Sun, 19 Feb 2023 16:18:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1676823482-15671-1" This is a multi-part message in MIME format... ------------=_1676823482-15671-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #61629: master: Sometimes M-x imenu throws an error when there's a single f= unction in the buffer. which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 61629@debbugs.gnu.org. --=20 61629: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D61629 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1676823482-15671-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 61629-done) by debbugs.gnu.org; 19 Feb 2023 16:17:13 +0000 Received: from localhost ([127.0.0.1]:49552 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTmNE-00043X-Tu for submit@debbugs.gnu.org; Sun, 19 Feb 2023 11:17:13 -0500 Received: from mx3.muc.de ([193.149.48.5]:17080) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTmND-00043J-B5 for 61629-done@debbugs.gnu.org; Sun, 19 Feb 2023 11:17:11 -0500 Received: (qmail 96963 invoked by uid 3782); 19 Feb 2023 17:17:04 +0100 Received: from acm.muc.de (pd953a64b.dip0.t-ipconnect.de [217.83.166.75]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Sun, 19 Feb 2023 17:17:04 +0100 Received: (qmail 9577 invoked by uid 1000); 19 Feb 2023 16:17:03 -0000 Date: Sun, 19 Feb 2023 16:17:03 +0000 To: 61629-done@debbugs.gnu.org Subject: Re: bug#61629: master: Sometimes M-x imenu throws an error when there's a single function in the buffer. Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Submission-Agent: TMDA/1.3.x (Ph3nix) From: Alan Mackenzie X-Primary-Address: acm@muc.de X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 61629-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) 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. > This throws the error "Wrong type argument: seqencep, # graziosi.cc>". This is a bug. -- Alan Mackenzie (Nuremberg, Germany). ------------=_1676823482-15671-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 19 Feb 2023 15:39:21 +0000 Received: from localhost ([127.0.0.1]:49504 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTlmb-000311-89 for submit@debbugs.gnu.org; Sun, 19 Feb 2023 10:39:21 -0500 Received: from lists.gnu.org ([209.51.188.17]:49542) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTlmZ-00030r-7A for submit@debbugs.gnu.org; Sun, 19 Feb 2023 10:39:19 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pTlmY-0002Hf-Pl for bug-gnu-emacs@gnu.org; Sun, 19 Feb 2023 10:39:18 -0500 Received: from mx3.muc.de ([193.149.48.5]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pTlmW-0008BD-UT for bug-gnu-emacs@gnu.org; Sun, 19 Feb 2023 10:39:18 -0500 Received: (qmail 68813 invoked by uid 3782); 19 Feb 2023 16:39:14 +0100 Received: from acm.muc.de (pd953a64b.dip0.t-ipconnect.de [217.83.166.75]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Sun, 19 Feb 2023 16:39:14 +0100 Received: (qmail 8798 invoked by uid 1000); 19 Feb 2023 15:39:13 -0000 Date: Sun, 19 Feb 2023 15:39:13 +0000 To: bug-gnu-emacs@gnu.org Subject: master: Sometimes M-x imenu throws an error when there's a single function in the buffer. Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Submission-Agent: TMDA/1.3.x (Ph3nix) From: Alan Mackenzie X-Primary-Address: acm@muc.de Received-SPF: pass client-ip=193.149.48.5; envelope-from=acm@muc.de; helo=mx3.muc.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.4 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) 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. This throws the error "Wrong type argument: seqencep, #". This is a bug. -- Alan Mackenzie (Nuremberg, Germany). ------------=_1676823482-15671-1-- From unknown Sun Jun 15 08:42:58 2025 X-Loop: help-debbugs@gnu.org Subject: bug#61629: master: Sometimes M-x imenu throws an error when there's a single function in the buffer. Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 Feb 2023 17:51:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61629 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 61629@debbugs.gnu.org, acm@muc.de Received: via spool by 61629-submit@debbugs.gnu.org id=B61629.167682901925964 (code B ref 61629); Sun, 19 Feb 2023 17:51:02 +0000 Received: (at 61629) by debbugs.gnu.org; 19 Feb 2023 17:50:19 +0000 Received: from localhost ([127.0.0.1]:49618 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTnpL-0006ki-0H for submit@debbugs.gnu.org; Sun, 19 Feb 2023 12:50:19 -0500 Received: from mail-wm1-f54.google.com ([209.85.128.54]:44612) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTnpJ-0006kL-0F for 61629@debbugs.gnu.org; Sun, 19 Feb 2023 12:50:17 -0500 Received: by mail-wm1-f54.google.com with SMTP id o9-20020a05600c510900b003ddca7a2bcbso711819wms.3 for <61629@debbugs.gnu.org>; Sun, 19 Feb 2023 09:50:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :sender:from:to:cc:subject:date:message-id:reply-to; bh=IEB0aTx+0SQBRXw+vJTK+7i2cE85z+ElwPqcjDXwkvU=; b=S7bd/OnjHpKCkbWbP0jI0i1qojpGtsOiewor8nFD4dcuWCjKH2pUlipCQOBp3ngWSQ zY28k6iQuHRJAgFn7t+qIkdbvI/ctuoTGm9PVEG/3f8Xd9swH+i6hC/0yWx1+xtdZUw5 2bF7QS/seHKcazl84EduWDdHrJCfQgUIKSebpdGO03H/s36u8LC4ycp68L5lxEk1Qd/s 1+CgKue5n84RgJ9ReZkiFmBiVl3WCajYHunWn/q62oRx3w4nypSrpsr7i2CwtXJI9cju 5uqIxJuzA76jZpRph8MXk2i1AXhf+/2eXN9RraZ7Qyt3uRFGIbrmCAWOZk2DUBjLfn17 35Fg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :sender:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=IEB0aTx+0SQBRXw+vJTK+7i2cE85z+ElwPqcjDXwkvU=; b=c2a9N3fn2Ww2YOh6BMjHdLZ8ZFtcF+k4ntX23onbAlGjEy6CYtrUDYSWf8uTTqbV/5 GuJH5whSN+8WrQVZ8OGC9MJc83BNXwIfcxhH/sLENxT+eztlgFtLGXMA7wXKcAtJ8rt5 zi3odc7VCST2G4R8O49pyfu4IPJ8HZUfENEndzVgaznm7esTyiqiskmWY1hSTZJl0S0k OIhoZwWMnDBOfMY59EpZAsN0X5YRWYIzM5bLB8b4liGu+66vmng9a2yIjFL5TnuLQQu+ HZSNrU79b29kwvUvgsQV5NfqDht6jCMMyPUDXfAlxM1PzYa1bfoBKdmtLTeRKlHYwLnh ljiA== X-Gm-Message-State: AO0yUKUkignxfZ4bnLaAnrKLMQU1eRfeGanKot0QwbXJyVjwh+Sb2qd/ qkDqYCQvaz8BcuI6aPuh2dOzMYQNisQ= X-Google-Smtp-Source: AK7set84ymdv3fUri14ZScoaDrcHc+JjK6SwFwNUHXphMJVduFUKEOOjVe9cNjUY/1eIQbQaum4FpQ== X-Received: by 2002:a05:600c:21d6:b0:3d0:6a57:66a5 with SMTP id x22-20020a05600c21d600b003d06a5766a5mr5593646wmj.0.1676829010933; Sun, 19 Feb 2023 09:50:10 -0800 (PST) Received: from [192.168.0.2] ([46.251.119.176]) by smtp.googlemail.com with ESMTPSA id q12-20020a7bce8c000000b003db0ee277b2sm8059120wmj.5.2023.02.19.09.50.09 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 19 Feb 2023 09:50:10 -0800 (PST) Message-ID: <7f184419-0053-2f80-f413-8a2bf17e656e@yandex.ru> Date: Sun, 19 Feb 2023 19:50:08 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2 Content-Language: en-US References: From: Dmitry Gutov In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -0.9 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.9 (-) On 19/02/2023 18:17, Alan Mackenzie wrote: > Bug fixed in master. Thanks, Alan!