GNU bug report logs - #15006
24.3; emacs manual comment-start-skip example grouping

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Severity: minor; Reported by: Kevin Ryde <user42@HIDDEN>; dated Fri, 2 Aug 2013 00:50:02 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 15006 <at> debbugs.gnu.org:


Received: (at 15006) by debbugs.gnu.org; 2 Aug 2013 02:31:08 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Aug 01 22:31:08 2013
Received: from localhost ([127.0.0.1]:35633 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1V5592-0001ld-0F
	for submit <at> debbugs.gnu.org; Thu, 01 Aug 2013 22:31:08 -0400
Received: from ironport2-out.teksavvy.com ([206.248.154.182]:19163)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <monnier@HIDDEN>) id 1V558z-0001ky-T8
 for 15006 <at> debbugs.gnu.org; Thu, 01 Aug 2013 22:31:06 -0400
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: Av4EABK/CFG4rw3m/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLDiYSFBgNJIgeBsEtkQoDpHqBXoMT
X-IPAS-Result: Av4EABK/CFG4rw3m/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLDiYSFBgNJIgeBsEtkQoDpHqBXoMT
X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="20400346"
Received: from 184-175-13-230.dsl.teksavvy.com (HELO pastel.home)
 ([184.175.13.230])
 by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA;
 01 Aug 2013 22:30:53 -0400
Received: by pastel.home (Postfix, from userid 20848)
 id A894B63C70; Thu,  1 Aug 2013 22:30:59 -0400 (EDT)
From: Stefan Monnier <monnier@HIDDEN>
To: Kevin Ryde <user42@HIDDEN>
Subject: Re: bug#15006: 24.3; emacs manual comment-start-skip example grouping
Message-ID: <jwvk3k4esie.fsf-monnier+emacs@HIDDEN>
References: <87mwp0x6hn.fsf@HIDDEN> <jwvvc3oev09.fsf-monnier+emacs@HIDDEN>
 <8738qsx3nb.fsf@HIDDEN>
Date: Thu, 01 Aug 2013 22:30:59 -0400
In-Reply-To: <8738qsx3nb.fsf@HIDDEN> (Kevin Ryde's message of "Fri, 02 Aug
 2013 11:50:00 +1000")
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.3 (/)
X-Debbugs-Envelope-To: 15006
Cc: 15006 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.3 (/)

> Actually I see the cc-mode code uses it with a group.  And js.el too
> (perhaps copying cc-mode).  Does it have some subtle effect of skipping
> the /*, or is it outright wrong?

It's wrong.  But cc-mode likes to reinvent the wheel, so maybe
it doesn't use much of that code anyway.

>> Yes, I prefer to stay away from "whitepace syntax" for that reason and
>> would recommend [ \t]* in its stead.
> I suppose the intention is to pick up non-breaking spaces or whatever
> other flavours of whitespace.  Unlikely to arise in practice in
> programming language stuff.  Is there an obvious ill effect?

You can get things like (re-search-forward comment-start-skip) and end
up with (match-end 0) past the end of the matched comment (e.g. when
matching "//\n").


        Stefan




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#15006; Package emacs. Full text available.

Message received at 15006 <at> debbugs.gnu.org:


Received: (at 15006) by debbugs.gnu.org; 2 Aug 2013 01:50:38 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Aug 01 21:50:38 2013
Received: from localhost ([127.0.0.1]:35580 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1V54Vo-00008x-Gm
	for submit <at> debbugs.gnu.org; Thu, 01 Aug 2013 21:50:37 -0400
Received: from mailout1-11.pacific.net.au ([125.255.80.130]:43988
 helo=mailout3-syd3.pacific.net.au)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <gg@HIDDEN>) id 1V54Vl-00008l-94
 for 15006 <at> debbugs.gnu.org; Thu, 01 Aug 2013 21:50:35 -0400
Received: from mailproxy3-syd3.pacific.net.au (mailproxy3-syd3.pacific.net.au
 [61.8.2.164])
 by mailout3-syd3.pacific.net.au (Postfix) with ESMTP id 965CD3A1D1F;
 Fri,  2 Aug 2013 11:50:30 +1000 (EST)
Received: from blah.blah (unknown [203.26.175.75])
 by mailproxy3-syd3.pacific.net.au (Postfix) with ESMTP id 2168657808A;
 Fri,  2 Aug 2013 11:50:25 +1000 (EST)
Received: from gg by blah.blah with local (Exim 4.80)
 (envelope-from <gg@HIDDEN>)
 id 1V54VE-00019d-Ll; Fri, 02 Aug 2013 11:50:00 +1000
From: Kevin Ryde <user42@HIDDEN>
To: Stefan Monnier <monnier@HIDDEN>
Subject: Re: bug#15006: 24.3; emacs manual comment-start-skip example grouping
References: <87mwp0x6hn.fsf@HIDDEN> <jwvvc3oev09.fsf-monnier+emacs@HIDDEN>
Date: Fri, 02 Aug 2013 11:50:00 +1000
In-Reply-To: <jwvvc3oev09.fsf-monnier+emacs@HIDDEN> (Stefan Monnier's message
 of "Thu, 01 Aug 2013 21:34:57 -0400")
Message-ID: <8738qsx3nb.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 15006
Cc: 15006 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.0 (/)

Stefan Monnier <monnier@HIDDEN> writes:
>
>> If I understand the comment-start-skip docstring correctly a \(..\)
>> group is for extra distinguishing text preceding the comment.  Should
>> that example be a shy group,
>
> Indeed, thank you.

Actually I see the cc-mode code uses it with a group.  And js.el too
(perhaps copying cc-mode).  Does it have some subtle effect of skipping
the /*, or is it outright wrong?

> Yes, I prefer to stay away from "whitepace syntax" for that reason and
> would recommend [ \t]* in its stead.

I suppose the intention is to pick up non-breaking spaces or whatever
other flavours of whitespace.  Unlikely to arise in practice in
programming language stuff.  Is there an obvious ill effect?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#15006; Package emacs. Full text available.

Message received at 15006 <at> debbugs.gnu.org:


Received: (at 15006) by debbugs.gnu.org; 2 Aug 2013 01:35:06 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Aug 01 21:35:06 2013
Received: from localhost ([127.0.0.1]:35543 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1V54Gn-0006wr-6k
	for submit <at> debbugs.gnu.org; Thu, 01 Aug 2013 21:35:05 -0400
Received: from ironport2-out.teksavvy.com ([206.248.154.182]:17422)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <monnier@HIDDEN>) id 1V54Gl-0006wC-Bj
 for 15006 <at> debbugs.gnu.org; Thu, 01 Aug 2013 21:35:04 -0400
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: Av4EABK/CFG4rw3m/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLDiYSFBgNJIgeBsEtkQoDpHqBXoMT
X-IPAS-Result: Av4EABK/CFG4rw3m/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLDiYSFBgNJIgeBsEtkQoDpHqBXoMT
X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="20398480"
Received: from 184-175-13-230.dsl.teksavvy.com (HELO pastel.home)
 ([184.175.13.230])
 by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA;
 01 Aug 2013 21:34:50 -0400
Received: by pastel.home (Postfix, from userid 20848)
 id 203FB63C70; Thu,  1 Aug 2013 21:34:57 -0400 (EDT)
From: Stefan Monnier <monnier@HIDDEN>
To: Kevin Ryde <user42@HIDDEN>
Subject: Re: bug#15006: 24.3; emacs manual comment-start-skip example grouping
Message-ID: <jwvvc3oev09.fsf-monnier+emacs@HIDDEN>
References: <87mwp0x6hn.fsf@HIDDEN>
Date: Thu, 01 Aug 2013 21:34:57 -0400
In-Reply-To: <87mwp0x6hn.fsf@HIDDEN> (Kevin Ryde's message of "Fri, 02 Aug
 2013 10:48:36 +1000")
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.3 (/)
X-Debbugs-Envelope-To: 15006
Cc: 15006 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.3 (/)

> If I understand the comment-start-skip docstring correctly a \(..\)
> group is for extra distinguishing text preceding the comment.  Should
> that example be a shy group,

Indeed, thank you.

> I also wondered whether the whitespace "\\s *" in the example was a
> little too loose since it matches \n and leading whitespace of the next
> line too.  Does that matter to anything?

Yes, I prefer to stay away from "whitepace syntax" for that reason and
would recommend [ \t]* in its stead.


        Stefan




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#15006; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 2 Aug 2013 00:49:42 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Aug 01 20:49:42 2013
Received: from localhost ([127.0.0.1]:35518 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1V53Yr-00056n-KI
	for submit <at> debbugs.gnu.org; Thu, 01 Aug 2013 20:49:41 -0400
Received: from eggs.gnu.org ([208.118.235.92]:57787)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <gg@HIDDEN>) id 1V53Yo-00056F-92
 for submit <at> debbugs.gnu.org; Thu, 01 Aug 2013 20:49:39 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <gg@HIDDEN>) id 1V53YZ-0002q5-D3
 for submit <at> debbugs.gnu.org; Thu, 01 Aug 2013 20:49:33 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=-100.0 required=5.0 tests=BAYES_20, USER_IN_WHITELIST
 autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:56512)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <gg@HIDDEN>) id 1V53YZ-0002q1-AY
 for submit <at> debbugs.gnu.org; Thu, 01 Aug 2013 20:49:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59409)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <gg@HIDDEN>) id 1V53YQ-0003U6-VA
 for bug-gnu-emacs@HIDDEN; Thu, 01 Aug 2013 20:49:23 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <gg@HIDDEN>) id 1V53YI-0002kq-Hj
 for bug-gnu-emacs@HIDDEN; Thu, 01 Aug 2013 20:49:14 -0400
Received: from mailout2-12.pacific.net.au ([125.255.80.139]:46330
 helo=mailout4-syd3.pacific.net.au)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <gg@HIDDEN>) id 1V53YI-0002k9-4q
 for bug-gnu-emacs@HIDDEN; Thu, 01 Aug 2013 20:49:06 -0400
Received: from mailproxy4-syd3.pacific.net.au (mailproxy4-syd3.pacific.net.au
 [61.8.2.162])
 by mailout4-syd3.pacific.net.au (Postfix) with ESMTP id E8C5C470D1A
 for <bug-gnu-emacs@HIDDEN>; Fri,  2 Aug 2013 10:49:00 +1000 (EST)
Received: from blah.blah (unknown [203.26.175.75])
 by mailproxy4-syd3.pacific.net.au (Postfix) with ESMTP id C27982C025
 for <bug-gnu-emacs@HIDDEN>; Fri,  2 Aug 2013 10:48:59 +1000 (EST)
Received: from gg by blah.blah with local (Exim 4.80)
 (envelope-from <gg@HIDDEN>) id 1V53Xo-0005rB-Bg
 for bug-gnu-emacs@HIDDEN; Fri, 02 Aug 2013 10:48:36 +1000
From: Kevin Ryde <user42@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: 24.3; emacs manual comment-start-skip example grouping
Date: Fri, 02 Aug 2013 10:48:36 +1000
Message-ID: <87mwp0x6hn.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -3.4 (---)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.4 (---)

In the emacs manual info node "(emacs)Options for Comments" an example
comment-start-skip is given

    "\\(//+\\|/\\*+\\)\\s *"

If I understand the comment-start-skip docstring correctly a \(..\)
group is for extra distinguishing text preceding the comment.  Should
that example be a shy group, or perhaps expanded out to ungroup like
vera-mode.el has?

    "/\\*+ *\\|//+ *"

I also wondered whether the whitespace "\\s *" in the example was a
little too loose since it matches \n and leading whitespace of the next
line too.  Does that matter to anything?



In GNU Emacs 24.3.1 (i486-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2013-05-29 on blah.blah, modified by Debian
System Description:	Debian GNU/Linux 7.0 (wheezy)

Configured using:
 `configure '--build' 'i486-linux-gnu' '--build' 'i486-linux-gnu'
 '--prefix=/usr' '--sharedstatedir=/var/lib' '--libexecdir=/usr/lib'
 '--localstatedir=/var/lib' '--infodir=/usr/share/info'
 '--mandir=/usr/share/man' '--with-pop=yes'
 '--enable-locallisppath=/etc/emacs24:/etc/emacs:/usr/local/share/emacs/24.3/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/24.3/site-lisp:/usr/share/emacs/site-lisp'
 '--with-crt-dir=/usr/lib/i386-linux-gnu' '--with-x=yes'
 '--with-x-toolkit=lucid' '--with-toolkit-scroll-bars' '--without-gconf'
 'build_alias=i486-linux-gnu' 'CFLAGS=-g -O2 -fstack-protector
 --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall'
 'LDFLAGS=-Wl,-z,relro -Wl,-znocombreloc'
 'CPPFLAGS=-D_FORTIFY_SOURCE=2''

Important settings:
  value of $LANG: en_AU
  locale-coding-system: iso-latin-1-unix
  default enable-multibyte-characters: t




Acknowledgement sent to Kevin Ryde <user42@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#15006; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Fri, 31 Oct 2014 17:00:04 UTC

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