Re: Short class syntax and inner classes

From: Date: Fri, 07 Feb 2025 15:05:54 +0000
Subject: Re: Short class syntax and inner classes
References: 1  Groups: php.internals 
Request: Send a blank email to [email protected] to get a copy of this message
Hi

Am 2025-02-07 15:23, schrieb Rob Landers:
Instantiation is done by static access: new Outer::Inner(1), which is currently a syntax error.
How would I access static members on an inner class without having ambiguity? Outer::Inner::Const already is valid syntax.
If this is a big "NO" (or if someone else has started working on this and I'm just so happening to accidentally step on their toes, again): I don't want to spend several days/weeks digging into the details for classes. However, it would probably look something like the above.
I believe Ilija has some proof-of-concept regarding file-private classes, which would sidestep the above problem of disambiguating static member access. Best regards Tim Düsterhus

Thread (4 messages)

« previous php.internals (#126333) next »