From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.help Subject: RE: test for shy-group "feature"? Date: Fri, 9 Dec 2005 19:42:18 -0800 Message-ID: References: <85ek4l208u.fsf@lola.goethe.zz> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1134186239 32558 80.91.229.2 (10 Dec 2005 03:43:59 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 10 Dec 2005 03:43:59 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Dec 10 04:43:57 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1EkvdM-0007Or-0Z for geh-help-gnu-emacs@m.gmane.org; Sat, 10 Dec 2005 04:42:52 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ekvdh-00030H-Kr for geh-help-gnu-emacs@m.gmane.org; Fri, 09 Dec 2005 22:43:13 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1EkvdP-00030B-4r for help-gnu-emacs@gnu.org; Fri, 09 Dec 2005 22:42:55 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1EkvdN-0002z8-Ih for help-gnu-emacs@gnu.org; Fri, 09 Dec 2005 22:42:54 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EkvdN-0002yv-DQ for help-gnu-emacs@gnu.org; Fri, 09 Dec 2005 22:42:53 -0500 Original-Received: from [141.146.126.228] (helo=agminet01.oracle.com) by monty-python.gnu.org with esmtp (TLS-1.0:DHE_RSA_3DES_EDE_CBC_SHA:24) (Exim 4.34) id 1Ekveg-0002xT-84 for help-gnu-emacs@gnu.org; Fri, 09 Dec 2005 22:44:14 -0500 Original-Received: from rgmsgw301.us.oracle.com (rgmsgw301.us.oracle.com [138.1.186.50]) by agminet01.oracle.com (Switch-3.1.7/Switch-3.1.7) with ESMTP id jBA3xnUM005475 for ; Fri, 9 Dec 2005 21:59:49 -0600 Original-Received: from rgmsgw301.us.oracle.com (localhost [127.0.0.1]) by rgmsgw301.us.oracle.com (Switch-3.1.7/Switch-3.1.7) with ESMTP id jBA3gR3F023374 for ; Fri, 9 Dec 2005 20:42:27 -0700 Original-Received: from dradamslap (dhcp-amer-rmdc-csvpn-gw5-141-144-105-225.vpn.oracle.com [141.144.105.225]) by rgmsgw301.us.oracle.com (Switch-3.1.7/Switch-3.1.7) with SMTP id jBA3gQBx023366 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NO) for ; Fri, 9 Dec 2005 20:42:26 -0700 Original-To: X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) In-reply-to: <85ek4l208u.fsf@lola.goethe.zz> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1506 X-Brightmail-Tracker: AAAAAQAAAAI= X-Whitelist: TRUE X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:31840 Archived-At: > Emacs 22 has shy groups for regexps; previous versions did not. Wrong. ** Regular expressions now support intervals \{n,m\} as well as Perl's shy-groups \(?:...\) and non-greedy *? +? and ?? operators. Also back-references like \2 are now considered as an error if the corresponding subgroup does not exist (or is not closed yet). Previously it would have been silently turned into `2' (ignoring the `\'). I didn't find any reference to "shy" by grepping the source code. Thanks for looking in News. > When writing conditional code that tries to work with multiple Emacs > versions, it is usually better to test fboundp, boundp, or > featurep, than it > is to test the major version. I couldn't find any function, > variable, or > feature associated with this new "feature", shy groups. Is > there one that I > might have missed? Thanks. (if (string-match "\\(?:\\)" "") ... ...) Very good (elegant - it even acts as an explanatory comment). Thanks.