On Tue, April 10, 2012 5:53 pm, Nikita Popov wrote:
> Another reason is that currently you get a very obscure error message
> if you try to use empty() on a function return value: "Can't use
> function return value in write context". Aha. Where did I try to write
> to the return value?!
On the lin
On Thu, April 12, 2012 6:05 pm, Johannes Schlüter wrote:
> On Wed, 2012-04-11 at 00:53 +0200, Nikita Popov wrote:
>>
>> Currently the empty() language construct only works on variables.
>> You
>> can write if (empty($array)) but not empty if
>> (empty(getSomeArray()).
>
> I've mentioned this though
On Fri, Apr 13, 2012 at 16:22, Pal Konyves wrote:
> Well, if you want to use empty in the above mentioned situations, you might
> need the change. I personally don't like using empty(). I use it only on
> arrays, that's because semantically fits: array is empty.
>
> In other situations I prefer co
Well, if you want to use empty in the above mentioned situations, you might
need the change. I personally don't like using empty(). I use it only on
arrays, that's because semantically fits: array is empty.
In other situations I prefer comparing against the according return type
because it improve
Hi,
On Fri, Apr 13, 2012 at 15:00, Nikita Popov wrote:
> On Fri, Apr 13, 2012 at 11:37 AM, Pal Konyves wrote:
>> I don't see the point of empty( function() ).
>>
>> You tipically use empty on values that holds information you want to use
>> later in the program flow (a string, an integer). That
On Fri, Apr 13, 2012 at 11:37 AM, Pal Konyves wrote:
> I don't see the point of empty( function() ).
>
> You tipically use empty on values that holds information you want to use
> later in the program flow (a string, an integer). That means you'd better
> extract it to a variable because you want
> Hi!
>
> "The original reason for this restriction probably is that - in a way -
> it "doesn't make sense" to pass anything but a variable to empty()"
>
> I don't see the point of empty( function() ).
>
> You tipically use empty on values that holds information you want to use
> later in the progr
On Wed, 2012-04-11 at 00:53 +0200, Nikita Popov wrote:
>
> Currently the empty() language construct only works on variables. You
> can write if (empty($array)) but not empty if (empty(getSomeArray()).
I've mentioned this thought off-list already but let's discuss it
officially:
A fear I have is
On Tue, Apr 10, 2012 at 10:31 PM, Pierre Joye wrote:
> hi Kris,
>
> On Wed, Apr 11, 2012 at 7:26 AM, Kris Craig wrote:
>
> > I must've missed that part. Who was it that said this would be a
> separate
> > forked project? If so, then yeah obviously it's not up to us one way or
> > another. And
hi Kris,
On Wed, Apr 11, 2012 at 7:26 AM, Kris Craig wrote:
> I must've missed that part. Who was it that said this would be a separate
> forked project? If so, then yeah obviously it's not up to us one way or
> another. And if he's just committing changes locally and/or pushing to an
> unmer
On Tue, Apr 10, 2012 at 10:12 PM, Stas Malyshev wrote:
> Hi!
>
> > Well, technically it's discussion /and/ vote. I know we've been wanting
> > to get out of the habit of "push first, ask later," which is precisely
> > what RFC helps us avoid. Personally, I think any commits for a
>
> Nobody's pu
Hi!
> Well, technically it's discussion /and/ vote. I know we've been wanting
> to get out of the habit of "push first, ask later," which is precisely
> what RFC helps us avoid. Personally, I think any commits for a
Nobody's pushing anything. We're talking about implementing it in a
fork, it's
On Tue, Apr 10, 2012 at 5:46 PM, Stas Malyshev wrote:
> Hi!
>
> > Err isn't this something that should go through the RFC process first?
> > I think it's a good idea and I'll probably vote for it, but as I
> > understand the RFC process was created specifically for stuff like this.
>
> One doesn't
Hi!
> Err isn't this something that should go through the RFC process first?
> I think it's a good idea and I'll probably vote for it, but as I
> understand the RFC process was created specifically for stuff like this.
One doesn't preclude the other. Pull is code, RFC is discussion, they
can go
Sent from my iPad
在 2012-4-11,6:54,Nikita Popov 写道:
> Hey internals!
>
> Currently the empty() language construct only works on variables. You
> can write if (empty($array)) but not empty if (empty(getSomeArray()).
>
> The original reason for this restriction probably is that - in a way -
> it "
On Tue, Apr 10, 2012 at 4:51 PM, Stas Malyshev wrote:
> Hi!
>
> > Currently the empty() language construct only works on variables. You
> > can write if (empty($array)) but not empty if (empty(getSomeArray()).
> >
> > The original reason for this restriction probably is that - in a way -
> > it "d
Hi!
> Currently the empty() language construct only works on variables. You
> can write if (empty($array)) but not empty if (empty(getSomeArray()).
>
> The original reason for this restriction probably is that - in a way -
> it "doesn't make sense" to pass anything but a variable to empty() as
>
2012/4/10 Johannes Schlüter
> On Tue, 2012-04-10 at 19:12 -0400, Jelle Zijlstra wrote:
> > I think this is a useful simplification of the language, removing an
> > unnecessary exception. Would it also make sense to make empty() into a
> > library function instead of a language construct? That wou
On Tue, 2012-04-10 at 19:12 -0400, Jelle Zijlstra wrote:
> I think this is a useful simplification of the language, removing an
> unnecessary exception. Would it also make sense to make empty() into a
> library function instead of a language construct? That would not
> result in
> any BC break as f
On Tue, Apr 10, 2012 at 4:12 PM, Jelle Zijlstra wrote:
> 2012/4/10 Nikita Popov
>
> > Hey internals!
> >
> > Currently the empty() language construct only works on variables. You
> > can write if (empty($array)) but not empty if (empty(getSomeArray()).
> >
> > The original reason for this restric
2012/4/10 Nikita Popov
> Hey internals!
>
> Currently the empty() language construct only works on variables. You
> can write if (empty($array)) but not empty if (empty(getSomeArray()).
>
> The original reason for this restriction probably is that - in a way -
> it "doesn't make sense" to pass an
21 matches
Mail list logo