Hi,
On Fri, Feb 12, 2021 at 8:45 PM Ben Ramsey wrote:
>
> I think it might be a good idea to check other languages to see if they
> support something like this. We could use their examples as points of
> reference for discussing whether to include this functionality in PHP.
>
On Sat, Feb 13,
On Tue, Feb 23, 2021 at 9:31 AM Nikita Popov wrote:
> On Fri, Feb 12, 2021 at 8:25 PM David Rodrigues
> wrote:
>
> > Hello!
> >
> > It is just a suggestion to be discussed.
> >
> > A lot of places on my projects I have codes like:
> >
> > $companies = $user->companies->count()
> > ? new
Hi internals,
As there appear to be no objections or concerns, I intend to open voting on
https://wiki.php.net/rfc/fsync_function tomorrow and voting will remain
open for two weeks.
The RFC and its implementation
- Adds functions fsync() and fdatasync() for plain file streams on Unix
systems.
-
On Tue, Feb 23, 2021 at 6:28 PM Larry Garfield
wrote:
>
> 1) Please don't top post.
>
Sorry for that!
> 2)
>
> The advantage of ?: over long-ternary is that the part it lets you omit is
> of variable size, and is often verbose (nested array elements). That's not
> the case here, as the
On 23/02/2021 18:41, Albert Casademont wrote:
Sure, it's not a big deal having to write the ": null" but it doesn't add
any value
On the contrary, it adds an important piece of information: that the
default value is "null", rather than "false", or "0", or "new EmptyValue()".
For instance,
On Tue, Feb 23, 2021 at 1:05 PM Rowan Tommins
wrote:
>
> On 23/02/2021 18:41, Albert Casademont wrote:
> > Sure, it's not a big deal having to write the ": null" but it doesn't
add
> > any value
>
> On the contrary, it adds an important piece of information: that the
> default value is "null",
On Tue, Feb 23, 2021 at 6:28 PM Larry Garfield
wrote:
> On Tue, Feb 23, 2021, at 10:49 AM, Albert Casademont wrote:
> > Another example is when a scalar input needs to be either left null or
> > converted to a Value Object:
> >
> > $color = $data['color'] ? new Color($data['color']) : null;
> >
See https://nigeltao.github.io/blog/2021/json-with-commas-comments.html
for more information.
It is quite common to have trailing commas in JSON, and a lot of
parsers support it. I believe this could be trivially supported by
PHP, even if you skip adding support for comments.
Perhaps this could
On 23/02/2021 18:21, Pavel Djundik via internals wrote:
See https://nigeltao.github.io/blog/2021/json-with-commas-comments.html
for more information.
It is quite common to have trailing commas in JSON, and a lot of
parsers support it. I believe this could be trivially supported by
PHP, even if
On Tue, Feb 23, 2021 at 7:30 AM Chase Peeler wrote:
> On Tue, Feb 23, 2021 at 10:27 AM Ben Ramsey wrote:
>
> > > On Feb 23, 2021, at 09:21, Larry Garfield
> > wrote:
> > >
> > > On Mon, Feb 22, 2021, at 4:26 AM, Christian Schneider wrote:
> > >> Am 15.02.2021 um 13:20 schrieb Pierre :
> > >>>
On Tue, Feb 23, 2021, at 10:49 AM, Albert Casademont wrote:
> Another example is when a scalar input needs to be either left null or
> converted to a Value Object:
>
> $color = $data['color'] ? new Color($data['color']) : null;
>
> This would become;
>
> $color = $data['color'] ? new
> On Feb 23, 2021, at 09:21, Larry Garfield wrote:
>
> On Mon, Feb 22, 2021, at 4:26 AM, Christian Schneider wrote:
>> Am 15.02.2021 um 13:20 schrieb Pierre :
>>> I noticed I receive almost all your replies to the list along with a
>>> duplicated copy addressed to me or other conversation
On Mon, Feb 22, 2021, at 4:26 AM, Christian Schneider wrote:
> Am 15.02.2021 um 13:20 schrieb Pierre :
> > I noticed I receive almost all your replies to the list along with a
> > duplicated copy addressed to me or other conversation participants, I think
> > you always click "reply to all"
On Fri, Feb 5, 2021 at 2:10 PM G. P. B. wrote:
> Greetings internals,
>
> While working on rewriting the PHP docs about errors and error handling [1]
> I came across a change of behaviour in an edge case of an edge case.
>
> finally blocks are meant to be always executed regardless that an
Another example is when a scalar input needs to be either left null or
converted to a Value Object:
$color = $data['color'] ? new Color($data['color']) : null;
This would become;
$color = $data['color'] ? new Color($data['color']); //the ": null" part is
implicit
It's actually kinda the
On Tue, Feb 23, 2021 at 5:12 PM Nikita Popov wrote:
> On Tue, Feb 23, 2021 at 4:52 PM Guilliam Xavier
> wrote:
>
>> On Fri, Feb 5, 2021 at 2:10 PM G. P. B. wrote:
>>
>> > Greetings internals,
>> >
>> > While working on rewriting the PHP docs about errors and error handling
>> [1]
>> > I came
On Tue, Feb 23, 2021, at 5:21 AM, Nikita Popov wrote:
> Hi internals,
>
> I'm a bit concerned about the addition of the "enum" reserved keyword as
> part of https://wiki.php.net/rfc/enumerations. The problem is that there
> are quite a few existing enum libraries (such as
>
On Tue, Feb 23, 2021 at 10:27 AM Ben Ramsey wrote:
> > On Feb 23, 2021, at 09:21, Larry Garfield
> wrote:
> >
> > On Mon, Feb 22, 2021, at 4:26 AM, Christian Schneider wrote:
> >> Am 15.02.2021 um 13:20 schrieb Pierre :
> >>> I noticed I receive almost all your replies to the list along with a
On Thu, Feb 11, 2021 at 12:36 AM Kamil Tekiela wrote:
> Hi internals,
>
> I have started voting on https://wiki.php.net/rfc/mysqli_default_errmode
> The voting period is 2020-02-11 -- 2020-02-28
>
While the change in itself is something I want to see, I voted no on this
proposal because its a
Hi internals,
While looking into various issues related to static variable handling, I've
become increasingly convinced that our handling of static variables in
inherited methods is outright buggy. However, it's also long-standing
behavior, so I've put up an RFC:
On Tue, Feb 23, 2021 at 4:52 PM Guilliam Xavier
wrote:
> On Fri, Feb 5, 2021 at 2:10 PM G. P. B. wrote:
>
> > Greetings internals,
> >
> > While working on rewriting the PHP docs about errors and error handling
> [1]
> > I came across a change of behaviour in an edge case of an edge case.
> >
>
> On Feb 23, 2021, at 2:05 PM, Rowan Tommins wrote:
>
> On 23/02/2021 18:41, Albert Casademont wrote:
>> Sure, it's not a big deal having to write the ": null" but it doesn't add
>> any value
>
>
> On the contrary, it adds an important piece of information: that the default
> value is "null",
On Tue, 23 Feb 2021 at 06:21, Nikita Popov wrote:
> Another possibility would be to recognize T_ENUM in the lexer, but only if
> it is followed by whitespace and an identifier. This would possibly be
> friendlier for tooling using token_get_all(). It would not permit comments
> in between the
Hi internals,
I'm a bit concerned about the addition of the "enum" reserved keyword as
part of https://wiki.php.net/rfc/enumerations. The problem is that there
are quite a few existing enum libraries (such as
https://github.com/myclabs/php-enum) that define an Enum class. While the
implementation
On Fri, Feb 12, 2021 at 8:25 PM David Rodrigues
wrote:
> Hello!
>
> It is just a suggestion to be discussed.
>
> A lot of places on my projects I have codes like:
>
> $companies = $user->companies->count()
> ? new Collection($user->companies)
> : null;
>
> So $companies will be null
On Mon, Feb 3, 2020 at 2:29 PM Nikita Popov wrote:
> Hi internals,
>
> We have a long-standing issue (tracked at
> https://bugs.php.net/bug.php?id=64196 and the very numerous duplicates)
> that certain types of infinite recursion can lead to a stack overflow.
> While for us it is easy to
Hi,
On Wed, 2021-02-10 at 23:35 +, Kamil Tekiela wrote:
> I have started voting on
> https://wiki.php.net/rfc/mysqli_default_errmode
> The voting period is 2020-02-11 -- 2020-02-28
Sorry, I didn't see this before. I agree that Exceptions are the way to
go and it were good if that had been
27 matches
Mail list logo