Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:87710 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 82746 invoked from network); 11 Aug 2015 17:56:05 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 11 Aug 2015 17:56:05 -0000 Authentication-Results: pb1.pair.com header.from=cmbecker69@gmx.de; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=cmbecker69@gmx.de; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmx.de designates 212.227.17.21 as permitted sender) X-PHP-List-Original-Sender: cmbecker69@gmx.de X-Host-Fingerprint: 212.227.17.21 mout.gmx.net Received: from [212.227.17.21] ([212.227.17.21:53886] helo=mout.gmx.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id C6/92-00789-2373AC55 for ; Tue, 11 Aug 2015 13:56:02 -0400 Received: from [192.168.0.100] ([91.67.244.142]) by mail.gmx.com (mrgmx102) with ESMTPSA (Nemesis) id 0LjLwB-1YomtZ1YP1-00dWrW; Tue, 11 Aug 2015 19:55:54 +0200 Message-ID: <55CA372B.8040006@gmx.de> Date: Tue, 11 Aug 2015 19:55:55 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Adam Harvey CC: PHP internals References: <55CA26DF.3030109@gmx.de> In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K0:t6tXVZgHC1AxgIAynEetIi+A/9hqpl4IA6OetHUcSd7jMviFmsZ nSCebyy7i/7Ia+tW5gh0r3qdAyAeBWv2MBLEiaI7noA45VHfVOtTerkJ0ViZXfs1sb8a81R vrNyiQXy7JMjl6YBTdZmLJJOuEGBinAaD81EB7nCFoLWdBC5BGCwANWy+IT+Dg1gffTyTAl AAGDAqCwrmyjs8ZWZEOOQ== X-UI-Out-Filterresults: notjunk:1;V01:K0:8DZwPhSTcA4=:ZhqiCQFS07ZmF9WrF90VLC Xdh8onxafS7iefcDTSYk93sK6XQyWaKz/+Dd30liOfhWejGSYJyKRYzrlyylmFLKW21RURl8c 12kbIhY2WWU57oObQuSdXyk5RoNRKHrJFYQn5VoY2NwS39ascn0CXuHDjlXd3e5sEltCy3/H0 3yi4WfGapJEbDGnDINBZOjkmpyUeSZuhFSQWAtOM8+MI+YI4JZIFvnZc+uUbwkuJG9jmNxkKe 9Bi/FSMLJ7DNTYt+8A1ycHzMI13yHlPK1Dug0v9GS89vqA++8xT0Z24NxMsEoOOzlfytQ6h+5 SXyhuQPa8EhwcnQynpV/j0oSTXa5DXqd+HjEzlYPt2DPEa6CN2lT10iqd4eEAEoGXC4UFb/TF j8r5uqPb0K6UVwNwzvQQLQxmG3Je1SfKmr4roxK68KlZxd9tspg4iqXp5LaE1z12S43FP7hjV RcTCqTWpUHNhutAFTtIKF2k8ZYz7rGEb2vxvY2hogCcCqoHd3AUxDhheceEo7kCjU0RBWJy/x fPbmYrtZrg9nQvV5nuVqHNxyvlS0bsMzQ67UW3XGGbToiThRlQWFa5eHcaEjp0mBDYKICIm4f YK3yzEZ7KDmaB8RkzUzC2PaeIDx6LG/gURqoDNW+35pWgtLj0w518IG4KiZwsxcXfHv7jTIP5 WH6im8qLkrGB0U0u0k5y+W8dRRo34lMAvG5RsHIzAZJyL//hONgvykHP8ANFcHknfnQa1R79C cN0RKp2HWc6N76yRn2C+P5pGLJ1THajpM/brSg== Subject: Re: [PHP-DEV] libpcre version requirements From: cmbecker69@gmx.de (Christoph Becker) On 11.08.2015 at 19:01, Adam Harvey wrote: > On 11 August 2015 at 09:46, Christoph Becker wrote: >> What is the minimum libpcre version that is supported as external >> libpcre for ext/pcre? According to config0.m4 it is PCRE 6.6 >> (2006-02-06), but is this still valid and do we really have to support >> such old versions? > > CentOS/RHEL 5 provides libpcre 6.6, which is probably where that > specific minimum version comes from. Someone out there is probably > still building packages that rely on this. FWIW, this PCRE 6.6 requirement has been introduced with commit 1ad21d9b in May 2006, thus before CentOS/RHEL 5.0 had been released. It seems to me that nobody simply touched this requirement since then. Actually some features already require more recent libpcre, for instance, the \K modifier requires PCRE 7.2. >> I'm asking because of bug #70232 which can easily be fixed, but that >> requires PCRE 8.00 (2009-10-19). If we have to support older PCRE >> versions, we'd probably need a fallback to the current behavior (which >> would obviously keep the bug). > > I guess the question's really whether we should still support an > _external_ libpcre that old, since we bundle much newer versions. I > think the argument against changing it has always been that it works > and we didn't need anything newer, but if we have a reason now then > that doesn't really hold. > > One problem is that I don't think we can really change the minimum > requirement on a stable branch, so for 5.5 and 5.6 we're going to have > to implement something that works with older versions regardless, but > I'd be for bumping the minimum version requirement for 7.0 if it makes > the code cleaner (on that branch, at least) moving forward. I don't know if we can implement a fully working fallback for PCRE < 8 in a viable way. Actually, PCRE_NOTEMPTY_ATSTART had been added to libpcre to solve the issue with \K for /g[1]. Note the wording of the commit message: | Added PCRE_NOTEMPTY_ATSTART in order to be able to correctly | implement the /g option in pcretest when the pattern contains \K, | [...] My best idea so far is to use PCRE_NOTEMPTY_ATSTART and to fallback to PCRE_NOTEMPTY, if the former is not available. Of course the bug would persist for old libpcre, but \K will not be effective for PCRE 6.6 anyway. [1] -- Christoph M. Becker