Re: [PHP-DEV] Null-safe property access in interpolated strings

2020-08-10 Thread Björn Larsson
Hi Ilija, Den 2020-08-10 kl. 17:06, skrev Ilija Tovilo: Hi Nikita I think if it can be reasonably fixed it probably would make sense for consistency and WTF-avoidance if anything. Agree. I don't think the question of whether it is useful should come into this, it's a matter of language

Re: [PHP-DEV] Null-safe property access in interpolated strings

2020-08-10 Thread Mike Schinkel
> > On Aug 10, 2020 at 11:02 AM, mailto:tovilo.il...@gmail.com)> > wrote: > > > > Hi Mike > $card_html = << {$card->content}HTML; Two things: 1. We're solely > talking about string interpolation without braces {}. You're using braces in > your example and this

[PHP-DEV] PHP 7.4.9 Released!

2020-08-10 Thread Derick Rethans
The PHP development team announces the immediate availability of PHP 7.4.9. This is a security bug fix release. All PHP 7.4 users are encouraged to upgrade to this version. For source downloads of PHP 7.4.9 please visit our downloads page. Windows binaries can be found on the PHP for Windows

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Andreas Leathley
On 10.08.20 17:40, Derick Rethans wrote: It missing an ending delimiter was my first reason for wanting to get something better than @@. I don't particularly care much if it ends up being @[], #[], <<>>, or other things such as @:( ). If you have something to open, and close, there there is a

Re: [PHP-DEV] ZEND_ENGINE_4 define?

2020-08-10 Thread Sara Golemon
On Mon, Aug 10, 2020 at 2:37 AM Nikita Popov wrote: > On Mon, Aug 10, 2020 at 7:57 AM Philip Hofstetter < > phofstet...@sensational.ch> wrote: > > In many cases, I've been using the ZEND_ENGINE_3 define to handle the > > PHP 5/7 difference. > > > > Now, the Zend Engine version seems to have been

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Derick Rethans
On Mon, 10 Aug 2020, Andreas Leathley wrote: > On 10.08.20 15:05, Markus Fischer wrote: > > Personally, and never gave it much thought TBH, the `@@` AND `<<`/`>>` > > in fact is the most "unreadable" version to me because duplicate > > occurrence of a single character somehow creates a noise _for

Re: [PHP-DEV] Null-safe property access in interpolated strings

2020-08-10 Thread Ilija Tovilo
Hi Nikita > > I think if it can be reasonably fixed it probably would make sense for > > consistency and WTF-avoidance if anything. > > Agree. I don't think the question of whether it is useful should come into > this, it's a matter of language consistency. There could be some leeway > here if we

Re: [PHP-DEV] Null-safe property access in interpolated strings

2020-08-10 Thread Ilija Tovilo
Hi Mike > $card_html = << > {$card->content}HTML; Two things: 1. We're solely talking about string interpolation without braces {}. You're using braces in your example and this does indeed work right now. 2. The semantics of ?-> are different than you're depicting them to be in this

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Peter Bowyer
On Mon, 10 Aug 2020 at 14:59, Derick Rethans wrote: > I did answer that as a reply to Rowan: > > https://externals.io/message/111312#111346 I'm with Rowan's response to you: https://externals.io/message/111312#111354 What is the difference between mandatory parentheses giving: <><>(

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Rowan Tommins
On Mon, 10 Aug 2020 at 14:56, Benjamin Eberlei wrote: > > On Mon, Aug 10, 2020 at 3:40 PM Rowan Tommins > wrote: > >> The question asked was that _if the parentheses were made mandatory_, >> would >> this provide the same benefits ascribed to the other syntaxes? >> > > For me It would indeed

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Benas IML
On Mon, Aug 10, 2020, 4:28 PM Theodore Brown wrote: > On Mon, Aug 10, 2020 at 3:41 AM Derick Rethans wrote: > > > I've just opened the vote to make sure we don't make a terrible mistake > > with using the @@ syntax for attributes: > > > >

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Derick Rethans
On Mon, 10 Aug 2020, Peter Bowyer wrote: > On Mon, 10 Aug 2020 at 10:15, Rowan Tommins wrote: > > > I am not a fan of the @@ syntax, and respect what you're trying to do with > > this RFC, but am disappointed you haven't engaged with those of us who said > > that the RFC needs more detail.

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Benjamin Eberlei
On Mon, Aug 10, 2020 at 3:52 PM guilhermebla...@gmail.com < guilhermebla...@gmail.com> wrote: > Hi, > > One question I'd like answered is that, like me, a few people have > voted NO on the question to re-vote the syntax. > If that is true, shouldn't their first primary choice be implied to be >

Re: [PHP-DEV] Null-safe property access in interpolated strings

2020-08-10 Thread Mike Schinkel
> > On Aug 9, 2020 at 3:00 PM, mailto:deleu...@gmail.com)> wrote: > > > > I like and make use of interpolation, but I can't think of a use case for > this. Is there any valid use case that would benefit from this fix regardless > of personal preference? In other words,

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Benjamin Eberlei
On Mon, Aug 10, 2020 at 3:40 PM Rowan Tommins wrote: > On Mon, 10 Aug 2020 at 14:08, Benjamin Eberlei > wrote: > > > > > On Mon, Aug 10, 2020 at 11:28 AM Peter Bowyer > > > wrote: > > > >> > >> I have voted no because I asked a question about the ending delimiter > and > >> why () didn't

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Andreas Leathley
On 10.08.20 15:05, Markus Fischer wrote: Personally, and never gave it much thought TBH, the `@@` AND `<<`/`>>` in fact is the most "unreadable" version to me because duplicate occurrence of a single character somehow creates a noise _for me_, I don't feel eligible to have a vote, but based on

Re: [PHP-DEV] [RFC] Shorter Attribute Syntax Change RFC 0.2

2020-08-10 Thread Derick Rethans
On Mon, 10 Aug 2020, Christoph M. Becker wrote: > On 10.08.2020 at 10:35, Derick Rethans wrote: > > > On Fri, 7 Aug 2020, Theodore Brown wrote: > > > >> - Used by other language: > >> - This is listed as an advantage for `#[]` and `<<>>`. However, the > >> table > >> fails to point out

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread guilhermebla...@gmail.com
Hi, One question I'd like answered is that, like me, a few people have voted NO on the question to re-vote the syntax. If that is true, shouldn't their first primary choice be implied to be <<>> instead of anything else? I see 7 votes for no, but I'm the only one that still kept the first voting

Re: [PHP-DEV] [RFC] [Vote] PHP namespace policy

2020-08-10 Thread Larry Garfield
On Sun, Jul 26, 2020, at 11:24 AM, Larry Garfield wrote: > The vote on the PHP namespace policy is now open: > > https://wiki.php.net/rfc/php_namespace_policy > > Usual rules, 2/3 required for passage. Vote will be open until 9 August. The vote has been closed. Final results: Yes: 13 No: 17

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Rowan Tommins
On Mon, 10 Aug 2020 at 14:08, Benjamin Eberlei wrote: > > On Mon, Aug 10, 2020 at 11:28 AM Peter Bowyer > wrote: > >> >> I have voted no because I asked a question about the ending delimiter and >> why () didn't count. Another person asked a similar question and neither >> of >> us got a reply.

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Andreas Leathley
On 10.08.20 15:08, Benjamin Eberlei wrote: () does not count as ending symbol, because it is not required, as such its not an ending symbol. The point Andreas Leathley makes in the discussion thread about new Foo not having an end symbol demonstrates exactly the opposite point he was trying to

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Theodore Brown
On Mon, Aug 10, 2020 at 3:41 AM Derick Rethans wrote: > I've just opened the vote to make sure we don't make a terrible mistake > with using the @@ syntax for attributes: > > https://wiki.php.net/rfc/shorter_attribute_syntax_change#voting > > The first vote is a vote to say that you have an

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Benjamin Eberlei
On Mon, Aug 10, 2020 at 11:28 AM Peter Bowyer wrote: > On Mon, 10 Aug 2020 at 10:15, Rowan Tommins > wrote: > > > I am not a fan of the @@ syntax, and respect what you're trying to do > with > > this RFC, but am disappointed you haven't engaged with those of us who > said > > that the RFC needs

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Markus Fischer
On 10.08.20 13:32, Jordi Boggiano wrote: https://gist.github.com/Seldaek/b7a3bd28920c6cc181e67a829b13a81c This is really really useful! However I suggest to look at the raw text rather, because the highlighting is unaware of the syntax and may bias "how it feels to look at it" (*):

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Benjamin Eberlei
On Mon, Aug 10, 2020 at 11:16 AM Rowan Tommins wrote: > On Mon, 10 Aug 2020 at 09:41, Derick Rethans wrote: > > > I've just opened the vote to make sure we don't make a terrible mistake > > with using the @@ syntax for attributes: > > > > [...] > > > > Please have a objective look at the table

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Jordi Boggiano
On 10/08/2020 10:41, Derick Rethans wrote: I've just opened the vote to make sure we don't make a terrible mistake with using the @@ syntax for attributes: https://wiki.php.net/rfc/shorter_attribute_syntax_change#voting Here is a more detailed comparison of how this would look like in real

Re: [PHP-DEV] Null-safe property access in interpolated strings

2020-08-10 Thread Philip Hofstetter
Hi, On Sun, Aug 9, 2020 at 8:34 PM Jordi Boggiano wrote: > Can't say I'm big on interpolation but I'd definitely expect this to > work because why not? A reason why not is because it will break backwards compatibility with existing (though admittedly unlikely) code which also can't be fixed by

Re: [PHP-DEV] Null-safe property access in interpolated strings

2020-08-10 Thread Nikita Popov
On Sun, Aug 9, 2020 at 8:34 PM Jordi Boggiano wrote: > On 09/08/2020 00:17, Sara Golemon wrote: > > Do we expect this to work? > > > > $foo = new stdClass; > > $foo->bar = "Hello"; > > echo "$foo?->bar world\n"; > > > > Because at the moment it doesn't: https://3v4l.org/nLv3l > > > > -Sara > >

Re: [PHP-DEV] [RFC] Shorter Attribute Syntax Change RFC 0.2

2020-08-10 Thread Christoph M. Becker
On 10.08.2020 at 10:35, Derick Rethans wrote: > On Fri, 7 Aug 2020, Theodore Brown wrote: > >> - Used by other language: >> - This is listed as an advantage for `#[]` and `<<>>`. However, the table >> fails to point out that Hack is migrating away from `<<>>` to `@Attr`. > > It can only

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Peter Bowyer
On Mon, 10 Aug 2020 at 10:15, Rowan Tommins wrote: > I am not a fan of the @@ syntax, and respect what you're trying to do with > this RFC, but am disappointed you haven't engaged with those of us who said > that the RFC needs more detail. There is simply not enough information in > that table

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Rowan Tommins
On Mon, 10 Aug 2020 at 09:41, Derick Rethans wrote: > I've just opened the vote to make sure we don't make a terrible mistake > with using the @@ syntax for attributes: > > [...] > > Please have a objective look at the table > (https://wiki.php.net/rfc/shorter_attribute_syntax_change#proposal)

[PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Derick Rethans
Hi, I've just opened the vote to make sure we don't make a terrible mistake with using the @@ syntax for attributes: https://wiki.php.net/rfc/shorter_attribute_syntax_change#voting The first vote is a vote to say that you have an opinion about attribute syntax. Make sure to read up on the

Re: [PHP-DEV] [RFC] Shorter Attribute Syntax Change RFC 0.2

2020-08-10 Thread Derick Rethans
On Fri, 7 Aug 2020, Theodore Brown wrote: > On Fri, Aug 7, 2020 at 6:03 AM Derick Rethans wrote: > > > On Fri, 7 Aug 2020, Theodore Brown wrote: > > > > > Even if we assume the implementation is only about 30 lines, it's > > > still extra complexity that I don't understand the benefit of. I >

Re: [PHP-DEV] ZEND_ENGINE_4 define?

2020-08-10 Thread Nikita Popov
On Mon, Aug 10, 2020 at 7:57 AM Philip Hofstetter < phofstet...@sensational.ch> wrote: > Hello, > > I'm currently looking into porting some extensions (both internal and > public) to PHP 8 while still keeping support for PHP 7 (for the public > ones) and PHP 5.6 (don't ask :-(). > > In many

Re: [PHP-DEV] [RFC] Import of variables

2020-08-10 Thread Manuel Canga
Hi, Internals, Thanks, Marco and also to Rowans, Josh, David and Tyson I'll use IIFE in order to avoid global conflicts. Regards En lun, 10 ago 2020 02:16:06 +0200 Marco Pivetta escribió > Hey Manuel, > > > > > On Sun, Aug 9, 2020, 11:02 Manuel Canga wrote: > > > Hi