Re: [PHP-DEV] Change default branch in GitHub for php-src

2019-02-22 Thread Sebastian Bergmann

On 2/22/19 7:00 PM, Gabriel Caruso wrote:

So, I'd like to propose that the default branch should be *`PHP-7.4`*.


Makes sense to me.

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-DEV] Change default branch in GitHub for php-src

2019-02-22 Thread Gabriel Caruso
Hi everyone, how are you doing?

I'd like to discuss the change of the default branch in GitHub for
`php-src`. Today, the default branch is `master`, aka PHP 8.0, but, the
development of `PHP 7.4` is still ongoing, and there's a lot of stuff that
we should merge into it, instead of just master. There're a couple of
examples that we constantly change from `master` to `PHP-7.4`.

So, I'd like to propose that the default branch should be *`PHP-7.4`*.

Best,
-- 
Gabriel Caruso


[PHP-DEV] Notes on RFCs that didn't get approved

2019-02-22 Thread Dan Ackroyd
Hi internals,

fyi I have made some notes on previous RFCs that seemed to be well
received in general but then didn't actually get approved.

https://github.com/danack/RfcCodex

The aim of these notes is to make it easier for people to see what
happened to those previous RFCs and what hurdles they might need to
overcome, if and when someone wants to revisit them.

I'm planning to keep adding notes about the RFCs that seem more
important to me, but not to be a comprehensive list.

cheers
Dan
Ack

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DEV] Re: Revive old "anonymous exception" RFC

2019-02-22 Thread Rowan Collins
On Fri, 22 Feb 2019 at 16:24, Dan Ackroyd  wrote:

> On Fri, 22 Feb 2019 at 13:28, Christoph M. Becker 
> wrote:
> >
> > However, before editing that RFC, please
> > try to reach out to the original author asking for permission.
>
> Or, better yet imo, please create a new document, referencing the
> earlier document.
>


Just make sure if you're calling it "v2" that it shouldn't actually be
"v3", as happened with https://wiki.php.net/rfc/typed-properties-v2 and
https://wiki.php.net/rfc/typed_properties_v2 :)

Regards,
-- 
Rowan Collins
[IMSoP]


Re: [PHP-DEV] Re: Revive old "anonymous exception" RFC

2019-02-22 Thread Dan Ackroyd
On Fri, 22 Feb 2019 at 13:28, Christoph M. Becker  wrote:
>
> However, before editing that RFC, please
> try to reach out to the original author asking for permission.

Or, better yet imo, please create a new document, referencing the
earlier document.

I've been doing some work recently to summarise what is the status of
some RFCs that have been discussed repeatedly (which I'll post in a
new thread), and one of the problems I had with doing that was with
RFCs where the same document has been used for multiple attempts. It
made correlating the discussions with what was in the RFC document at
the time of the discussions quite difficult.

cheers
Dan

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DEV][RFC] Cast in foreach

2019-02-22 Thread Chris Riley
Cast would work for both key and value, although I think the instances
where you need to cast a key will be fewer.

On Thu, Feb 21, 2019, 15:08 Legale.legale  wrote:

> what about:
>
> foreach($array as $i=>$v) {}
>
> ?On Feb 21, 2019 13:15, Chris Riley  wrote:
> >
> > Hi internals,
> >
> > I'd like to propose opening an rfc to make the following syntax legal:
> >
> > foreach($array as (int) $i) {}
> >
> > Which would be functionally equivalent to
> >
> > foreach($array as $i) {
> > $i=(int) $i;
> > }
> >
> > Thoughts? Feedback?
> > ~C
>


Re: [PHP-DEV][RFC] Cast in foreach

2019-02-22 Thread Chris Riley
In this instance, I would expect the cast to come before each variable
eg foreach ($data as ["id" => (int) $id, "name" => (string) $name])

On Thu, Feb 21, 2019, 13:28 Kalle Sommer Nielsen  wrote:

> Den tor. 21. feb. 2019 kl. 14.16 skrev Chris Riley :
> >
> > Hi internals,
> >
> > I'd like to propose opening an rfc to make the following syntax legal:
> >
> > foreach($array as (int) $i) {}
>
> How would this interact with the foreach-list syntax?
>
> $data = [
> ["id" => 1, "name" => 'Tom'],
> ["id" => 2, "name" => 'Fred'],
> ];
>
> foreach ($data as ["id" => $id, "name" => $name]) {
> echo "id: $id, name: $name\n";
> }
>
> Having something like:
> foreach ($data as (int) ["id" => $id, "name" => $name]) {
>
> Would then make both $id and $name integers?
>
> --
> regards,
>
> Kalle Sommer Nielsen
> ka...@php.net
>


[PHP-DEV] Re: Revive old "anonymous exception" RFC

2019-02-22 Thread Christoph M. Becker
On 22.02.2019 at 13:28, Roland Franssen wrote:

> I would like to restart the discussion for RFC
> https://wiki.php.net/rfc/anonymous_catch (
> http://news.php.net/php.webmaster/16065)
> 
> It dates back to 2013, however, I think in general it still applies today.
> I can make the necessary changes if needed, but for this i need feedback
> and possibly permissions to edit the RFC. (Wiki username=ro0nl)

You should have RFC karma now.  However, before editing that RFC, please
try to reach out to the original author asking for permission.

-- 
Christoph M. Becker

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DEV] [RFC] JIT

2019-02-22 Thread Dmitry Stogov
Thanks to Anatol, who started working on Windows build and "enforced" me 
to implement MSVC support :)

On 2/22/19 3:21 PM, Joe Watkins wrote:
> Thanks for all the effort Dmitry, it's looking in much better shape.
> 
> Cheers
> Joe
> 
> On Fri, 22 Feb 2019 at 13:18, Dmitry Stogov  > wrote:
> 
> Hi Internals,
> 
> 
> The RFC and implementation was updated once again.
> 
> 
> https://wiki.php.net/rfc/jit
> 
> 
> Now JIT supports PHP builds with compilers without GCC explicit
> global register variables extension.
> 
> This means we support CLANG/LLVM (Tested on Linux. Should work on
> Mac as well) and MSVC.
> 
> Complete Windows support is not implemented yet, but I don't see any
> big problems anymore.
> 
> 
> ZTS support might be implemented after implementation of proposed
> TSRM API improvement.
> 
> 
> Thanks. Dmitry.
> 
> 
> 
> From: Dmitry Stogov mailto:dmi...@zend.com>>
> Sent: Wednesday, February 13, 2019 16:07
> To: PHP internals
> Subject: Re: [PHP-DEV] [RFC] JIT
> 
> Hi Internals,
> 
> According to comments, code reviews and discussions, JIT RFC was
> extended with few new sections.
> 
> Please, consider to review the RFC once again.
> 
> https://wiki.php.net/rfc/jit
> 
> Any suggestion for RFC improvement are welcome.
> 
> I'm not going to invest significant time into JIT implementation
> improvement itself, at this point. So, ideas are also welcome, but don't
> expect to get them implemented tomorrow.
> 
> Thanks. Dmitry.
> 
> On 1/31/19 12:43 PM, Dmitry Stogov wrote:
>  > Hi Internals,
>  >
>  >
>  > I'm glad to finally propose including JIT into PHP.
>  >
>  >
>  > https://wiki.php.net/rfc/jit
>  >
>  >
>  > In the current state it may be included both into PHP-8, where we are
>  > going to continue active improvement, and into PHP-7.4, as an
>  > experimental feature.
>  >
>  >
>  > Thanks. Dmitry.
>  >
> 


[PHP-DEV] Revive old "anonymous exception" RFC

2019-02-22 Thread Roland Franssen
Hi Internals,

I would like to restart the discussion for RFC
https://wiki.php.net/rfc/anonymous_catch (
http://news.php.net/php.webmaster/16065)

It dates back to 2013, however, I think in general it still applies today.
I can make the necessary changes if needed, but for this i need feedback
and possibly permissions to edit the RFC. (Wiki username=ro0nl)

This request supersedes https://externals.io/message/104491

Cheers,
Roland Franssen


Re: [PHP-DEV] [RFC] JIT

2019-02-22 Thread Joe Watkins
Thanks for all the effort Dmitry, it's looking in much better shape.

Cheers
Joe

On Fri, 22 Feb 2019 at 13:18, Dmitry Stogov  wrote:

> Hi Internals,
>
>
> The RFC and implementation was updated once again.
>
>
> https://wiki.php.net/rfc/jit
>
>
> Now JIT supports PHP builds with compilers without GCC explicit global
> register variables extension.
>
> This means we support CLANG/LLVM (Tested on Linux. Should work on Mac as
> well) and MSVC.
>
> Complete Windows support is not implemented yet, but I don't see any big
> problems anymore.
>
>
> ZTS support might be implemented after implementation of proposed TSRM API
> improvement.
>
>
> Thanks. Dmitry.
>
>
> 
> From: Dmitry Stogov 
> Sent: Wednesday, February 13, 2019 16:07
> To: PHP internals
> Subject: Re: [PHP-DEV] [RFC] JIT
>
> Hi Internals,
>
> According to comments, code reviews and discussions, JIT RFC was
> extended with few new sections.
>
> Please, consider to review the RFC once again.
>
> https://wiki.php.net/rfc/jit
>
> Any suggestion for RFC improvement are welcome.
>
> I'm not going to invest significant time into JIT implementation
> improvement itself, at this point. So, ideas are also welcome, but don't
> expect to get them implemented tomorrow.
>
> Thanks. Dmitry.
>
> On 1/31/19 12:43 PM, Dmitry Stogov wrote:
> > Hi Internals,
> >
> >
> > I'm glad to finally propose including JIT into PHP.
> >
> >
> > https://wiki.php.net/rfc/jit
> >
> >
> > In the current state it may be included both into PHP-8, where we are
> > going to continue active improvement, and into PHP-7.4, as an
> > experimental feature.
> >
> >
> > Thanks. Dmitry.
> >
>


Re: [PHP-DEV] [RFC] JIT

2019-02-22 Thread Dmitry Stogov
Hi Internals,


The RFC and implementation was updated once again.


https://wiki.php.net/rfc/jit


Now JIT supports PHP builds with compilers without GCC explicit global register 
variables extension.

This means we support CLANG/LLVM (Tested on Linux. Should work on Mac as well) 
and MSVC.

Complete Windows support is not implemented yet, but I don't see any big 
problems anymore.


ZTS support might be implemented after implementation of proposed TSRM API 
improvement.


Thanks. Dmitry.



From: Dmitry Stogov 
Sent: Wednesday, February 13, 2019 16:07
To: PHP internals
Subject: Re: [PHP-DEV] [RFC] JIT

Hi Internals,

According to comments, code reviews and discussions, JIT RFC was
extended with few new sections.

Please, consider to review the RFC once again.

https://wiki.php.net/rfc/jit

Any suggestion for RFC improvement are welcome.

I'm not going to invest significant time into JIT implementation
improvement itself, at this point. So, ideas are also welcome, but don't
expect to get them implemented tomorrow.

Thanks. Dmitry.

On 1/31/19 12:43 PM, Dmitry Stogov wrote:
> Hi Internals,
>
>
> I'm glad to finally propose including JIT into PHP.
>
>
> https://wiki.php.net/rfc/jit
>
>
> In the current state it may be included both into PHP-8, where we are
> going to continue active improvement, and into PHP-7.4, as an
> experimental feature.
>
>
> Thanks. Dmitry.
>


[PHP-DEV] [RFC][Vote] Weakrefs

2019-02-22 Thread Joe Watkins
Morning all,

The vote for weakrefs is open: https://wiki.php.net/rfc/weakrefs

Cheers
Joe


[PHP-DEV] [RFC] [Accepted] Abolish Narrow Margins

2019-02-22 Thread Joe Watkins
Morning all,

The abolish narrow margins RFC has been accepted and the Voting RFC has
been updated and had it's version changed to 1.1

Cheers
Joe


Re: [PHP-DEV] Optional catch binding

2019-02-22 Thread Roland Franssen
Turns out this is a duplicate request.

https://wiki.php.net/rfc/anonymous_catch
https://externals.io/message/67786

I'm not sure how to move forward from here on. Feel free to take over the
existing RFC and implement it :) (Im not a C developer).

Roland,

Op do 21 feb. 2019 om 19:56 schreef Gabriel O :

> How is it another way of doing same thing? It’s same way without
> unnecessary stuff. It’s more intuitive, as it doesn’t make sense to force
> user to specify variable they don’t need. When learning PHP, I remember
> being surprised I’m forced to specify variable I am not going to use.
> Plenty other languages like C#, C++, Python, Ruby already allow this.
>
> > On 21. Feb 2019, at 17:57, Dan Ackroyd  wrote:
> >
> > On Thu, 21 Feb 2019 at 15:46, Roland Franssen 
> wrote:
> >> For now, I'm aiming to get rid of "unused variable $e".
> >
> > You seem to be trying to alter the language to fit your code-style
> > checker, rather than altering your code-style checker to fit the
> > language.
> >
> > That seems back-to-front to me.
> >
> > Although there are times when having multiple ways of doing the same
> > thing can be a benefit, each new way is a something else that has to
> > be learned, so in my opinion they need more justification than this.
> >
> >> Example in the wild that could benefit from this:
> >
> > That code appears to be using exceptions for flow-control, which is
> > often recommended to not do. Again, wanting to change the language to
> > meet the needs of some code that is following a style that is
> > discouraged doesn't seem the right way round to me.
> >
> > cheers
> > Dan
> > Ack
> >
> > --
> > PHP Internals - PHP Runtime Development Mailing List
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
>
>