From jidanni@jidanni.org Fri Nov 27 18:45:07 2009 Received: (at submit) by emacsbugs.donarmstrong.com; 28 Nov 2009 02:45:08 +0000 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=1.7 required=4.0 tests=SARE_RECV_SPAM_DOMN0b autolearn=no 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.14.3/8.14.3/Debian-5) with ESMTP id nAS2j6Ik030455 for ; Fri, 27 Nov 2009 18:45:07 -0800 Received: from mail.gnu.org ([199.232.76.166]:42547 helo=mx10.gnu.org) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1NEDJ2-0003Sm-7R for emacs-pretest-bug@gnu.org; Fri, 27 Nov 2009 21:45:04 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NEDJ0-0007fS-VJ for emacs-pretest-bug@gnu.org; Fri, 27 Nov 2009 21:45:03 -0500 Received: from caiajhbdcbef.dreamhost.com ([208.97.132.145]:57823 helo=homiemail-a7.g.dreamhost.com) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NEDJ0-0007fI-Ly for emacs-pretest-bug@gnu.org; Fri, 27 Nov 2009 21:45:02 -0500 Received: from jidanni.org (125-230-47-245.dynamic.hinet.net [125.230.47.245]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by homiemail-a7.g.dreamhost.com (Postfix) with ESMTPSA id 1967B25C05F for ; Fri, 27 Nov 2009 18:45:00 -0800 (PST) From: jidanni@jidanni.org To: emacs-pretest-bug@gnu.org Subject: 23.1.50; perl mode coloring gone if subroutine name is one letter long Date: Sat, 28 Nov 2009 09:41:40 +0800 Message-ID: <87ocmn8lyj.fsf@jidanni.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Gentlemen, consider the following perl subroutines. Notice how the latter has all its coloring gone, just because it starts with one letter. (perl-mode)^X^E sub max { my $max = shift(@_); foreach $foo (@_) { $max = $foo if $max < $foo; } return $max; } sub m { my $max = shift(@_); foreach $foo (@_) { $max = $foo if $max < $foo; } return $max; } From monnier@iro.umontreal.ca Sat Nov 28 11:41:11 2009 Received: (at 5064) by emacsbugs.donarmstrong.com; 28 Nov 2009 19:41:11 +0000 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=-2.8 required=4.0 tests=AWL,HAS_BUG_NUMBER autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from ironport2-out.pppoe.ca (ironport2-out.teksavvy.com [206.248.154.183]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nASJf9G6001986 for <5064@emacsbugs.donarmstrong.com>; Sat, 28 Nov 2009 11:41:11 -0800 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AqYEAOcKEUtFpYc//2dsb2JhbACBTdIDhDEEihk X-IronPort-AV: E=Sophos;i="4.47,306,1257138000"; d="scan'208";a="50247492" Received: from 69-165-135-63.dsl.teksavvy.com (HELO pastel.home) ([69.165.135.63]) by ironport2-out.pppoe.ca with ESMTP; 28 Nov 2009 14:41:04 -0500 Received: by pastel.home (Postfix, from userid 20848) id 7E51180E3; Sat, 28 Nov 2009 14:41:03 -0500 (EST) From: Stefan Monnier To: jidanni@jidanni.org Cc: 5064@debbugs.gnu.org Subject: Re: bug#5064: 23.1.50; perl mode coloring gone if subroutine name is one letter long Message-ID: References: <87ocmn8lyj.fsf@jidanni.org> Date: Sat, 28 Nov 2009 14:41:03 -0500 In-Reply-To: <87ocmn8lyj.fsf@jidanni.org> (jidanni@jidanni.org's message of "Sat, 28 Nov 2009 09:41:40 +0800") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii > Gentlemen, consider the following perl subroutines. > Notice how the latter has all its coloring gone, just because it starts > with one letter. (perl-mode)^X^E > sub max { > my $max = shift(@_); > foreach $foo (@_) { > $max = $foo if $max < $foo; > } > return $max; > } > sub m { > my $max = shift(@_); > foreach $foo (@_) { > $max = $foo if $max < $foo; > } > return $max; > } Actually, the problem is not really that it's only one letter, but that it's the "keyword" m, used for matching (as in "m/regexp/"). Of course the same can happen with other keywords like "s", "tr", "y", "q", "qx", and various others. I'm not sure if such a function definition is valid. Does Perl accept it and can you actually call this function? Stefan From debbugs@rietz.debian.org Sat Nov 28 12:30:38 2009 Received: (at 5064-close) by emacsbugs.donarmstrong.com; 28 Nov 2009 20:30:38 +0000 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.3 required=4.0 tests=AWL,HAS_BUG_NUMBER, HAS_PACKAGE,SARE_RECV_SPAM_DOMN0b autolearn=ham version=3.2.5-bugs.debian.org_2005_01_02 Received: from rietz.debian.org (rietz.debian.org [140.211.166.43]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nASKUaNp007647 for <5064-close@emacsbugs.donarmstrong.com>; Sat, 28 Nov 2009 12:30:38 -0800 Received: from debbugs by rietz.debian.org with local (Exim 4.63) (envelope-from ) id 1NETsm-0007Tp-QJ; Sat, 28 Nov 2009 20:27:04 +0000 X-Loop: owner@bugs.debian.org Subject: Bug#558428: mention that perl can't deal with certain one letter subroutines Reply-To: jidanni@jidanni.org, 558428@bugs.debian.org Resent-From: jidanni@jidanni.org Resent-To: debian-bugs-dist@lists.debian.org Resent-CC: 5064-close@debbugs.gnu.org, monnier@iro.umontreal.ca, Niko Tyni X-Loop: owner@bugs.debian.org Resent-Date: Sat, 28 Nov 2009 20:27:01 +0000 Resent-Message-ID: X-Debian-PR-Message: report 558428 X-Debian-PR-Package: perl-doc X-Debian-PR-Keywords: upstream X-Debian-PR-Source: perl Received: via spool by submit@bugs.debian.org id=B.125943978827078 (code B ref -1); Sat, 28 Nov 2009 20:27:01 +0000 Received: (at submit) by bugs.debian.org; 28 Nov 2009 20:23:08 +0000 Received: from caiajhbdcbef.dreamhost.com ([208.97.132.145] helo=homiemail-a14.g.dreamhost.com) by rietz.debian.org with esmtp (Exim 4.63) (envelope-from ) id 1NEToy-00072X-7H for submit@bugs.debian.org; Sat, 28 Nov 2009 20:23:08 +0000 Received: from jidanni.org (218-163-4-239.dynamic.hinet.net [218.163.4.239]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by homiemail-a14.g.dreamhost.com (Postfix) with ESMTPSA id E96138C071 for ; Sat, 28 Nov 2009 12:23:06 -0800 (PST) From: jidanni@jidanni.org To: submit@bugs.debian.org References: Date: Sun, 29 Nov 2009 04:23:07 +0800 Message-ID: <873a3ytn4k.fsf_-_@jidanni.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Delivered-To: submit@bugs.debian.org Resent-Sender: Debian BTS Resent-Date: Sat, 28 Nov 2009 20:27:04 +0000 X-debbugs-cc: 5064-close@debbugs.gnu.org, monnier@iro.umontreal.ca Package: perl-doc Version: 5.10.1-8 Severity: wishlist File: /usr/share/man/man1/perlsub.1.gz Tags: upstream Dear Perl guys: On the perlsub man page, please mention near: Subroutines whose names are in all upper case are reserved to the Perl core, as are modules whose names are in all lower case. that sub m {...} won't work too. SM> Actually, the problem is not really that it's only one letter, but that SM> it's the "keyword" m, used for matching (as in "m/regexp/"). Of course SM> the same can happen with other keywords like "s", "tr", "y", "q", "qx", SM> and various others. From unknown Tue Jun 24 22:37:52 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 27 Dec 2009 12:24:02 +0000 User-Agent: Fakemail v42.6.9 # A New Hope # A long time ago, in a galaxy far, far away # something happened. # # Magically this resulted in the following # action being taken, but this fake control # message doesn't tell you why it happened # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator