Re: [PHP-DEV] Re: [RFC] Default expression

2024-09-01 Thread Rowan Tommins [IMSoP]
On 1 September 2024 17:45:57 BST, Rob Landers wrote: >Is manually copying the default also not type-safe? Is php a type-safe >language? I think a lot of the arguments I saw suggested that people don't >review libraries and their implementations when upgrading or installing them. >This is jus

Re: [PHP-DEV] Re: [RFC] Default expression

2024-09-01 Thread Rob Landers
On Sun, Sep 1, 2024, at 14:39, Rowan Tommins [IMSoP] wrote: > On 29/08/2024 22:52, Bilge wrote: > > On 24/08/2024 17:49, Bilge wrote: > >> > >> New RFC just dropped: https://wiki.php.net/rfc/default_expression. I > >> think some of you might enjoy this one. Hit me with any feedback. > >> > > Now t

Re: [PHP-DEV] Re: [RFC] Default expression

2024-09-01 Thread Rowan Tommins [IMSoP]
On 29/08/2024 22:52, Bilge wrote: On 24/08/2024 17:49, Bilge wrote: New RFC just dropped: https://wiki.php.net/rfc/default_expression. I think some of you might enjoy this one. Hit me with any feedback. Now the dust has settled, I've updated the RFC to version 1.1. The premise of the RFC is

Re: [PHP-DEV] Re: [RFC] Default expression

2024-08-30 Thread Rowan Tommins [IMSoP]
On Thu, 29 Aug 2024, at 22:52, Bilge wrote: >> New RFC just dropped: https://wiki.php.net/rfc/default_expression. I >> think some of you might enjoy this one. Hit me with any feedback. >> > Now the dust has settled, I've updated the RFC to version 1.1. The > premise of the RFC is unchanged, but t

Re: [PHP-DEV] Re: [RFC] Default expression

2024-08-29 Thread John Coggeshall
One thought re-reading the RFC. abstract class Theme { public function bar(); } class CuteTheme extends Theme { public function foo(); } class Config { public function __construct(Theme $theme = new CuteTheme()) {} } $a = new Config(default->foo()); In the proposed (updated) RFC would this be p