On Mon, Aug 26, 2024 at 5:36 AM, Jakob Givoni <[ja...@givoni.dk](mailto:On Mon,
Aug 26, 2024 at 5:36 AM, Jakob Givoni < wrote
> "default" should not evaluate to a value before sending it as an argument to
> the function or method.
I have no dog in this fight, but I agree with the above. Plus, h
> On Jul 4, 2024, at 12:02 PM, Mike Schinkel wrote:
>
> Your definitions are language-specific. For example, in Go the definitions
> for those terms are the opposite of how you defined them.
>
> The point being that PHP is free to choose how they are defined with respect
> to PHP.
>
> To w
> On Jul 3, 2024, at 6:16 PM, Michael Morris wrote:
>
> Hello all. Hitting reset again as the primary problem at hand has become
> clear. Let's recap it.
>
> Autoloading is great for loading packages, but it can't load different
> versions of the same package at the same time. Why would y
> On Jun 27, 2024, at 11:26 AM, Tim Düsterhus wrote:
>
> Hi
>
> On 6/27/24 19:09, Chuck Adams wrote:
>> Personally I say let strtok be and just admit in the documentation that it’s
>> weird because C.
>
> strtok() is not weird because C. It does not rely on
> On Jun 27, 2024, at 2:22 AM, Stephen Reay wrote:
>
> I do appreciate that strtok has a kind of bizarre signature/use pattern and
> potential for confusion due to how subsequent calls work, but to me that
> sounds like a better result for uses that need the repeated call
> functionality, would
> On Jun 26, 2024, at 5:49 PM, Derick Rethans wrote:
>
> There has been some work done on function autoloading too:
> https://wiki.php.net/rfc/core-autoloading
Fantastic! I still want modules and/or companion objects of course... I
wonder whether the autoloading machinery could be bent to
> On Jun 26, 2024, at 1:50 PM, Morgan wrote:
> So the issue has nothing to do with this hypothetical infinity of
> unobservable nulls, and comes entirely down to the fact that with this
> pattern a variable may pass
> a) because it does not have a key named 'foo', or
> b) because it has a key na
> On Jun 25, 2024, at 9:17 AM, Derick Rethans wrote:
>
> Having read this thread, and the previous one from half a year ago, I
> will do so too. In short, we shouldn't be encouraging static classes as
> a bag of static functions, that ought to be just namespaced functions.
Which brings us back to
> On Jun 24, 2024, at 1:53 PM, Robert Landers wrote:
>
> $arr = ['a' => 'a string'];
> $arr is ['a' => string, ?'b' => $value, ...];
>
> This syntax implies that a non-existent key is a special case, and if
> it passes as-is, it will be. If there is a binding and the key is
> missing, what happens
> On Jun 24, 2024, at 3:31 AM, Robert Landers wrote:
>
>
> There's no need to use `?` to check for existence on a key, so this:
>
> $arr is ['a' => string, ?'b' => string, ...];
>
> should be this:
>
> $arr is ['a' => string, 'b' => ?string, ...];
>
> because $arr['non-existent-key'] is NU
On Wed, Dec 30, 2020 at 12:27 PM Larry Garfield wrote:
>
> If you clone the object, you don't duplicate 15+1 zvals. You duplicate just
> the one zval for the object itself, which reuses the existing 15 internal
> property entries. If in the new object you then update just the third one,
> PHP
On Wed, Dec 2, 2020 at 10:46 AM G. P. B. wrote:
> The reason why this has been deferred is because of which semantics should
> be used for duplicate string keys.
>
> Do we use the addition between two arrays semantics or the array_merge()
> semantics? See: https://3v4l.org/7QbWv
array_merge is th
On Sat, Jul 25, 2020 at 9:30 AM Chuck Adams wrote:
>
> Not a fan of special syntax for environment variables regardless of
> the syntax. I think `$_ENV['foo'] ?? 'bar'` is fine as-is. Not so
> much the superglobal, but there's also getenv().
I feel fairly
On Fri, Jul 24, 2020 at 2:54 PM Derek Bonner wrote:
> * memory_limit = ${PHP_MEMORY_LIMIT:-"default value"}
> * memory_limit = ${PHP_MEMORY_LIMIT::"default value"}
> * memory_limit = ${PHP_MEMORY_LIMIT:="default value"}
> * memory_limit = ${PHP_MEMORY_LIMIT=="default value"}
Not a fan of special
On Fri, Jul 24, 2020 at 1:32 PM Rowan Tommins wrote:
> If anything, I would argue for making both of these into errors, if
> that's possible. I think the biggest risk with this kind of change is
> not existing code relying on the old behaviour, it is code relying on
> the *new* behaviour which is
On Sat, Jul 11, 2020 at 8:56 AM Rowan Tommins wrote:
> (and, funnily enough, PHP 4 did for objects).
The funny thing about it for me is that this behavior caused me to
throw such a fit when I discovered it -- more to say burned by it --
that I swore off PHP forever at the time. Now I actually w
On Sat, Jul 11, 2020 at 8:06 AM Olle Härstedt wrote:
>
> Dear internals,
>
> I'd like to discuss the concept of ownership in PHP, from the point of
> view of a new interface UniqueInterface (or SplUniqueInterface or
> something), which will throw a UniqueException if refcount > 1.
>
> Use-case: Mu
> Then the question becomes, do we rename parameters a lot? I doubt it's a
> large problem, and even then the variadics support makes it very easy to
> handle in a backwards compatible way. In addition libraries are always open
> to declare they don't consider named parameters as part of their API.
I might suggest that we at least confine any renaming to things that
are user-visible and not worry about the source code. Except they're
going to need aliases for all time, that's just a fact. Although I'm
all about addressing the injustices of the past and present, I think
it would be a lot mor
Oh man, not this again, not here. Nothing intelligent ever comes out of this.
Looks like most instances in the PHP source refer to mysql constants,
which means the ball would be in mysql's court. Reality is you'd
still need the aliases that contain the offending word.
The other is in ext/standa
> 1. It aligns with the addition of the functions referenced in the
original post (`str_[contains|starts_with|ends_with]()`), and one
their stated reasons of simplifying the API for userland developers.
Two reactions to this: One, reflection isn't a facility for novices,
so there's no need to cate
(Trying again without a plussed address, which is too much hassle for
the ML. Sorry for dups.)
Honestly, I'd rather PHP didn't barf raw lex tokens to the end user
for its output. But until then, renaming it seems wise.
Didn't someone come out and claim that the current token is misspelled
Hebre
22 matches
Mail list logo