Re: Future stability of PHP?

From: Date: Tue, 11 Apr 2023 16:16:03 +0000
Subject: Re: Future stability of PHP?
References: 1 2 3 4 5 6 7 8 9 10 11  Groups: php.internals 
Request: Send a blank email to internals+get-119934@lists.php.net to get a copy of this message
> Can you expand a bit more on your use-case? Here are some things I've deliberately used dynamic properties for: - development proxies (production uses compiled proxies) for remote objects [can use attribute or magic functions] - visitor pattern when hacking on parser packages [in PHP 9, "hacking" will be more complex if underlying package doesn't support dynamic properties] - "tagging" objects [can use weak maps now] - deserialization of user-submitted types to a base class [can just 'decorate' a stdClass] In brackets, I listed the 'solution' for avoiding dynamic properties, but FWIW, having dynamic properties available made it far easier to create 'POC-style' code that could be refactored/rewritten. I personally never saw a bug resulting from dynamic properties, but I might have just been lucky.

« previous php.internals (#119934) next »