Re: [PHP-DEV] [RFC] Explicit call-site pass-by-reference (again)

2020-02-20 Thread Matthew Brown
This proposal is great, but most PHP static analysis tools already do a reasonable job of understanding by-reference assignment and detecting bugs there (an exception is closure use by-reference checks, which is a static-analysis no-man's land). No static analysis tools catch your specific

Re: [PHP-DEV] New PCRE function

2020-02-20 Thread Mike Schinkel
> On Feb 20, 2020, at 4:11 AM, Nikita Popov wrote: > > FWIW, it is our established stance that all error messages must be > capitalized. Lower-case first character is only permitted if it is part of > a function name, or similar cases. Fair enough. -Mike -- PHP Internals - PHP Runtime

Re: [PHP-DEV] RFC: Server-Side Request and Response Objects (v2)

2020-02-20 Thread Mike Schinkel
> On Feb 20, 2020, at 10:26 AM, Paul M. Jones wrote: > > One of the "open questions" on this RFC is: are the class names > ServerRequest, ServerResponse, and ServerResponseSender "good enough" for our > purposes, or are there names that are "better" in some qualitative way? > > Having said

Re: [PHP-DEV] [RFC] Explicit call-site pass-by-reference (again)

2020-02-20 Thread Mike Schinkel
> On Feb 20, 2020, at 9:13 AM, Nikita Popov wrote: > > I'd like to start the discussion on the "explicit call-site > pass-by-reference" RFC again: > https://wiki.php.net/rfc/explicit_send_by_ref > On Feb 20, 2020, at 6:04 PM, Larry Garfield wrote: > > If $this->data is itself an object, then

Re: [PHP-DEV] [RFC] Explicit call-site pass-by-reference (again)

2020-02-20 Thread Christian Schneider
Am 21.02.2020 um 00:04 schrieb Larry Garfield : > On Thu, Feb 20, 2020, at 8:47 AM, Levi Morrison via internals wrote: >> Just chiming in to voice strong support for this RFC. This is a key >> piece toward making PHP code statically analyzable. If it becomes >> required at the call site, such as

Re: [PHP-DEV] [RFC] Explicit call-site pass-by-reference (again)

2020-02-20 Thread Larry Garfield
On Thu, Feb 20, 2020, at 8:47 AM, Levi Morrison via internals wrote: > Just chiming in to voice strong support for this RFC. This is a key > piece toward making PHP code statically analyzable. If it becomes > required at the call site, such as in an edition of the language, it > will significantly

Re: [PHP-DEV] [RFC] [DISCUSSION] Immutable/final/readonly properties

2020-02-20 Thread Larry Garfield
On Thu, Feb 20, 2020, at 3:06 AM, Nikita Popov wrote: > On Thu, Feb 20, 2020 at 1:27 AM Matthew Brown > wrote: > > > Someone recently requested something similar for a PHP static analysis tool > > I wrote (https://psalm.dev/r/f75997a263), though that version only allows > > lazy initialisation

[PHP-DEV] Re: [RFC] Explicit call-site pass-by-reference (again)

2020-02-20 Thread Mark Randall
On 20/02/2020 14:13, Nikita Popov wrote: The RFC proposes to allow using a "&" marker at the call-site (in addition to the declaration-site) when by-reference passing is used. It's a solid +1 from me I do think this is somewhere else that an "official" upgrade / migration tool would be

Re: [PHP-DEV] RFC: Server-Side Request and Response Objects (v2)

2020-02-20 Thread Paul M. Jones
Hi all, One of the "open questions" on this RFC is: are the class names ServerRequest, ServerResponse, and ServerResponseSender "good enough" for our purposes, or are there names that are "better" in some qualitative way? The original thought was Request and Response, but I thought it might be

Re: [PHP-DEV] RFC: Server-Side Request and Response Objects (v2)

2020-02-20 Thread Paul M. Jones
Hi Rowan, > On Feb 19, 2020, at 16:43, Rowan Tommins wrote: > >>> - When working out the details, what code should we be picturing using the >>> new classes? >> >> Not to be flippant, but: request-reading and response-writing code? > > The reason I keep trying to pin you down on this is that

Re: [PHP-DEV] [RFC] Explicit call-site pass-by-reference (again)

2020-02-20 Thread Levi Morrison via internals
Just chiming in to voice strong support for this RFC. This is a key piece toward making PHP code statically analyzable. If it becomes required at the call site, such as in an edition of the language, it will significantly enhance the ability to reason about code and probably make it more correct

[PHP-DEV] [RFC] Explicit call-site pass-by-reference (again)

2020-02-20 Thread Nikita Popov
Hi internals, I'd like to start the discussion on the "explicit call-site pass-by-reference" RFC again: https://wiki.php.net/rfc/explicit_send_by_ref The RFC proposes to allow using a "&" marker at the call-site (in addition to the declaration-site) when by-reference passing is used. Relative

[PHP-DEV] PHP 7.4.3 Released

2020-02-20 Thread Derick Rethans
The PHP development team announces the immediate availability of PHP 7.4.3. This is a security release which also contains several bug fixes. All PHP 7.3 users are encouraged to upgrade to this version. For source downloads of PHP 7.4.3 please visit our downloads page. Windows binaries can be

[PHP-DEV] PHP 7.3.15 Released

2020-02-20 Thread Christoph M. Becker
The PHP development team announces the immediate availability of PHP 7.3.15. This is a security release which also contains several bug fixes. All PHP 7.3 users are encouraged to upgrade to this version. For source downloads of PHP 7.3.15 please visit our downloads page. Windows binaries can be

[PHP-DEV] PHP 7.2.28 Released

2020-02-20 Thread Remi Collet
Hi, The PHP development team announces the immediate availability of PHP 7.2.28. This is a security. All PHP 7.2 users are encouraged to upgrade to this version. For source downloads of PHP 7.2.28 please visit our downloads page. Windows binaries can be found on the PHP for Windows site. The

Re: [PHP-DEV] New PCRE function

2020-02-20 Thread Nikita Popov
On Wed, Feb 19, 2020 at 6:36 PM Rowan Tommins wrote: > On Wed, 19 Feb 2020 at 17:15, Mike Schinkel wrote: > > > From https://github.com/golang/go/wiki/CodeReviewComments#error-strings > > > > "Error strings should not be capitalized (unless beginning with proper > > nouns or acronyms) or end

Re: [PHP-DEV] [RFC] [DISCUSSION] Immutable/final/readonly properties

2020-02-20 Thread Nikita Popov
On Thu, Feb 20, 2020 at 1:27 AM Matthew Brown wrote: > Someone recently requested something similar for a PHP static analysis tool > I wrote (https://psalm.dev/r/f75997a263), though that version only allows > lazy initialisation inside the class in which a given property is declared. > >

Re: [PHP-DEV] [RFC] [DISCUSSION] Immutable/final/readonly properties

2020-02-20 Thread Máté Kocsis
> > I would expect that operating on one of these properties before it's > initialized will throw an error: > Actually, the RFC only says that the "immutability" of properties is guaranteed after initialization. We could of course change this premise, but that would make some important use-cases