Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-02 Thread Christoph M. Becker
On 02.10.2024 at 12:55, Gina P. Banyard wrote: > On Wednesday, 2 October 2024 at 00:32, Larry Garfield > wrote: > >> I have no strong opinions on this RFC as I've not paid close attention to >> it, but "we can't introduce an unnamespaced class, that's a BC break" is >> simply not true, and not

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-02 Thread Gina P. Banyard
On Wednesday, 2 October 2024 at 00:32, Larry Garfield wrote: > > I have no strong opinions on this RFC as I've not paid close attention to it, > but "we can't introduce an unnamespaced class, that's a BC break" is simply > not true, and not consistent with how Internals and the stdlib are and

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-01 Thread Rob Landers
On Tue, Oct 1, 2024, at 23:02, Nick Lockheart wrote: > > > > Hey Nick, > > > > Is this actually an issue though? \Directory would be a weird thing > > to autoload. Most people tend to autoload specific namespaces. I > > think it would be weird to autoload into the global namespace. > > > > Maybe

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-01 Thread Nick Lockheart
On Tue, 2024-10-01 at 18:32 -0500, Larry Garfield wrote: > On Tue, Oct 1, 2024, at 4:02 PM, Nick Lockheart wrote: > > > > > Which is why anyone creating a global namespace class, especially > with a generic name like that, in 2024 is Doing PHP Wrong(tm). OK. I'm going to go back to writing fast,

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-01 Thread Larry Garfield
On Tue, Oct 1, 2024, at 4:02 PM, Nick Lockheart wrote: >> >> Hey Nick, >> >> Is this actually an issue though? \Directory would be a weird thing >> to autoload. Most people tend to autoload specific namespaces. I >> think it would be weird to autoload into the global namespace. >> >> Maybe I am

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-01 Thread Nick Lockheart
> > Hey Nick, > > Is this actually an issue though? \Directory would be a weird thing > to autoload. Most people tend to autoload specific namespaces. I > think it would be weird to autoload into the global namespace. > > Maybe I am wrong, and that is why I ask. > > — Rob In a situation where

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-01 Thread Rob Landers
On Tue, Oct 1, 2024, at 22:21, Nick Lockheart wrote: > On Tue, 2024-10-01 at 16:36 +, Gina P. Banyard wrote: > > On Wednesday, 25 September 2024 at 10:12, Nick Lockheart > > wrote: > > > > > On Sat, 2024-09-14 at 15:33 +, Gina P. Banyard wrote: > > > I don't suppose we could call the Dire

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-01 Thread Nick Lockheart
On Tue, 2024-10-01 at 16:36 +, Gina P. Banyard wrote: > On Wednesday, 25 September 2024 at 10:12, Nick Lockheart > wrote: > > > On Sat, 2024-09-14 at 15:33 +, Gina P. Banyard wrote: > > I don't suppose we could call the Directory class something else, > > like > > "SPLDirectory"? > > > >

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-01 Thread Gina P. Banyard
On Tuesday, 24 September 2024 at 13:25, Gina P. Banyard wrote: > On Saturday, 14 September 2024 at 16:33, Gina P. Banyard intern...@gpb.moe > wrote: > > > Hello internals, > > > > I came across the Directory class while doing some code exploration of > > ext/standard. > > This class is effec

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-10-01 Thread Gina P. Banyard
On Wednesday, 25 September 2024 at 10:12, Nick Lockheart wrote: > On Sat, 2024-09-14 at 15:33 +, Gina P. Banyard wrote: > I don't suppose we could call the Directory class something else, like > "SPLDirectory"? > > You can't make a Directory with `new` (or at least you aren't supposed > to

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-25 Thread Nick Lockheart
On Sat, 2024-09-14 at 15:33 +, Gina P. Banyard wrote: > Hello internals, > > I came across the Directory class while doing some code exploration > of ext/standard. > This class is effectively an opaque object for Directory resources, > however it doesn't behave like one, as it has existed sinc

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-24 Thread Gina P. Banyard
On Tuesday, 24 September 2024 at 14:34, Christian Schneider wrote: > Am 14.09.2024 um 17:33 schrieb Gina P. Banyard intern...@gpb.moe: > > > I came across the Directory class while doing some code exploration of > > ext/standard. > > This class is effectively an opaque object for Directory res

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-24 Thread Christian Schneider
Am 14.09.2024 um 17:33 schrieb Gina P. Banyard : > I came across the Directory class while doing some code exploration of > ext/standard. > This class is effectively an opaque object for Directory resources, however > it doesn't behave like one, as it has existed since PHP 4. > > As such, I am p

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-24 Thread Gina P. Banyard
On Saturday, 14 September 2024 at 16:33, Gina P. Banyard wrote: > Hello internals, > > I came across the Directory class while doing some code exploration of > ext/standard. > This class is effectively an opaque object for Directory resources, however > it doesn't behave like one, as it has e

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-17 Thread Christoph M. Becker
On 17.09.2024 at 18:03, Gina P. Banyard wrote: > On Saturday, 14 September 2024 at 18:48, Christoph M. Becker > wrote: > >> On 14.09.2024 at 17:33, Gina P. Banyard wrote: >> >>> RFC: https://wiki.php.net/rfc/directory-opaque-object >> >> As I see it, an opaque object is an object which doesn't h

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-17 Thread Gina P. Banyard
On Saturday, 14 September 2024 at 18:48, Christoph M. Becker wrote: > On 14.09.2024 at 17:33, Gina P. Banyard wrote: > > > I came across the Directory class while doing some code exploration of > > ext/standard. > > This class is effectively an opaque object for Directory resources, however >

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-17 Thread Gina P. Banyard
On Monday, 16 September 2024 at 18:31, Derick Rethans wrote: > On Sat, 14 Sep 2024, Gina P. Banyard wrote: > > > I came across the Directory class while doing some code exploration of > > ext/standard. This class is effectively an opaque object for Directory > > resources, however it doesn't beh

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-16 Thread Christoph M. Becker
On 16.09.2024 at 18:31, Derick Rethans wrote: > On Sat, 14 Sep 2024, Gina P. Banyard wrote: > >> I came across the Directory class while doing some code exploration of >> ext/standard. This class is effectively an opaque object for Directory >> resources, however it doesn't behave like one, as it

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-16 Thread Derick Rethans
On Sat, 14 Sep 2024, Gina P. Banyard wrote: > I came across the Directory class while doing some code exploration of > ext/standard. This class is effectively an opaque object for Directory > resources, however it doesn't behave like one, as it has existed since > PHP 4. > > As such, I am prop

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-14 Thread David CARLIER
Seems right thing to do. I saw some usage like final class Dir extends Directory { } also did not see much in *new* codes Directory being extended so 8.5 sure. Cheers. On Sat, 14 Sept 2024 at 16:36, Gina P. Banyard wrote: > Hello internals, > > I came across the Directory class while doing s

Re: [PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-14 Thread Christoph M. Becker
On 14.09.2024 at 17:33, Gina P. Banyard wrote: > I came across the Directory class while doing some code exploration of > ext/standard. > This class is effectively an opaque object for Directory resources, however > it doesn't behave like one, as it has existed since PHP 4. > > As such, I am pro

[PHP-DEV] [RFC] Change Directory class to behave like an opaque object

2024-09-14 Thread Gina P. Banyard
Hello internals, I came across the Directory class while doing some code exploration of ext/standard. This class is effectively an opaque object for Directory resources, however it doesn't behave like one, as it has existed since PHP 4. As such, I am proposing an RFC to turn this class into an