From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Fixing ill-conditioned regular expressions. Proof of concept. Date: Fri, 27 Feb 2015 08:45:37 -0500 Message-ID: References: <20150223224245.GC2861@acm.fritz.box> <54EBB9C4.1020505@cs.ucla.edu> <20150225100834.GA3502@acm.fritz.box> <54EEDD82.4010502@cs.ucla.edu> <20150226101137.GA19320@acm.fritz.box> <87fv9tc4qm.fsf@gnu.org> <20150226130917.GC19320@acm.fritz.box> <20150226162119.GD19320@acm.fritz.box> <20150226200108.GE19320@acm.fritz.box> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1425044776 16932 80.91.229.3 (27 Feb 2015 13:46:16 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 27 Feb 2015 13:46:16 +0000 (UTC) Cc: Paul Eggert , emacs-devel@gnu.org To: Alan Mackenzie Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Feb 27 14:46:00 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YRLEr-0005tV-VP for ged-emacs-devel@m.gmane.org; Fri, 27 Feb 2015 14:45:58 +0100 Original-Received: from localhost ([::1]:36452 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YRLEh-0004Ow-7j for ged-emacs-devel@m.gmane.org; Fri, 27 Feb 2015 08:45:47 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40145) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YRLEd-0004LM-J5 for emacs-devel@gnu.org; Fri, 27 Feb 2015 08:45:44 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YRLEa-0002ax-1u for emacs-devel@gnu.org; Fri, 27 Feb 2015 08:45:43 -0500 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:39841) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YRLEZ-0002af-Sb for emacs-devel@gnu.org; Fri, 27 Feb 2015 08:45:39 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ArsTAPOG1lRsoXmY/2dsb2JhbABbgwaDX4VTwGUEAgKBDUQBAQEBAQF8hA0BBAFWIwULCw4mEhQYDSSIOAjOIwEBAQcBAQEBAR2PeAeEKgWKJ59LgUUiggIcgW4ggnMBAQE X-IPAS-Result: ArsTAPOG1lRsoXmY/2dsb2JhbABbgwaDX4VTwGUEAgKBDUQBAQEBAQF8hA0BBAFWIwULCw4mEhQYDSSIOAjOIwEBAQcBAQEBAR2PeAeEKgWKJ59LgUUiggIcgW4ggnMBAQE X-IronPort-AV: E=Sophos;i="5.09,536,1418101200"; d="scan'208";a="111796110" Original-Received: from 108-161-121-152.dsl.teksavvy.com (HELO pastel.home) ([108.161.121.152]) by ironport2-out.teksavvy.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 27 Feb 2015 08:45:38 -0500 Original-Received: by pastel.home (Postfix, from userid 20848) id DBC701088; Fri, 27 Feb 2015 08:45:37 -0500 (EST) In-Reply-To: <20150226200108.GE19320@acm.fritz.box> (Alan Mackenzie's message of "Thu, 26 Feb 2015 20:01:08 +0000") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.181 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:183527 Archived-At: > I really did mean R*\(\)R*, with R being the same on both sides of the > \(\), but the *s possibly being +s. Ah, well R*R* where can match the empty string is definitely nasty given the current implementation technique of our regexp matcher, yes. It's not specific to \(\), OTOH. > _That_ is nasty and undefined. Well, it's actually defined (by the "leftmost longest" rule), but I agree it's a nasty case. Stefan