Re: [RFC][DISCUSSION] debug_backtrace alternative as an array of StackFrame objects
| From: | Michał Marcin Brzuchalski | Date: | Thu, 09 Jul 2020 07:09:17 +0000 |
| Subject: | Re: [RFC][DISCUSSION] debug_backtrace alternative as an array of StackFrame objects | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-110887@lists.php.net to get a copy of this message | ||
Hi Mike
śr., 8 lip 2020 o 22:20 Mike Schinkel <mike@newclarity.net> napisał(a):
> Yes, excited to see this.
>
That’s good to hear.
> Would adding a method that allows getting a specific stack frame rather
> than the entire trace if you know which on you want take up less memory
> and/or perform better?
>
> Something like StackFrame::getFrame(1) which would be functionally
> equivalent to StackFrame::getTrace()[1]?
>
Indeed, this makes sense.
Since I already consider adding an
$offset parameter to getTrace(),
adding a dedicated static method will be trivial.
Cheers,
--
Michał Marcin Brzuchalski