Re: [RFC] Pass Scope to Magic Accessors
| From: | Marco Pivetta | Date: | Thu, 19 Jan 2023 19:31:06 +0000 |
| Subject: | Re: [RFC] Pass Scope to Magic Accessors | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-119356@lists.php.net to get a copy of this message | ||
Hey Ilija!
On Thu, 19 Jan 2023, 20:26 Ilija Tovilo, <tovilo.ilija@gmail.com> wrote:
> However, as demonstrated by the 3v4l, it's not
> exactly trivial. It also requires the full stack trace, as well as all
> frame objects and arguments. That's not going to be great for
> performance. So saying debug_backtrace() exists for this purpose is
> misleading, to say the least.
>
Meh, I made the kinkiest code work that way, and it's mostly for edge
cases: I would raise this as a problem once:
1. The use-case is not kinky
2. The performance benefits are so large that they warrant a language
change
Integration-testing code that uses
debug_backtrace() is usually
sufficient for making this stuff work.
>