Re: [PHP-DEV] [RFC] Deprecations for PHP 8.4

2024-07-01 Thread Marc Bennewitz
Hi Gina, On 25.06.24 16:36, Gina P. Banyard wrote: Hello internals, It is this time of year again where we proposed a list of deprecations to add in PHP 8.4: https://wiki.php.net/rfc/deprecations_php_8_4 As a reminder, this list has been compiled over the course of the past year by various

Re: [PHP-DEV] [Discussion] Add date_test_set_now() function

2024-07-01 Thread Rob Landers
On Mon, Jul 1, 2024, at 15:07, Go Kudo wrote: > Hi, Internals. > > I've been absent for a long time due to poor health. I'm finally back. > > I maintain a legacy application written in PHP, and occasionally need to fake > the current time for testing purposes. However, PHP doesn't provide a >

Re: [PHP-DEV] [Discussion] Add date_test_set_now() function

2024-07-01 Thread Andreas Heigl
Hey Am 01.07.24 um 15:07 schrieb Go Kudo: Hi, Internals. I've been absent for a long time due to poor health. I'm finally back. I maintain a legacy application written in PHP, and occasionally need to fake the current time for testing purposes. However, PHP doesn't provide a standard way to

Re: [PHP-DEV] [Discussion] Add date_test_set_now() function

2024-07-01 Thread Alexandru Pătrănescu
> > > https://github.com/colopl/php-colopl_timeshifter > > However, this Extension has some problems. > > The first is that there's no way to determine whether the format passed to > the ext-date parser is relative or absolute time, resulting in a dirty hack > using usleep. The second is that it de

Re: [PHP-DEV] Re: [Discussion] Add date_test_set_now() function

2024-07-01 Thread Go Kudo
Hi. > So don't do that. Relying on global mutable state is a bug. That older parts of the stdlib made that mistake doesn't mean we should continue it. (See also the Random extension, which also works to avoid global mutable state.) I generally agree. However, I have some questions. It's true

Re: [PHP-DEV] Re: [Discussion] Add date_test_set_now() function

2024-07-01 Thread Lanre
On Mon, Jul 1, 2024 at 2:21 PM Jorg Sowa wrote: > > You don’t make any effort to help or provide constructive criticism; you > just love to (incorrectly) tell everyone what they're doing wrong and how > they should be doing it, without adding anything constructive to the > conversation. > > Pleas

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Mike Schinkel
> On Jul 1, 2024, at 5:07 PM, Rob Landers wrote: > > On Mon, Jul 1, 2024, at 18:22, Mike Schinkel wrote: >> > On Jul 1, 2024, at 7:57 AM, Arvids Godjuks > > > wrote: >> > >> > TL;DR: As a userland developer, in my opinion, this is just a downgrade >> > from what

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Mike Schinkel
> On Jul 1, 2024, at 4:54 PM, Jordan LeDoux wrote: > On Mon, Jul 1, 2024 at 11:09 AM Mike Schinkel > wrote: > > > and I'm fairly certain after keeping up with the thread that it is almost > > universally not what people want. Most people just want the toolbox be > >

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Rob Landers
On Mon, Jul 1, 2024, at 18:22, Mike Schinkel wrote: > > On Jul 1, 2024, at 7:57 AM, Arvids Godjuks wrote: > > > > TL;DR: As a userland developer, in my opinion, this is just a downgrade > > from what we have now. Enhance namespaces to have the ability to have > > internal/private classes, inter

Re: [PHP-DEV] [RFC] Property Hook improvements

2024-07-01 Thread Larry Garfield
On Mon, Jul 1, 2024, at 8:32 PM, Tim Düsterhus wrote: > Hi > > On 7/1/24 19:02, Larry Garfield wrote: >> I'd say we expect these to be uncontroversial, but this is PHP. :-) So I >> will instead just note that it's a short RFC and open the discussion >> accordingly. > > Big fan of the performance

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Jordan LeDoux
On Mon, Jul 1, 2024 at 11:09 AM Mike Schinkel wrote: > > > and I'm fairly certain after keeping up with the thread that it is > almost universally not what people want. Most people just want the toolbox > be "finished" so to speak, not get a completely new one in addition that > has no compatibil

Re: [PHP-DEV] [RFC] Property Hook improvements

2024-07-01 Thread Tim Düsterhus
Hi On 7/1/24 19:02, Larry Garfield wrote: I'd say we expect these to be uncontroversial, but this is PHP. :-) So I will instead just note that it's a short RFC and open the discussion accordingly. Big fan of the performance improvement, given that I convinced Ilija to look into that once mo

Re: [PHP-DEV] [RFC] [discussion] Correctly name the rounding mode and make it an Enum

2024-07-01 Thread Tim Düsterhus
Hi On 5/31/24 16:49, Saki Takamachi wrote: I would like to start an RFC discussion regarding rounding modes. https://wiki.php.net/rfc/correctly_name_the_rounding_mode_and_make_it_an_enum We already wanted to announce the RFC vote, but then I forgot to do so and then Claude's email came in. Oh

Re: [PHP-DEV] Re: [Discussion] Add date_test_set_now() function

2024-07-01 Thread Jorg Sowa
> You don’t make any effort to help or provide constructive criticism; you just love to (incorrectly) tell everyone what they're doing wrong and how they should be doing it, without adding anything constructive to the conversation. Please limit to the arguments on the topic, not a person. The arg

Re: [PHP-DEV] [RFC] [discussion] Correctly name the rounding mode and make it an Enum

2024-07-01 Thread Tim Düsterhus
Hi please apologize the delay in getting back to you. I was absolutely swamped with mailing list mails, other work and I didn't want to give a reply that I did not give any thought. On 6/19/24 21:14, Claude Pache wrote: Second, “TowardsPositiveInfinity” is just a mouthful synonym for “Up”. Y

Re: [PHP-DEV] Re: [Discussion] Add date_test_set_now() function

2024-07-01 Thread Lanre
On Mon, Jul 1, 2024 at 12:42 PM Lanre wrote: > Larry, > > Your absolutes and comments like "Relying on global mutable state is a > bug" are incredibly frustrating. Are the authors of Carbon and Chronos, the > two biggest userland time libraries, somehow wrong because they aren’t you? > Do you thi

Re: [PHP-DEV] Re: [Discussion] Add date_test_set_now() function

2024-07-01 Thread Lanre
Larry, Your absolutes and comments like "Relying on global mutable state is a bug" are incredibly frustrating. Are the authors of Carbon and Chronos, the two biggest userland time libraries, somehow wrong because they aren’t you? Do you think they didn’t put any thought into their decisions and ju

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Mike Schinkel
> On Jul 1, 2024, at 1:07 PM, Dusk wrote: > > On Jul 1, 2024, at 09:22, Mike Schinkel wrote: >> 2. Autoloading effectively necessitates that every symbol be in its own >> separate file. > > How so? While Composer "recommends" PSR4 autoloading with one class per file, > other configurations ar

Re: [PHP-DEV] [RFC] Property Hook improvements

2024-07-01 Thread Larry Garfield
On Mon, Jul 1, 2024, at 5:28 PM, Lynn wrote: > "A side effect of that optimization, however, is that we cannot > proactively detect the bug above. Instead, it would result in an > infinite loop, which would eventually trigger a a stack overflow." > > This got a small typo ("a a" at the end). F

Re: [PHP-DEV] [RFC] Property Hook improvements

2024-07-01 Thread Lynn
On Mon, Jul 1, 2024 at 7:05 PM Larry Garfield wrote: > Hi folks. As Ilija's been polishing off hooks to get the PR merged, we've > run into two small revisions that should make life better for all > involved. One is a performance improvement that requires a very slight > error handling behavior

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Arvids Godjuks
On Mon, 1 Jul 2024 at 19:22, Mike Schinkel wrote: > > On Jul 1, 2024, at 7:57 AM, Arvids Godjuks > wrote: > > > > TL;DR: As a userland developer, in my opinion, this is just a downgrade > from what we have now. Enhance namespaces to have the ability to have > internal/private classes, interfaces

Re: [PHP-DEV] [Initial Feedback] Typed Arrays

2024-07-01 Thread Rob Landers
On Mon, Jul 1, 2024, at 15:14, Larry Garfield wrote: > On Mon, Jul 1, 2024, at 12:21 PM, Richard Miles wrote: > > Howdy Rob, > > > >>> I appreciate your feedback, and I think it’s valid. I try to compare my > >>> expectations to what is possible in typescript. > >> > >> I feel like Typescript i

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Dusk
On Jul 1, 2024, at 09:22, Mike Schinkel wrote: > 2. Autoloading effectively necessitates that every symbol be in its own > separate file. How so? While Composer "recommends" PSR4 autoloading with one class per file, other configurations are entirely possible, either with Composer's autoload.cl

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Alexander Pravdin
On Tue, Jul 2, 2024 at 1:20 AM Rowan Tommins [IMSoP] wrote: > On 1 July 2024 15:37:49 CEST, Alexander Pravdin > wrote: > >I personally support the movement from the current "plain-text > >template-first" language to a "coding-first" language, where files > >contain code by default. > > I honestl

[PHP-DEV] [RFC] Property Hook improvements

2024-07-01 Thread Larry Garfield
Hi folks. As Ilija's been polishing off hooks to get the PR merged, we've run into two small revisions that should make life better for all involved. One is a performance improvement that requires a very slight error handling behavior change, and the other is enabling readonly in selected (but

Re: [PHP-DEV] Re: [Discussion] Add date_test_set_now() function

2024-07-01 Thread Larry Garfield
On Mon, Jul 1, 2024, at 3:56 PM, Go Kudo wrote: > I apologize, the main point of my explanation was off. > > To put it simply, I'm suggesting that it might be good to implement > convenient and commonly used features from Carbon at the ext-date level. > > I'm proposing the date_test_set_now() fun

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Mike Schinkel
> On Jul 1, 2024, at 9:00 AM, Larry Garfield wrote: > 3. Using URLs as the package naming system is the dumbest thing Go ever did. > Let's not replicate that. :-) This is probably the wrong thread and maybe even the wrong list to discuss this, but having programmed in PHP for a decade and then

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Mike Schinkel
> On Jul 1, 2024, at 7:57 AM, Arvids Godjuks wrote: > > TL;DR: As a userland developer, in my opinion, this is just a downgrade from > what we have now. Enhance namespaces to have the ability to have > internal/private classes, interfaces, enums and constants. That's about it. Please note my c

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Rowan Tommins [IMSoP]
On 1 July 2024 15:37:49 CEST, Alexander Pravdin wrote: >I personally support the movement from the current "plain-text >template-first" language to a "coding-first" language, where files >contain code by default. I honestly don't read the

Re: [PHP-DEV] [Initial Feedback] Typed Arrays

2024-07-01 Thread Richard Miles
Hey Larry, >> interface iArrayA ['a' => string ] >> interface iArrayB extends iArrayA ['b' => string, 'c' => ?string, ‘d’ >> => SomeClass, ‘e’=> iArrayA, ‘f’ => mixed ] >> $array = (iArrayA &| iArrayB) [ ‘a’ => ‘hello’ ]; I will start by advocating for how much cleaner this is from its object

[PHP-DEV] Re: [Discussion] Add date_test_set_now() function

2024-07-01 Thread Go Kudo
2024年7月1日(月) 22:07 Go Kudo : > Hi, Internals. > > I've been absent for a long time due to poor health. I'm finally back. > > I maintain a legacy application written in PHP, and occasionally need to > fake the current time for testing purposes. However, PHP doesn't provide a > standard way to fake

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Alexander Pravdin
Sorry for getting into this hot topic. Just wanted to add my two cents. > Really, the only targets we should be looking at, IMO, are: > > 1. Package-level visibility. > 2. Giving the compiler/optimizer/JIT a larger "scope" of code to > compile/optimize at once, so it can do smarter things. > > I

Re: [PHP-DEV] [Discussion] Add date_test_set_now() function

2024-07-01 Thread Larry Garfield
On Mon, Jul 1, 2024, at 1:07 PM, Go Kudo wrote: > Hi, Internals. > > I've been absent for a long time due to poor health. I'm finally back. > > I maintain a legacy application written in PHP, and occasionally need > to fake the current time for testing purposes. However, PHP doesn't > provide a s

Re: [PHP-DEV] [Initial Feedback] Typed Arrays

2024-07-01 Thread Larry Garfield
On Mon, Jul 1, 2024, at 12:21 PM, Richard Miles wrote: > Howdy Rob, > >>> I appreciate your feedback, and I think it’s valid. I try to compare my >>> expectations to what is possible in typescript. >> >> I feel like Typescript is the wrong model to follow. The type system in >> Typescript is Tur

[PHP-DEV] [Discussion] Add date_test_set_now() function

2024-07-01 Thread Go Kudo
Hi, Internals. I've been absent for a long time due to poor health. I'm finally back. I maintain a legacy application written in PHP, and occasionally need to fake the current time for testing purposes. However, PHP doesn't provide a standard way to fake the current time, so I've been changing th

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Larry Garfield
On Sun, Jun 30, 2024, at 8:28 PM, Michael Morris wrote: > So let's take another crack at this based on all the points raised in > the thread. This should also underline why I don't consider this an RFC > - I am iterating until we arrive at something that may be refinable > into an RFC. And I say

Re: [PHP-DEV] Re: VCS Account Request: youkidearitai

2024-07-01 Thread youkidearitai
2024年7月1日(月) 21:19 Ilija Tovilo : > > Hi Yuya! > > On Sat, Jun 29, 2024 at 11:11 PM youkidearitai > wrote: > > > > 2024年4月9日(火) 7:55 youkidearitai : > > > > > > Mainly review and approve pull request to mbstring extension. > > > (probably everything related to Unicode and other character encoding

Re: [PHP-DEV] [Initial Feedback] Typed Arrays

2024-07-01 Thread Larry Garfield
On Mon, Jul 1, 2024, at 4:48 AM, Michał Marcin Brzuchalski wrote: > pon., 1 lip 2024 o 03:01 Larry Garfield napisał(a): >> Contextual point: Nearly every other major language at this point that has a >> meaningful standard library has gone with a three-separate-object approach >> (Seq, Set, Dic

Re: [PHP-DEV] [Initial Feedback] Typed Arrays

2024-07-01 Thread Richard Miles
Howdy Rob, >> I appreciate your feedback, and I think it’s valid. I try to compare my >> expectations to what is possible in typescript. > > I feel like Typescript is the wrong model to follow. The type system in > Typescript is Turing Complete > (https://github.com/microsoft/TypeScript/issues

Re: [PHP-DEV] Iteration III: Packages (was Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript)

2024-07-01 Thread Arvids Godjuks
On Sun, 30 Jun 2024 at 23:30, Michael Morris wrote: > So let's take another crack at this based on all the points raised in the > thread. This should also underline why I don't consider this an RFC - I am > iterating until we arrive at something that may be refinable into an RFC. > And I say we b

Re: [PHP-DEV] Re: VCS Account Request: youkidearitai

2024-07-01 Thread Ilija Tovilo
Hi Yuya! On Sat, Jun 29, 2024 at 11:11 PM youkidearitai wrote: > > 2024年4月9日(火) 7:55 youkidearitai : > > > > Mainly review and approve pull request to mbstring extension. > > (probably everything related to Unicode and other character encoding) > > Alex Dowad (alexdowad) suggested that give to me

Re: [PHP-DEV] [Initial Feedback] PHP User Modules - An Adaptation of ES6 from JavaScript

2024-07-01 Thread Peter Bowyer
On Thu, 27 Jun 2024 at 03:22, Michael Morris wrote: > ``` > import foo from "foo.php" > ``` > I'd strongly recommend the autocomplete-friendly order instead: ``` from "foo.php" import foo ``` Overall I am keen on module/package support of some kind that allows for visibility control at the boun