Hi,
Hope this can help.
Le 22/09/2015 20:16, j adams a écrit :
I'm working on a data serialization routine wherein I must iterate through
an object's properties while distinguishing between "sealed" properties
(i.e., those specified by class definitions) and "dynamic" properties"
(i.e., those a
Hi Rowan,
Le 22/09/2015 12:49, Rowan Collins a écrit :
I take it you didn't like my suggestion of separate functions for
hasitem() and variable_exists() then?
I think there are two very different use cases here, and combining them
will just add to the confusion which isset() already seems to c
On Wed, Sep 23, 2015 at 12:00 AM, Anthony Ferrara
wrote:
> Dmitry,
>
> On Tue, Sep 22, 2015 at 3:19 PM, Dmitry Stogov wrote:
> >
> >
> > On Tue, Sep 22, 2015 at 9:20 PM, Anthony Ferrara
> > wrote:
> >>
> >> Dmitry,
> >>
> >> On Tue, Sep 22, 2015 at 2:05 PM, Dmitry Stogov wrote:
> >> > On Tue,
Dmitry,
On Tue, Sep 22, 2015 at 3:19 PM, Dmitry Stogov wrote:
>
>
> On Tue, Sep 22, 2015 at 9:20 PM, Anthony Ferrara
> wrote:
>>
>> Dmitry,
>>
>> On Tue, Sep 22, 2015 at 2:05 PM, Dmitry Stogov wrote:
>> > On Tue, Sep 22, 2015 at 7:01 PM, Bob Weinand
>> > wrote:
>> >
>> >>
>> >> > Am 22.09.2015
Thank you, Sean. Still looking for a couple of answers...
> 1) 'Default Properties' or properties stored on the class (not object)
can be found on the zend_class_entry[0], they are just accessed by offset
[1]
> This isn't a stable/public API, but good for a cool hack!
I'm afraid I don't follow. C
On Tue, Sep 22, 2015 at 11:16:46AM -0700, j adams wrote:
> I'm working on a data serialization routine wherein I must iterate through
> an object's properties while distinguishing between "sealed" properties
> (i.e., those specified by class definitions) and "dynamic" properties"
> (i.e., those ass
On 09/22/2015 06:38 AM, Stig Bakken wrote:
Actually, you need to think about compatibility in a bigger perspective.
One of the first things I would want do if PHP were to grow enums, is
to add support for it to Apache Thrift. For those not familiar with
it, Thrift is basically an IDL for specify
On Tue, Sep 22, 2015 at 9:24 PM, Bob Weinand wrote:
>
> Am 22.09.2015 um 20:05 schrieb Dmitry Stogov :
>
> The current PHP version emits two warning on similar constructs, and this
> is explainable because we explicitly "use" $y.
>
> $ sapi/cli/php -r 'function foo(){(function($x) use ($y){$y=3;
On Tue, Sep 22, 2015 at 9:20 PM, Anthony Ferrara
wrote:
> Dmitry,
>
> On Tue, Sep 22, 2015 at 2:05 PM, Dmitry Stogov wrote:
> > On Tue, Sep 22, 2015 at 7:01 PM, Bob Weinand
> wrote:
> >
> >>
> >> > Am 22.09.2015 um 17:36 schrieb Dmitry Stogov :
> >> >
> >> > On Tue, Sep 22, 2015 at 4:54 PM, Joe
> Am 22.09.2015 um 20:05 schrieb Dmitry Stogov :
>
> The current PHP version emits two warning on similar constructs, and this
> is explainable because we explicitly "use" $y.
>
> $ sapi/cli/php -r 'function foo(){(function($x) use ($y){$y=3; return
> $y+$x;})(5);return $y;} var_dump(foo());'
>
Dmitry,
On Tue, Sep 22, 2015 at 2:05 PM, Dmitry Stogov wrote:
> On Tue, Sep 22, 2015 at 7:01 PM, Bob Weinand wrote:
>
>>
>> > Am 22.09.2015 um 17:36 schrieb Dmitry Stogov :
>> >
>> > On Tue, Sep 22, 2015 at 4:54 PM, Joe Watkins
>> wrote:
>> >
>> >> I'd really like to understand what you're tryi
I'm working on a data serialization routine wherein I must iterate through
an object's properties while distinguishing between "sealed" properties
(i.e., those specified by class definitions) and "dynamic" properties"
(i.e., those assigned ad-hoc to some object that are not party of any class
defin
On Tue, Sep 22, 2015 at 7:01 PM, Bob Weinand wrote:
>
> > Am 22.09.2015 um 17:36 schrieb Dmitry Stogov :
> >
> > On Tue, Sep 22, 2015 at 4:54 PM, Joe Watkins
> wrote:
> >
> >> I'd really like to understand what you're trying to say there Dmitry,
> but
> >> I don't get it.
> >>
> >> What is your
Dan Cryer wrote on 22/09/2015 16:06:
C#'s enums seem a good model to follow.
It's worth pointing out that C#'s enums are basically the same as C's -
a typedef over int with a handful of helper methods in the standard
library. They don't even range-check on assignment, so that a "weekday"
var
On Tue, Sep 22, 2015 at 10:29 AM, Rowan Collins wrote:
> Dan Cryer wrote on 22/09/2015 16:06:
>>
>> C#'s enums seem a good model to follow.
>
>
> It's worth pointing out that C#'s enums are basically the same as C's - a
> typedef over int with a handful of helper methods in the standard library.
>
> Am 22.09.2015 um 17:36 schrieb Dmitry Stogov :
>
> On Tue, Sep 22, 2015 at 4:54 PM, Joe Watkins wrote:
>
>> I'd really like to understand what you're trying to say there Dmitry, but
>> I don't get it.
>>
>> What is your example function trying to show ?
>>
>> As it mentions in the RFC, vars
On Tue, Sep 22, 2015 at 4:54 PM, Joe Watkins wrote:
> I'd really like to understand what you're trying to say there Dmitry, but
> I don't get it.
>
> What is your example function trying to show ?
>
> As it mentions in the RFC, vars in short closure are by-value, so I can't
> see what side effect
Hi Bob,
Bob Weinand wrote:
Hey,
Thanks for all your feedback in the discussion thread!
So, before I start the vote, just two quick notes:
I've added two notes about the statement syntax and the single variable use.
Though a few people complained, I'm not switching to the ==> operator, as I
no
Am 22.09.2015 um 12:38 schrieb Stig Bakken:
> The point I'm trying to make is that an enum's normalized
> representation should be an integer, and that is also how it should be
> serialized.
Makes sense to me.
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http:
>
> You can always serialize things however you want. Using `serialize()`
> is just a convenience – there is absolutely nothing that prevents you
> from using a custom serialization routine. Note that while Java has
> built in serialization it is often not used, and instead libraries
> like Google'
> The point I'm trying to make is that an enum's normalized
> representation should be an integer, and that is also how it should be
> serialized. It also happens to be how most other languages chose to
> represent enums, and deviating from that will cause all kinds of pain
> the minute you need to
I'd really like to understand what you're trying to say there Dmitry, but I
don't get it.
What is your example function trying to show ?
As it mentions in the RFC, vars in short closure are by-value, so I can't
see what side effects you might be thinking of ?
Cheers
Joe
On Tue, Sep 22, 2015 at
Results for project php-src-nightly, build date 2015-09-22 05:00:00+03:00
commit: b7f0b4bdb3f2723695224eadef73ef180db6132a
revision_date: 2015-09-21 22:05:45+08:00
environment:Haswell-EP
cpu:Intel(R) Xeon(R) CPU E5-2699 v3 @ 2.30GHz 2x18 cores, stepping
2, LLC 45 MB
François Laupretre wrote on 22/09/2015 01:11:
Hi,
for those interested, a pull request implementing an exists()
construct (on PHP 7) is available for testing and reviewing :
https://github.com/php/php-src/pull/1530
exists() is modelled after isset(), with the difference that every
value (in
On Fri, Sep 18, 2015 at 2:05 AM, Rowan Collins wrote:
> On 18/09/2015 00:34, user@domain.invalid wrote:
>>
>> Well, how are you supposed to serialize an enum value without some sort of
>> numerical representation or value? Maybe you could serialize it by
>> converting the enum to a string represen
On Sep 19, 2015 15:50, "Rowan Collins" wrote:
>
> On 19 September 2015 10:48:17 BST, Lester Caine
wrote:
> >I get that a lot of people think that the only way forward with PHP is
> >fully typed, strict checking and blocking anything that may be deemed
> >to
> >be risky. However PHP7 has not yet d
Hi,
The introduction claims:
"he current implementation of anonymous functions in PHP is quite verbose
compared to other languages. That makes using anonymous functions be more
difficult than it could be, as there is both more to type, and more
importantly the current implementation makes it hard
I'm against the magic - "automatically use () all of the (compiled)
variables".
I'm also against compound short closures with curly brackets.
in my opinion they opens too many ambiguous questions.
function foo() {
(($x) ~> {$y = 3; return $y + $x;})(5);
return $y;
}
also think about nested cl
On 22/09/15 01:11, François Laupretre wrote:
> for those interested, a pull request implementing an exists() construct
> (on PHP 7) is available for testing and reviewing :
>
> https://github.com/php/php-src/pull/1530
>
> exists() is modelled after isset(), with the difference that every value
>
29 matches
Mail list logo