Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:74466 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 13092 invoked from network); 23 May 2014 17:29:02 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 23 May 2014 17:29:02 -0000 Authentication-Results: pb1.pair.com header.from=tyra3l@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=tyra3l@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.192.41 as permitted sender) X-PHP-List-Original-Sender: tyra3l@gmail.com X-Host-Fingerprint: 209.85.192.41 mail-qg0-f41.google.com Received: from [209.85.192.41] ([209.85.192.41:47066] helo=mail-qg0-f41.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id B2/48-01753-9558F735 for ; Fri, 23 May 2014 13:28:57 -0400 Received: by mail-qg0-f41.google.com with SMTP id j5so8614243qga.28 for ; Fri, 23 May 2014 10:28:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=8xdub/4JXHplo0g3N3LHm0tNJX6i+0wfkG/BCJiKLwI=; b=CpGSFzyuUpIwS7nsARlbgRaso39wr1+GNioUOQI3ArPyu0FsN8c9qiLeDx3flWUlTL aM+AmFMA7bWDMn9CG2TsZ5hfH3DfHhN5vSpSKEi1j06hLqTfmngC69LN2qKmwjsgpThH nguH2xzYmm9J1xz9w9cwvpeIdPPqHw0AaYx0Yzq1VyTN01vhe+E3/MA/cg9R49WU04Mu eNJwlBgZjU505mCRI41YpI7od1Cs8I8TUsWR/23uYCA4GLJ8c5LKMOrG7eAHsSu5OZGC 8VUWcMF4dFO7YRri3zXeNXTKs0gvb/nNKIi1cAl5gQsDqySL3vfp0NgAaCXrw4PRxChK 6D7A== MIME-Version: 1.0 X-Received: by 10.224.14.79 with SMTP id f15mr9005394qaa.96.1400866134691; Fri, 23 May 2014 10:28:54 -0700 (PDT) Sender: tyra3l@gmail.com Received: by 10.140.17.77 with HTTP; Fri, 23 May 2014 10:28:54 -0700 (PDT) Received: by 10.140.17.77 with HTTP; Fri, 23 May 2014 10:28:54 -0700 (PDT) In-Reply-To: References: <2DC459EE-AE98-4CAE-977A-6FB918FDEF54@bafford.com> <537EA42B.4000000@lerdorf.com> Date: Fri, 23 May 2014 19:28:54 +0200 X-Google-Sender-Auth: uTzYgDA_RQD1c2AqdlJTgLw24U0 Message-ID: To: Julien Pauli Cc: John Bafford , Pierre Joye , Rasmus Lerdorf , PHP internals Content-Type: multipart/alternative; boundary=047d7bdc80fc5616f304fa149019 Subject: Re: [PHP-DEV] Bison 3 support for PHP 5.5 From: tyrael@php.net (Ferenc Kovacs) --047d7bdc80fc5616f304fa149019 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable 2014.05.23. 13:59, "Julien Pauli" ezt =C3=ADrta: > > On Fri, May 23, 2014 at 8:40 AM, Pierre Joye wrote= : > > Hi John, > > > > On Fri, May 23, 2014 at 3:44 AM, John Bafford wrote: > >> Hi Rasmus, > >> > >> On May 22, 2014, at 20:28, Rasmus Lerdorf wrote: > >> > >>> On 5/22/14, 6:01 PM, John Bafford wrote: > >>>> Hi, > >>>> > >>>> I=E2=80=99ve submitted a PR (https://github.com/php/php-src/pull/683= ) to add support for Bison 3.0 to PHP 5.5. > >>>> > >>>> I=E2=80=99ve run the tests on this patch, with no unexpected errors,= with Bison 2.4 (minimum version for PHP 5.5 and 5.6), 2.7, and 3.0, with and without --enable-maintainer-zts against the current PHP-5.5 and (with minor changes) master branches. > >>> > >>> Could you explain your changes a bit? You removed %pure-parser, for > >>> example, and you shuffled globals around. This looks like more than just > >>> adding support for Bison 3. > >>> > >>> -Rasmus > >> > >> I replaced %pure-parser (which was deprecated) with %pure_parser (its replacement). (Also, YYERROR_VERBOSE, which also was deprecated, with %error-verbose.) > >> > >> Most of the changes in the PR revolve around this change in Zend/zend_language_parser.y: > >> -%code requires { > >> -#ifdef ZTS > >> -# define YYPARSE_PARAM tsrm_ls > >> -# define YYLEX_PARAM tsrm_ls > >> -#endif > >> -} > >> +%parse-param { void *tsrm_ls } > >> +%lex-param { void *tsrm_ls } > >> > >> YYPARSE_PARAM and YYLEX_PARAM were deprecated, and then removed, and replaced with %parse-param and %lex-param. However, you cannot (or I did not see a way to) conditionally define parameters, as PHP was previously doing here. > >> > >> So instead, I created the TSRMLS_DN and TSRMLS_CN macros which, in the ZTS case, work like TSRMLS_D/TSRMLS_C, but when ZTS is off, still resolve to a parameter (that must always be present), which is passed NULL. > > > > Thanks for your work, always good to support less archaic version of bison. > > > > Some comments: > > > > - does it still work with previous versions? If yes, do you know which > > or which minimum version we should then require? > > - 5.5 is stable, I am not sure it is a good idea to do these changes > > there. 5.6 may be a good candidate (but has to be done quickly, RMs > > can confirm if it is still possible) > > That's a no-go for 5.5. > 5.5 is stable, 1year old (at this email date), and we should not > change such a thing into this stable branch. > > For 5.6, we are actually in RC stage (with first RC to come soon). > Seeing the comments saying that it's all compatible and tests have > passed, I'm not against requiring bison 3.x for PHP 5.6. > Waiting for Ferenc's answer ;-) > > Thank you for your patch and your support to make PHP better. > > Julien Pauli I would be fine with this change, even it happens after the first RC, given that it could only affect people, who are building php from source and not using the official release tarballs. --047d7bdc80fc5616f304fa149019--