From unknown Mon Aug 18 11:22:04 2025 X-Loop: don@donarmstrong.com Subject: bug#88: perl-mode - fix syntax of anonymous sub prototypes Reply-To: "Giuliano Procida" , 88@debbugs.gnu.org Resent-From: "Giuliano Procida" Original-Sender: bug-gnu-emacs-bounces+monnier=iro.umontreal.ca@gnu.org Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Sat, 29 Mar 2008 18:55:11 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 88 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by submit@emacsbugs.donarmstrong.com id=B.120681658726719 (code B ref -1); Sat, 29 Mar 2008 18:55:11 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=0.0 required=4.0 tests=MURPHY_DRUGS_REL8 autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 29 Mar 2008 18:49:47 +0000 Received: from ironport2-out.teksavvy.com (ironport2-out.pppoe.ca [206.248.154.182]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m2TInhYb026713 for ; Sat, 29 Mar 2008 11:49:45 -0700 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ag4FADcs7kfO+LLN/2dsb2JhbACBWpBqlns X-IronPort-AV: E=Sophos;i="4.25,575,1199682000"; d="scan'208";a="17131999" Received: from smtp.pppoe.ca (HELO smtp.teksavvy.com) ([65.39.196.238]) by ironport2-out.teksavvy.com with ESMTP; 29 Mar 2008 14:49:38 -0400 Received: from pastel.home ([206.248.178.205]) by smtp.teksavvy.com (Internet Mail Server v1.0) with ESMTP id JVA59338 for ; Sat, 29 Mar 2008 14:49:38 -0400 Received: by pastel.home (Postfix, from userid 20848) id 568047F9E; Sat, 29 Mar 2008 14:49:38 -0400 (EDT) Resent-Message-ID: Resent-To: submit@debbugs.gnu.org Resent-From: Stefan Monnier Resent-Date: Sat, 29 Mar 2008 14:49:38 -0400 X-Original-To: monnier@iro.umontreal.ca Received: from pinpin.iro.umontreal.ca (pinpin.iro.umontreal.ca [132.204.24.52]) by mercure.iro.umontreal.ca (Postfix) with ESMTP id 600942CF96C for ; Fri, 28 Mar 2008 21:48:03 -0400 (EDT) Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by pinpin.iro.umontreal.ca (Postfix) with ESMTP id 8CD7E3B8AA7 for ; Fri, 28 Mar 2008 21:47:59 -0400 (EDT) Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JfQAp-0000jY-CX for monnier@iro.umontreal.ca; Fri, 28 Mar 2008 21:47:59 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JfIW5-0001dp-LY for bug-gnu-emacs@gnu.org; Fri, 28 Mar 2008 13:37:25 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JfIW4-0001d2-5D for bug-gnu-emacs@gnu.org; Fri, 28 Mar 2008 13:37:25 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JfIW4-0001cs-22 for bug-gnu-emacs@gnu.org; Fri, 28 Mar 2008 13:37:24 -0400 Received: from nf-out-0910.google.com ([64.233.182.188]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JfIW3-0006pn-K5 for bug-gnu-emacs@gnu.org; Fri, 28 Mar 2008 13:37:23 -0400 Received: by nf-out-0910.google.com with SMTP id f5so219806nfh.26 for ; Fri, 28 Mar 2008 10:37:09 -0700 (PDT) Received: by 10.78.142.14 with SMTP id p14mr10544175hud.65.1206725828798; Fri, 28 Mar 2008 10:37:08 -0700 (PDT) Received: by 10.78.198.16 with HTTP; Fri, 28 Mar 2008 10:37:08 -0700 (PDT) Message-ID: <5c8016cf0803281037q5c64bd21le5e3359ddadca955@mail.gmail.com> Date: Fri, 28 Mar 2008 17:37:08 +0000 From: "Giuliano Procida" To: bug-gnu-emacs@gnu.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 2) X-Mailman-Approved-At: Fri, 28 Mar 2008 21:47:40 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: bug-gnu-emacs-bounces+monnier=iro.umontreal.ca@gnu.org Errors-To: bug-gnu-emacs-bounces+monnier=iro.umontreal.ca@gnu.org X-DIRO-MailScanner-Information: Please contact the ISP for more information X-DIRO-MailScanner: Found to be clean X-DIRO-MailScanner-SpamCheck: n'est pas un polluriel, SpamAssassin (score=-1.873, requis 5, BAYES_00 -2.60, RCVD_BY_IP 0.07, RECEIVED_FROM_NOUNK 0.66, SPF_HELO_PASS -0.00) X-DIRO-MailScanner-From: bug-gnu-emacs-bounces+monnier=iro.umontreal.ca@gnu.org Hi. GNU Emacs 22.1.1 (i386-pc-solaris2.10, X toolkit) of 2008-02-11 on robot Constructs like this: my $del = sub($) { my ($old) = @_; return if not active($old); &$delete_row($old->{$fde_id}); }; upset later indentation as the $ in the sub($) has the default backslash syntax class (instead of being treated specially as in non-anonymous sub definitions) and then the "sub(" triggers the hanging parens check. The fix is to modify perl-font-lock-syntactic-keywords to have: ;; Funny things in sub arg specifications like `sub myfunc ($$)' and `sub ($)' ("\\, 88@debbugs.gnu.org Resent-From: "Giuliano Procida" Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Sat, 29 Mar 2008 19:40:06 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 88 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by 88-submit@emacsbugs.donarmstrong.com id=B88.12068190675801 (code B ref 88); Sat, 29 Mar 2008 19:40:06 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=0.1 required=4.0 tests=AWL,FOURLA,MURPHY_DRUGS_REL8 autolearn=no version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 88) by emacsbugs.donarmstrong.com; 29 Mar 2008 19:31:07 +0000 Received: from nf-out-0910.google.com (nf-out-0910.google.com [64.233.182.188]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m2TJV1dX005795 for <88@emacsbugs.donarmstrong.com>; Sat, 29 Mar 2008 12:31:03 -0700 Received: by nf-out-0910.google.com with SMTP id 4so387423nfv.31 for <88@emacsbugs.donarmstrong.com>; Sat, 29 Mar 2008 12:31:00 -0700 (PDT) Received: by 10.78.182.17 with SMTP id e17mr15394168huf.57.1206819056358; Sat, 29 Mar 2008 12:30:56 -0700 (PDT) Received: by 10.78.198.16 with HTTP; Sat, 29 Mar 2008 12:30:56 -0700 (PDT) Message-ID: <5c8016cf0803291230g55a76353off33332ae3dc186c@mail.gmail.com> Date: Sat, 29 Mar 2008 19:30:56 +0000 From: "Giuliano Procida" To: 88@debbugs.gnu.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline The patch I sent was broken. In any case it looks like the latest HEAD has a completely different regexp: ;; Funny things in sub arg specifications like `sub myfunc ($$)' ;; Be careful not to match "sub { (...) ... }". ("\\ Subject: bug#88 closed by Stefan Monnier (Re: perl-mode - fix syntax of anonymous sub prototypes) Message-ID: References: <5c8016cf0803281037q5c64bd21le5e3359ddadca955@mail.gmail.com> X-Emacs-PR-Message: they-closed 88 X-Emacs-PR-Package: emacs Reply-To: 88@debbugs.gnu.org Content-Type: multipart/mixed; boundary="----------=_1207305903-5825-1" This is a multi-part message in MIME format... ------------=_1207305903-5825-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" This is an automatic notification regarding your bug report which was filed against the emacs package: #88: perl-mode - fix syntax of anonymous sub prototypes It has been closed by Stefan Monnier . Their explanation is attached below along with your original report. If this explanation is unsatisfactory and you have not received a better one in a separate message then please contact Stefan Monnier by replying to this email. --=20 88: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D88 Emacs Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1207305903-5825-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit >From monnier@iro.umontreal.ca Fri Apr 4 03:36:32 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-0.6 required=4.0 tests=AWL autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 88-done) by emacsbugs.donarmstrong.com; 4 Apr 2008 10:36:32 +0000 Received: from ironport2-out.teksavvy.com (ironport2-out.teksavvy.com [206.248.154.182]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m34AaTXP004554 for <88-done@emacsbugs.donarmstrong.com>; Fri, 4 Apr 2008 03:36:30 -0700 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AqYCAPeg9UfO+J/WdGdsb2JhbACBWo9yASqZaw X-IronPort-AV: E=Sophos;i="4.25,603,1199682000"; d="scan'208";a="17681702" Received: from smtp.pppoe.ca (HELO smtp.teksavvy.com) ([65.39.196.238]) by ironport2-out.teksavvy.com with ESMTP; 03 Apr 2008 23:38:09 -0400 Received: from pastel.home ([206.248.159.214]) by smtp.teksavvy.com (Internet Mail Server v1.0) with ESMTP id KHQ27309 for <88-done@emacsbugs.donarmstrong.com>; Thu, 03 Apr 2008 23:38:09 -0400 Received: by pastel.home (Postfix, from userid 20848) id D91267FEE; Thu, 3 Apr 2008 23:38:08 -0400 (EDT) Resent-Message-ID: Resent-To: 88-done@debbugs.gnu.org Resent-From: Stefan Monnier Resent-Date: Thu, 03 Apr 2008 23:38:08 -0400 X-Original-To: monnier@iro.umontreal.ca Received: from pinpin.iro.umontreal.ca (pinpin.iro.umontreal.ca [132.204.24.52]) by mercure.iro.umontreal.ca (Postfix) with ESMTP id 85A1F2CF6EE for ; Thu, 3 Apr 2008 18:11:02 -0400 (EDT) Received: from pruche.dit.umontreal.ca (pruche.dit.umontreal.ca [132.204.246.22]) by pinpin.iro.umontreal.ca (Postfix) with ESMTP id AC36B3B8B43 for ; Thu, 3 Apr 2008 18:10:58 -0400 (EDT) Received: from ceviche.home (vpn-132-204-232-76.acd.umontreal.ca [132.204.232.76]) by pruche.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id m33MBA7C005384 for ; Thu, 3 Apr 2008 18:11:10 -0400 Received: by ceviche.home (Postfix, from userid 20848) id A868CB40F9; Thu, 3 Apr 2008 18:10:56 -0400 (EDT) From: Stefan Monnier To: "Giuliano Procida" Cc: bug-gnu-emacs@gnu.org Subject: Re: perl-mode - fix syntax of anonymous sub prototypes Message-ID: References: <5c8016cf0803281037q5c64bd21le5e3359ddadca955@mail.gmail.com> <5c8016cf0803290143x34727c91laac78b676d598000@mail.gmail.com> Date: Thu, 03 Apr 2008 18:10:56 -0400 In-Reply-To: <5c8016cf0803290143x34727c91laac78b676d598000@mail.gmail.com> (Giuliano Procida's message of "Sat, 29 Mar 2008 08:43:28 +0000") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 0 Rules triggered X-DIRO-MailScanner-Information: Please contact the ISP for more information X-DIRO-MailScanner: Found to be clean X-DIRO-MailScanner-SpamCheck: n'est pas un polluriel, SpamAssassin (score=-5.899, requis 5, autolearn=not spam, ALL_TRUSTED -3.30, BAYES_00 -2.60) X-DIRO-MailScanner-From: monnier@iro.umontreal.ca > ;; Funny things in sub arg specifications like `sub myfunc ($$)' > ;; Be careful not to match "sub { (...) ... }". > ("\\ 1 '(1)) > It is still wrong for anonymous subs. Should be (untested): > "\\From monnier@iro.umontreal.ca Sat Mar 29 11:49:47 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=0.0 required=4.0 tests=MURPHY_DRUGS_REL8 autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 29 Mar 2008 18:49:47 +0000 Received: from ironport2-out.teksavvy.com (ironport2-out.pppoe.ca [206.248.154.182]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m2TInhYb026713 for ; Sat, 29 Mar 2008 11:49:45 -0700 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ag4FADcs7kfO+LLN/2dsb2JhbACBWpBqlns X-IronPort-AV: E=Sophos;i="4.25,575,1199682000"; d="scan'208";a="17131999" Received: from smtp.pppoe.ca (HELO smtp.teksavvy.com) ([65.39.196.238]) by ironport2-out.teksavvy.com with ESMTP; 29 Mar 2008 14:49:38 -0400 Received: from pastel.home ([206.248.178.205]) by smtp.teksavvy.com (Internet Mail Server v1.0) with ESMTP id JVA59338 for ; Sat, 29 Mar 2008 14:49:38 -0400 Received: by pastel.home (Postfix, from userid 20848) id 568047F9E; Sat, 29 Mar 2008 14:49:38 -0400 (EDT) Resent-Message-ID: Resent-To: submit@debbugs.gnu.org Resent-From: Stefan Monnier Resent-Date: Sat, 29 Mar 2008 14:49:38 -0400 X-Original-To: monnier@iro.umontreal.ca Received: from pinpin.iro.umontreal.ca (pinpin.iro.umontreal.ca [132.204.24.52]) by mercure.iro.umontreal.ca (Postfix) with ESMTP id 600942CF96C for ; Fri, 28 Mar 2008 21:48:03 -0400 (EDT) Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by pinpin.iro.umontreal.ca (Postfix) with ESMTP id 8CD7E3B8AA7 for ; Fri, 28 Mar 2008 21:47:59 -0400 (EDT) Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JfQAp-0000jY-CX for monnier@iro.umontreal.ca; Fri, 28 Mar 2008 21:47:59 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JfIW5-0001dp-LY for bug-gnu-emacs@gnu.org; Fri, 28 Mar 2008 13:37:25 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JfIW4-0001d2-5D for bug-gnu-emacs@gnu.org; Fri, 28 Mar 2008 13:37:25 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JfIW4-0001cs-22 for bug-gnu-emacs@gnu.org; Fri, 28 Mar 2008 13:37:24 -0400 Received: from nf-out-0910.google.com ([64.233.182.188]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JfIW3-0006pn-K5 for bug-gnu-emacs@gnu.org; Fri, 28 Mar 2008 13:37:23 -0400 Received: by nf-out-0910.google.com with SMTP id f5so219806nfh.26 for ; Fri, 28 Mar 2008 10:37:09 -0700 (PDT) Received: by 10.78.142.14 with SMTP id p14mr10544175hud.65.1206725828798; Fri, 28 Mar 2008 10:37:08 -0700 (PDT) Received: by 10.78.198.16 with HTTP; Fri, 28 Mar 2008 10:37:08 -0700 (PDT) Message-ID: <5c8016cf0803281037q5c64bd21le5e3359ddadca955@mail.gmail.com> Date: Fri, 28 Mar 2008 17:37:08 +0000 From: "Giuliano Procida" To: bug-gnu-emacs@gnu.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 2) X-Mailman-Approved-At: Fri, 28 Mar 2008 21:47:40 -0400 Subject: perl-mode - fix syntax of anonymous sub prototypes X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: bug-gnu-emacs-bounces+monnier=iro.umontreal.ca@gnu.org Errors-To: bug-gnu-emacs-bounces+monnier=iro.umontreal.ca@gnu.org X-DIRO-MailScanner-Information: Please contact the ISP for more information X-DIRO-MailScanner: Found to be clean X-DIRO-MailScanner-SpamCheck: n'est pas un polluriel, SpamAssassin (score=-1.873, requis 5, BAYES_00 -2.60, RCVD_BY_IP 0.07, RECEIVED_FROM_NOUNK 0.66, SPF_HELO_PASS -0.00) X-DIRO-MailScanner-From: bug-gnu-emacs-bounces+monnier=iro.umontreal.ca@gnu.org Hi. GNU Emacs 22.1.1 (i386-pc-solaris2.10, X toolkit) of 2008-02-11 on robot Constructs like this: my $del = sub($) { my ($old) = @_; return if not active($old); &$delete_row($old->{$fde_id}); }; upset later indentation as the $ in the sub($) has the default backslash syntax class (instead of being treated specially as in non-anonymous sub definitions) and then the "sub(" triggers the hanging parens check. The fix is to modify perl-font-lock-syntactic-keywords to have: ;; Funny things in sub arg specifications like `sub myfunc ($$)' and `sub ($)' ("\\