Re: [PHP-DEV] Local constants

2024-09-06 Thread Rowan Tommins [IMSoP]
On Fri, 6 Sep 2024, at 03:01, Mike Schinkel wrote: >> Block-scoping doesn't have to allow shadowing of names, > > How exactly would that work? Are you suggesting to restrict the use of > variable names to one per function but still allow for block scoping? Yes. That's how C# works, for example

Re: [PHP-DEV] function autoloading v4 RFC

2024-09-06 Thread Jakob Givoni
Hi Rob, On Thu, Sep 5, 2024 at 10:45 PM Rob Landers wrote: > On Thu, Sep 5, 2024, at 21:03, Jakob Givoni wrote: > > > > On Wed, Sep 4, 2024 at 9:18 PM Rob Landers wrote: > > > On Wed, Sep 4, 2024, at 17:16, Jakob Givoni wrote: > > > > 2. I've removed artificial restrictions on the constants in

Re: [PHP-DEV] function autoloading v4 RFC

2024-09-06 Thread Jakob Givoni
On Thu, Sep 5, 2024 at 10:58 PM Rob Landers wrote: > On Thu, Sep 5, 2024, at 21:03, Jakob Givoni wrote: > > > > On Wed, Sep 4, 2024 at 9:18 PM Rob Landers wrote: > > > On Wed, Sep 4, 2024, at 17:16, Jakob Givoni wrote: > > > > 2. I've removed artificial restrictions on the constants in which all

Re: [PHP-DEV] Where to document configuration option changes?

2024-09-06 Thread Christoph M. Becker
On 06.09.2024 at 16:38, Remi Collet wrote: > Hi, > > Le 04/09/2024 à 15:04, Christoph M. Becker a écrit : >> Hi all, >> >> that issue came up the other day on a pull request[1], but since it is >> not particularly related to any single PR, I wanted to ask here for >> clarification. >> >> This is a

Re: [PHP-DEV] RFC: Deprecate json_encode() on classes marked as non-serializable

2024-09-06 Thread Claude Pache
> Le 5 sept. 2024 à 18:03, John Coggeshall a écrit : > > > As per my previous email to the list, I have now created the official RFC to > deprecate calling json_serialize() on instances of classes marked with > ZEND_ACC_NOT_SERIALIZABLE. > > I would suggest we take a step back from this and

Re: [PHP-DEV] RFC: Deprecate json_encode() on classes marked as non-serializable

2024-09-06 Thread John Coggeshall
On Sep 6 2024, at 2:07 pm, Claude Pache wrote: > > > > Le 5 sept. 2024 à 18:03, John Coggeshall a écrit : > > > > > As per my previous email to the list, I have now created the official RFC > > > to deprecate calling json_serialize() on instances of classes marked with > > > ZEND_ACC_NOT_SERI

[PHP-DEV] bikeshed: Typed Aliases

2024-09-06 Thread Rob Landers
Hello Internals, I'm going to try something new. I've been working on another RFC called "Typed Aliases" (https://wiki.php.net/rfc/typed-aliases). It is very much a draft and in-flux, and I've already worked out the technical mechanics of it ... however, I am very unhappy with the syntax, and w

Re: [PHP-DEV] RFC: Deprecate json_encode() on classes marked as non-serializable

2024-09-06 Thread Rob Landers
On Fri, Sep 6, 2024, at 20:07, Claude Pache wrote: > > >> Le 5 sept. 2024 à 18:03, John Coggeshall a écrit : >> >> >>> As per my previous email to the list, I have now created the official RFC >>> to deprecate calling json_serialize() on instances of classes marked with >>> ZEND_ACC_NOT_SERI

[PHP-DEV] Re: [RFC] Decoding HTML and the Ambiguous Ampersand

2024-09-06 Thread Dennis Snell
All, I have updated the RFC document by adding a section on the proposed HtmlContext enum, with some extra contexts than were originally discussed (but which were added to the implementation). As I’ve been a bit distracted this has taken a bit of a backseat but I am still interested in keeping

Re: [PHP-DEV] Local constants

2024-09-06 Thread Mike Schinkel
> On Sep 6, 2024, at 4:47 AM, Rowan Tommins [IMSoP] > wrote: > > On Fri, 6 Sep 2024, at 03:01, Mike Schinkel wrote: >>> Block-scoping doesn't have to allow shadowing of names, >> >> How exactly would that work? Are you suggesting to restrict the use of >> variable names to one per function b

Re: [PHP-DEV] bikeshed: Typed Aliases

2024-09-06 Thread Larry Garfield
On Fri, Sep 6, 2024, at 1:41 PM, Rob Landers wrote: > Hello Internals, > > I'm going to try something new. I've been working on another RFC called > "Typed Aliases" (https://wiki.php.net/rfc/typed-aliases). It is very > much a draft and in-flux, and I've already worked out the technical > mechan

Re: [PHP-DEV] bikeshed: Typed Aliases

2024-09-06 Thread Rob Landers
On Fri, Sep 6, 2024, at 22:45, Larry Garfield wrote: > Hi Rob. > > First of all, I'm very much in favor of type aliases generally, so thank you > for taking a swing at this. > > Second, it looks like you've run into the main design issue that has always > prevented them in the past: Should alia

Re: [PHP-DEV] bikeshed: Typed Aliases

2024-09-06 Thread Larry Garfield
On Fri, Sep 6, 2024, at 6:27 PM, Rob Landers wrote: >> I suspect there's also other edge case bits to worry about, particularly if >> trying to combine a complex alias with a complex type, which could lead to >> violating the DNF rule. For example: > > Oh, DNF is the bane of my existence with t

Re: [PHP-DEV] bikeshed: Typed Aliases

2024-09-06 Thread Rob Landers
On Sat, Sep 7, 2024, at 01:34, Larry Garfield wrote: > On Fri, Sep 6, 2024, at 6:27 PM, Rob Landers wrote: > > >> I suspect there's also other edge case bits to worry about, particularly > >> if trying to combine a complex alias with a complex type, which could lead > >> to violating the DNF r

Re: [PHP-DEV] bikeshed: Typed Aliases

2024-09-06 Thread Davey Shafik
> On Sep 6, 2024, at 16:40, Rob Landers wrote: > > > > On Sat, Sep 7, 2024, at 01:34, Larry Garfield wrote: >> On Fri, Sep 6, 2024, at 6:27 PM, Rob Landers wrote: >> >> >> I suspect there's also other edge case bits to worry about, particularly >> >> if trying to combine a complex alias with

Re: [PHP-DEV] bikeshed: Typed Aliases

2024-09-06 Thread Juliette Reinders Folmer
On 6-9-2024 20:41, Rob Landers wrote: - This RFC expands the "use ... as ..." syntax to allow any type expression on the left side. These aliases are PER FILE and expire once the file is compiled. Explicitly without expressing any opinion about the RFC, I'd just like to remind you that `use