Just like how variables values can be changed while stepping through code lines. Is it possible to add PHP statements between lines and let it run further after picking that up change?
Probably not even possible as the state of the codebase is already loaded into memory when it starts executing but I think it was worth a try.
Xdebug can do this. It's the exact same mechanism in the DBGp protocol as updating variables. This happens with the DBGp "eval" command, which as you can guess, runs PHP's eval function.
But it depends on the IDE whether they actually have implemented this. PhpStorm for example has its console, which is also a wrapper for this eval command. You can probably get away by using a real PHP statement in a "watch" as well.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With