From unknown Sun Aug 17 10:17:06 2025 X-Loop: help-debbugs@gnu.org Subject: bug#69720: 29.2; `shortdoc-copy-function-as-kill' copies the ')' for some functions Resent-From: Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 11 Mar 2024 02:47:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 69720 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 69720@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.171012517920577 (code B ref -1); Mon, 11 Mar 2024 02:47:01 +0000 Received: (at submit) by debbugs.gnu.org; 11 Mar 2024 02:46:19 +0000 Received: from localhost ([127.0.0.1]:38221 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rjVgA-0005Lm-Bg for submit@debbugs.gnu.org; Sun, 10 Mar 2024 22:46:19 -0400 Received: from lists.gnu.org ([209.51.188.17]:50768) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rjODz-0001Zg-3V for submit@debbugs.gnu.org; Sun, 10 Mar 2024 14:48:52 -0400 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 1rjODH-0000BN-9g for bug-gnu-emacs@gnu.org; Sun, 10 Mar 2024 14:48:00 -0400 Received: from mail-qt1-x82c.google.com ([2607:f8b0:4864:20::82c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rjODF-00058I-NV for bug-gnu-emacs@gnu.org; Sun, 10 Mar 2024 14:47:58 -0400 Received: by mail-qt1-x82c.google.com with SMTP id d75a77b69052e-42a0ba5098bso29636511cf.0 for ; Sun, 10 Mar 2024 11:47:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1710096474; x=1710701274; darn=gnu.org; h=content-transfer-encoding:mime-version:user-agent:message-id:date :subject:to:from:from:to:cc:subject:date:message-id:reply-to; bh=poEGt5wPxWOM6dDivLtUbM5lJQxb4abm7VmHBNvDaJY=; b=B3ohBQvUKDoyqJNMSNOXUPnak8l4szqdKxcI91ldeU3V8qD4iBCEVEo+Bnhk1ejwpd j5cNTcsF3m9/uxJuWxhM/fWlWWYJyAaSE+AiUVUpC2C+zm/kpcJr3ahhmoL8MfslczvV qmShcY0VVJYMGbLn9kwlUVlk9ICre19owxysg8lWK0AsJXyx1KhP72Z87xiHCOm7/EeW LyOTH7nEI6tAcZMWtfkY3lZhQ63c7FAt/LkU7lpSsUsAU1VJVkRAOBOdJWET6UhI7gvG 9aiFpivZ3KvLcRSHeryOdpXdTnKZC9Q3+cenet5eUmcTxZtNppsT3oX6abNcBYJ/Vjaz 3FwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1710096474; x=1710701274; h=content-transfer-encoding:mime-version:user-agent:message-id:date :subject:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=poEGt5wPxWOM6dDivLtUbM5lJQxb4abm7VmHBNvDaJY=; b=ZdC/McvSVByP34NWuDB51tRdzUXcF7GkW8e4oYXOE/PBq70eLBAXEn1ERrY0ryOVot odMq6/xvoEHsTaTHwEEqaa6EOVoNcphhSvz9EvRYc/+fen32X4mc+8dmoRbGtfpa7vWY AUFLytpIOo6ll2bGWoxRyIwOT5+ALlTNQ5Z3lwUmM7v4JnQ5hPxbb/8ar5uaj3KnSgox SUEMM+iixQwUXHlINGpyIgGxjWoyBvh01Q2luvX8vBkjfh4pwxJfFtLD/RUgLvb7wigX 25TSMIF18Ft69VFlxkGlPumuNWs5YmDviq1u40HrS/4tvQNOQdcI/Llu5v8KJtSb7NG6 Lr3A== X-Gm-Message-State: AOJu0YxOOAyPW1hCT/bzNabLX7GYs3XD1ppRQmDZ2KaiCfwfsI0y/DY9 cY9BlXuR2mtCFiKvmU09e+9CCZm4b8ltcNBkWr3NGDHCTlqBDkgp X-Google-Smtp-Source: AGHT+IGNJmvvk4Vp/d4I1adnlBHt8bP4VtE2t8+9mHjAng48B2jvh7Ta846gOhzmYjdrcVJmB/oOgw== X-Received: by 2002:ac8:5a0b:0:b0:42f:3096:c4d3 with SMTP id n11-20020ac85a0b000000b0042f3096c4d3mr7081014qta.20.1710096473891; Sun, 10 Mar 2024 11:47:53 -0700 (PDT) Received: from t530.local ([2600:8806:a821:2b00::ec00]) by smtp.gmail.com with ESMTPSA id ju2-20020a05622aa04200b0042ef50235e7sm2025535qtb.47.2024.03.10.11.47.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Mar 2024 11:47:53 -0700 (PDT) From: Date: Sun, 10 Mar 2024 14:47:52 -0400 Message-ID: <8734sx2aav.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2607:f8b0:4864:20::82c; envelope-from=tpeplt@gmail.com; helo=mail-qt1-x82c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) X-Mailman-Approved-At: Sun, 10 Mar 2024 22:46:17 -0400 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.3 (--) Emacs Maintainers, The function =E2=80=98shortdoc-copy-function-as-kill=E2=80=99 copies the function name of the function of the shortdoc item in which point is located. This works as expected when a function has arguments, but when a function does not have arguments, then =E2=80=98shortdoc-copy-function-as-kill=E2=80=99 copies the trailing parenthesis (that is, the =E2=80=98)=E2=80=99). So, for example in the shortdoc function summary for =E2=80=98buffer=E2=80=99, when point is in the item for =E2=80=98current-bu= ffer=E2=80=99, then =E2=80=98shortdoc-copy-function-as-kill=E2=80=99 (mapped to =E2=80=98w= =E2=80=99) will copy the text "current-buffer)", rather than the expected "current-buffer". The same error occurs for =E2=80=98point=E2=80=99, =E2=80=98point-min=E2=80=99, =E2=80=98point-max=E2=80=99, and so on. In the definition of =E2=80=98shortdoc-copy-function-as-kill=E2=80=99, the specification of the regular expression that is used to match the function name searches for a space (" ") to find the end of the name, rather than searching for a space or right parenthesis (" )"). That is, the expression (in " ") in the =E2=80=98when-let*=E2=80=99 expression: (when-let* ((re (rx bol "(" (group (+ (not (in " "))))))... A possible fix is to change (in " ") to (in " )"): (when-let* ((re (rx bol "(" (group (+ (not (in " )"))))))... -- From unknown Sun Aug 17 10:17:06 2025 X-Loop: help-debbugs@gnu.org Subject: bug#69720: 29.2; `shortdoc-copy-function-as-kill' copies the ')' for some functions Resent-From: tpeplt Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 14 Mar 2024 16:24:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 69720 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 69720@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.171043343830816 (code B ref -1); Thu, 14 Mar 2024 16:24:02 +0000 Received: (at submit) by debbugs.gnu.org; 14 Mar 2024 16:23:58 +0000 Received: from localhost ([127.0.0.1]:50479 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rkns5-00080x-AS for submit@debbugs.gnu.org; Thu, 14 Mar 2024 12:23:57 -0400 Received: from lists.gnu.org ([209.51.188.17]:37804) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rknlG-0007p9-J8 for submit@debbugs.gnu.org; Thu, 14 Mar 2024 12:16:55 -0400 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 1rknkc-0003wG-1K for bug-gnu-emacs@gnu.org; Thu, 14 Mar 2024 12:16:16 -0400 Received: from mail-qk1-x736.google.com ([2607:f8b0:4864:20::736]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rknka-0004sy-86 for bug-gnu-emacs@gnu.org; Thu, 14 Mar 2024 12:16:13 -0400 Received: by mail-qk1-x736.google.com with SMTP id af79cd13be357-7882b1e87c4so51961785a.1 for ; Thu, 14 Mar 2024 09:16:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1710432969; x=1711037769; darn=gnu.org; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:to:from:from:to:cc:subject:date :message-id:reply-to; bh=oML9NuGt7JyqIpHRzGVRj8d4jtvCRB773U7x1ZVow3A=; b=hflP8EQ2XCfF0uQy9qi+mtePbefcLwjIjUnIenxyMLi0CK+fy6gu5rjZCJgIpmw+Ox Mdh/5mT6zoykl7Veg0sJ5WVYDMGDS01Bc41Vp/zsNVC4pg9/VB7KH4amhhSenC38pl2m uuOX40+CzPT2/5n02VETRnT9YpZ2or4yO5v/oJKRPRz41hCkB2e2cIwcFNFS/u+ZoFsC pfUVyJAoX/dC7UGmPlSpMrm2n1ZktG5JOxAEU5l3DfjO8mLdoyYG5Y/lorg18NX4al3s W3eY34Ag9SJwPJPGf0b6MT6xYrDBKaw/D/sKng9f6OlhJGC/5sH/e1QRv2eb2habFm0R b5Qw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1710432969; x=1711037769; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:to:from:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=oML9NuGt7JyqIpHRzGVRj8d4jtvCRB773U7x1ZVow3A=; b=L6WxK+Thd4pWqiwYXGL/3M8K3x5Hkt2lgBuPGc0v9U3zAUzvbSmXW7iB3grzUFbU6f nmdxSzk2+I5ycDI8icWCZCpoakJ0yjWfi7/TINqNCWegdh+lW9wfi/Bx9XMs5rcdGulr yvb0ZtKDpq3oSuNHlDiMsASq46MdLGt4DeCdULg4gu2F4guB8WWelYGnU9LMmq26KmHg LaagGfk9TMHUkbvsWSu8WC4ugd+G2ziWNuCEpfx10BkzjAmfxmtZq397XYpr7d+CinE8 5i0pcWstp6hEtiysn2k6j2ksssh8xTQwA4U+wr19Nwm4PuWvbyxz4L/wDbe6N9XY1xYM Mkuw== X-Gm-Message-State: AOJu0YxQdYb8tQ27IOOaczv62T03aCwqjv8SlVkgRnQNnOo4LHxrIATz 9SPonWEiiL3KaSudIrdUwtXz2jqGqxUvMa9VnROQebF85cbP7dKnvVUR368A X-Google-Smtp-Source: AGHT+IEq+Ij9HL7OGDL/+rW4TWLtClUyTj7nIhNVLJKict5KJjJlwwFqwxaYG+hWg4nZPNuGfHaPdQ== X-Received: by 2002:a05:620a:2a02:b0:789:e127:e3ff with SMTP id o2-20020a05620a2a0200b00789e127e3ffmr1114961qkp.67.1710432969352; Thu, 14 Mar 2024 09:16:09 -0700 (PDT) Received: from t530.local ([2600:8806:a821:2b00::f46]) by smtp.gmail.com with ESMTPSA id o5-20020ae9f505000000b0078812b73ea1sm999172qkg.28.2024.03.14.09.16.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 14 Mar 2024 09:16:08 -0700 (PDT) From: tpeplt In-Reply-To: <8734sx2aav.fsf@gmail.com> (tpeplt@gmail.com's message of "Sun, 10 Mar 2024 14:47:52 -0400") References: <8734sx2aav.fsf@gmail.com> Date: Thu, 14 Mar 2024 12:16:06 -0400 Message-ID: <87bk7gvlfd.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2607:f8b0:4864:20::736; envelope-from=tpeplt@gmail.com; helo=mail-qk1-x736.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Mailman-Approved-At: Thu, 14 Mar 2024 12:23:56 -0400 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.3 (--) Here is a recipe for reproducing this error: 1. Start Emacs from a shell prompt with =E2=80=98emacs -Q=E2=80=99. 2. Run the =E2=80=98shortdoc=E2=80=99 command: M-x shortdoc 3. At the prompt "Show summary for functions in: ", type: buffer RET 4. In the buffer "*Shortdoc buffer*", position point on the line that begins description of the =E2=80=98current-buffer=E2=80=99 entry, (current-= buffer). 5. Type =E2=80=98w=E2=80=99 to copy the name of the function (w runs the co= mmand =E2=80=98shortdoc-copy-function-as-kill=E2=80=99). 6. Switch to the *scratch* buffer. 7. Type C-y to yank the name of the function =E2=80=98current-buffer=E2=80= =99 into the buffer. Note that the text that is inserted is "current-buffer)", with a trailing parenthesis instead of "current-buffer". 8. Repeat the sequence of operations above to copy the names of functions that have at least one argument. The function name is copied correctly. 9. Repeat the sequence of operations above to copy the names of other functions in the *Shortdoc buffer* that have no arguments (such as =E2=80=98point=E2=80=99, =E2=80=98point-min=E2=80=99, and so on). Note tha= t when the function name is yanked into the *scratch* buffer, a trailing parenthesis is (incorrectly) included in the text. -- From unknown Sun Aug 17 10:17:06 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: Subject: bug#69720: closed (Re: bug#69720: 29.2; `shortdoc-copy-function-as-kill' copies the ')' for some functions) Message-ID: References: <865xxm77sm.fsf@gnu.org> <8734sx2aav.fsf@gmail.com> X-Gnu-PR-Message: they-closed 69720 X-Gnu-PR-Package: emacs Reply-To: 69720@debbugs.gnu.org Date: Sat, 16 Mar 2024 11:10:03 +0000 Content-Type: multipart/mixed; boundary="----------=_1710587403-28521-1" This is a multi-part message in MIME format... ------------=_1710587403-28521-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #69720: 29.2; `shortdoc-copy-function-as-kill' copies the ')' for some func= tions 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 69720@debbugs.gnu.org. --=20 69720: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D69720 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1710587403-28521-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 69720-done) by debbugs.gnu.org; 16 Mar 2024 11:09:46 +0000 Received: from localhost ([127.0.0.1]:54985 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rlRv8-0007P0-AA for submit@debbugs.gnu.org; Sat, 16 Mar 2024 07:09:46 -0400 Received: from eggs.gnu.org ([209.51.188.92]:45572) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rlRv6-0007On-M5 for 69720-done@debbugs.gnu.org; Sat, 16 Mar 2024 07:09:45 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rlRuP-0008Md-Pa; Sat, 16 Mar 2024 07:09:02 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=gKDmUF2K8jNUclOvMj7U/vv8dGNBSQxn/Yy+y8bUO1s=; b=Mp/LrcLvG4mPnvoCzNPb M3IUt7iz/FXm6ZvtofOJfucXbAXL5iGEr1W4PGbO3HmMUCPsQCe6o/kHfCSQVLia2Khjo3fCjm3kU WHBoPU3WqtaMPhWiqdX+cAkQfejmuJuToAD3Jd3M5f6EE1xgIHGphvvm248eqGBxAie9uUQOGbYnM gQ4GBZ02dkwYe4dIOhido0AyiDlPFfZt6SAKMHfsfAmVX8CKwslNAMY9L22uvFq4+TRNNu5venejW woIATdxomr6Z2dmFJyCvTsqxEwoY6RzuLuADfpIgHbt6Q3xZLgbVvSn7Ii5h7a8OLqHBTeG/cFnSw rMotwah3adiQuA==; Date: Sat, 16 Mar 2024 13:08:57 +0200 Message-Id: <865xxm77sm.fsf@gnu.org> From: Eli Zaretskii To: In-Reply-To: <8734sx2aav.fsf@gmail.com> (tpeplt@gmail.com) Subject: Re: bug#69720: 29.2; `shortdoc-copy-function-as-kill' copies the ')' for some functions References: <8734sx2aav.fsf@gmail.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 69720-done Cc: 69720-done@debbugs.gnu.org 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: -3.3 (---) > From: > Date: Sun, 10 Mar 2024 14:47:52 -0400 > > Emacs Maintainers, > > The function ‘shortdoc-copy-function-as-kill’ copies the > function name of the function of the shortdoc item in > which point is located. This works as expected when a > function has arguments, but when a function does not have > arguments, then ‘shortdoc-copy-function-as-kill’ copies the > trailing parenthesis (that is, the ‘)’). > > So, for example in the shortdoc function summary for > ‘buffer’, when point is in the item for ‘current-buffer’, > then ‘shortdoc-copy-function-as-kill’ (mapped to ‘w’) will > copy the text "current-buffer)", rather than the expected > "current-buffer". The same error occurs for ‘point’, > ‘point-min’, ‘point-max’, and so on. > > In the definition of ‘shortdoc-copy-function-as-kill’, > the specification of the regular expression that is used to > match the function name searches for a space (" ") to find > the end of the name, rather than searching for a space or > right parenthesis (" )"). That is, the expression (in " ") > in the ‘when-let*’ expression: > > (when-let* ((re (rx bol "(" (group (+ (not (in " "))))))... > > A possible fix is to change (in " ") to (in " )"): > > (when-let* ((re (rx bol "(" (group (+ (not (in " )"))))))... Thanks, fixed on the emacs-29 branch, and closing the bug. ------------=_1710587403-28521-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 11 Mar 2024 02:46:19 +0000 Received: from localhost ([127.0.0.1]:38221 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rjVgA-0005Lm-Bg for submit@debbugs.gnu.org; Sun, 10 Mar 2024 22:46:19 -0400 Received: from lists.gnu.org ([209.51.188.17]:50768) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rjODz-0001Zg-3V for submit@debbugs.gnu.org; Sun, 10 Mar 2024 14:48:52 -0400 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 1rjODH-0000BN-9g for bug-gnu-emacs@gnu.org; Sun, 10 Mar 2024 14:48:00 -0400 Received: from mail-qt1-x82c.google.com ([2607:f8b0:4864:20::82c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rjODF-00058I-NV for bug-gnu-emacs@gnu.org; Sun, 10 Mar 2024 14:47:58 -0400 Received: by mail-qt1-x82c.google.com with SMTP id d75a77b69052e-42a0ba5098bso29636511cf.0 for ; Sun, 10 Mar 2024 11:47:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1710096474; x=1710701274; darn=gnu.org; h=content-transfer-encoding:mime-version:user-agent:message-id:date :subject:to:from:from:to:cc:subject:date:message-id:reply-to; bh=poEGt5wPxWOM6dDivLtUbM5lJQxb4abm7VmHBNvDaJY=; b=B3ohBQvUKDoyqJNMSNOXUPnak8l4szqdKxcI91ldeU3V8qD4iBCEVEo+Bnhk1ejwpd j5cNTcsF3m9/uxJuWxhM/fWlWWYJyAaSE+AiUVUpC2C+zm/kpcJr3ahhmoL8MfslczvV qmShcY0VVJYMGbLn9kwlUVlk9ICre19owxysg8lWK0AsJXyx1KhP72Z87xiHCOm7/EeW LyOTH7nEI6tAcZMWtfkY3lZhQ63c7FAt/LkU7lpSsUsAU1VJVkRAOBOdJWET6UhI7gvG 9aiFpivZ3KvLcRSHeryOdpXdTnKZC9Q3+cenet5eUmcTxZtNppsT3oX6abNcBYJ/Vjaz 3FwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1710096474; x=1710701274; h=content-transfer-encoding:mime-version:user-agent:message-id:date :subject:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=poEGt5wPxWOM6dDivLtUbM5lJQxb4abm7VmHBNvDaJY=; b=ZdC/McvSVByP34NWuDB51tRdzUXcF7GkW8e4oYXOE/PBq70eLBAXEn1ERrY0ryOVot odMq6/xvoEHsTaTHwEEqaa6EOVoNcphhSvz9EvRYc/+fen32X4mc+8dmoRbGtfpa7vWY AUFLytpIOo6ll2bGWoxRyIwOT5+ALlTNQ5Z3lwUmM7v4JnQ5hPxbb/8ar5uaj3KnSgox SUEMM+iixQwUXHlINGpyIgGxjWoyBvh01Q2luvX8vBkjfh4pwxJfFtLD/RUgLvb7wigX 25TSMIF18Ft69VFlxkGlPumuNWs5YmDviq1u40HrS/4tvQNOQdcI/Llu5v8KJtSb7NG6 Lr3A== X-Gm-Message-State: AOJu0YxOOAyPW1hCT/bzNabLX7GYs3XD1ppRQmDZ2KaiCfwfsI0y/DY9 cY9BlXuR2mtCFiKvmU09e+9CCZm4b8ltcNBkWr3NGDHCTlqBDkgp X-Google-Smtp-Source: AGHT+IGNJmvvk4Vp/d4I1adnlBHt8bP4VtE2t8+9mHjAng48B2jvh7Ta846gOhzmYjdrcVJmB/oOgw== X-Received: by 2002:ac8:5a0b:0:b0:42f:3096:c4d3 with SMTP id n11-20020ac85a0b000000b0042f3096c4d3mr7081014qta.20.1710096473891; Sun, 10 Mar 2024 11:47:53 -0700 (PDT) Received: from t530.local ([2600:8806:a821:2b00::ec00]) by smtp.gmail.com with ESMTPSA id ju2-20020a05622aa04200b0042ef50235e7sm2025535qtb.47.2024.03.10.11.47.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Mar 2024 11:47:53 -0700 (PDT) From: To: bug-gnu-emacs@gnu.org Subject: 29.2; `shortdoc-copy-function-as-kill' copies the ')' for some functions Date: Sun, 10 Mar 2024 14:47:52 -0400 Message-ID: <8734sx2aav.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2607:f8b0:4864:20::82c; envelope-from=tpeplt@gmail.com; helo=mail-qt1-x82c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Sun, 10 Mar 2024 22:46:17 -0400 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.3 (--) Emacs Maintainers, The function =E2=80=98shortdoc-copy-function-as-kill=E2=80=99 copies the function name of the function of the shortdoc item in which point is located. This works as expected when a function has arguments, but when a function does not have arguments, then =E2=80=98shortdoc-copy-function-as-kill=E2=80=99 copies the trailing parenthesis (that is, the =E2=80=98)=E2=80=99). So, for example in the shortdoc function summary for =E2=80=98buffer=E2=80=99, when point is in the item for =E2=80=98current-bu= ffer=E2=80=99, then =E2=80=98shortdoc-copy-function-as-kill=E2=80=99 (mapped to =E2=80=98w= =E2=80=99) will copy the text "current-buffer)", rather than the expected "current-buffer". The same error occurs for =E2=80=98point=E2=80=99, =E2=80=98point-min=E2=80=99, =E2=80=98point-max=E2=80=99, and so on. In the definition of =E2=80=98shortdoc-copy-function-as-kill=E2=80=99, the specification of the regular expression that is used to match the function name searches for a space (" ") to find the end of the name, rather than searching for a space or right parenthesis (" )"). That is, the expression (in " ") in the =E2=80=98when-let*=E2=80=99 expression: (when-let* ((re (rx bol "(" (group (+ (not (in " "))))))... A possible fix is to change (in " ") to (in " )"): (when-let* ((re (rx bol "(" (group (+ (not (in " )"))))))... -- ------------=_1710587403-28521-1--