Hi Sean,
thanks for your answers.
Am 08.08.2013 um 02:54 schrieb Sean Cannella se...@fb.com:
It does in the sense the same way as the current mode enforces types on
properties. That is, there's no guarantee that types will remain as
initially set, only that the values passed to the
On 7 August 2013 20:47, Sean Cannella se...@fb.com wrote:
https://wiki.php.net/rfc/constructor-promotion
What do you all think?
I'm not sure what problem this is really trying to solve, the boilerplate
code you mention is very explicit and it is very clear to the reader what
is being done.
On 08.08.2013 10:34, Leigh wrote:
I'm not sure what problem this is really trying to solve, the boilerplate
code you mention is very explicit and it is very clear to the reader what
is being done. Each property documented with its type, purpose and
visibility in a common place for easy
Am 08.08.2013 12:34 schrieb Jordi Boggiano j.boggi...@seld.be:
On 08.08.2013 10:34, Leigh wrote:
I'm not sure what problem this is really trying to solve, the
boilerplate
code you mention is very explicit and it is very clear to the reader
what
is being done. Each property documented with
Le 08/08/2013 13:11, Martin Keckeis a écrit :
Am 08.08.2013 12:34 schrieb Jordi Boggiano j.boggi...@seld.be:
On 08.08.2013 10:34, Leigh wrote:
I'm not sure what problem this is really trying to solve, the
boilerplate
code you mention is very explicit and it is very clear to the reader
what
On 8 August 2013 14:12, Matthieu Napoli matth...@mnapoli.fr wrote:
class MyClass {
public $foo;
protected $bar;
public function __construct($this-foo, $this-bar, $baz) {
// $this-foo and $this-bar are now set
This actually feels _way_ more intuitive to me, it feels like you are
as before.
-Ursprüngliche Nachricht-
Von: Leigh [mailto:lei...@gmail.com]
Gesendet: Donnerstag, 8. August 2013 17:17
An: Matthieu Napoli
Cc: internals@lists.php.net
Betreff: Re: [PHP-DEV] RFC: constructor argument promotion
On 8 August 2013 14:12, Matthieu Napoli matth...@mnapoli.fr wrote
On 8 August 2013 17:16, Leigh lei...@gmail.com wrote:
On 8 August 2013 14:12, Matthieu Napoli matth...@mnapoli.fr wrote:
class MyClass {
public $foo;
protected $bar;
public function __construct($this-foo, $this-bar, $baz) {
// $this-foo and $this-bar are now set
This actually
Am 08.08.2013 15:12 schrieb Matthieu Napoli matth...@mnapoli.fr:
Le 08/08/2013 13:11, Martin Keckeis a écrit :
Am 08.08.2013 12:34 schrieb Jordi Boggiano j.boggi...@seld.be:
On 08.08.2013 10:34, Leigh wrote:
I'm not sure what problem this is really trying to solve, the
boilerplate
Everyone -
Hi! Since this is my first post to this list, I'll introduce myself:
I'm an engineer who has been working on HipHop VM in New York for the last half
year or so after a long time working at Microsoft on business software and
services in multiple hemispheres.
I wanted to get the PHP
Hi!
https://wiki.php.net/rfc/constructor-promotion
1. From the first glance, it doesn't seem clear how this syntax would
interact with magic methods - i.e., if you have __get, would access to
$make call it? If not, it's rather un-intuitive since the property is
not defined in the class but
Hi Sean,
thanks for the RFC. Two other questions additionally to what Stas askes:
- What about class type hints and array type hints?
- If type hints are possible, doesn’t it look too much as real property type
hinting?
cu,
Lars
Am 07.08.2013 um 21:47 schrieb Sean Cannella se...@fb.com:
Hi Stas,
https://wiki.php.net/rfc/constructor-promotion
1. From the first glance, it doesn't seem clear how this syntax would
interact with magic methods - i.e., if you have __get, would access to
$make call it? If not, it's rather un-intuitive since the property is
not defined in the class
Hi Lars,
thanks for the RFC. Two other questions additionally to what Stas askes:
- What about class type hints and array type hints?
Type hints continue to work as is:
class Foo {
public function __construct(public stdClass $foo, protected array $bar =
null) {}
}
- If type hints are
Hi!
Type hints continue to work as is:
class Foo {
public function __construct(public stdClass $foo, protected array $bar =
null) {}
}
This is both very confusing syntax (since this would be only place in a
language where public and type name can be mixed in the same construct)
and it
Hi!
In that case, __get() would not be called, since the property is defined
on the class, just not in a traditional way. This behavior is not
unprecedented however, as implicitly created public properties follow the
same pattern:
The code doing it is actually pretty explicit - you can see
On Wed, Aug 7, 2013 at 12:47 PM, Sean Cannella se...@fb.com wrote:
Everyone -
Hi! Since this is my first post to this list, I'll introduce myself:
I'm an engineer who has been working on HipHop VM in New York for the last
half year or so after a long time working at Microsoft on business
17 matches
Mail list logo