[xdebug-general] Re: General question about the debugger

From: Shawn Clark <shawn_d_clark[@]hotmail.com>
Date: Tue, 26 May 2009 00:54:33 -0700

Hi Matt,

Not sure if I am missing something here but that wouldn't show up in a log file but walking through the code with a debugger client would show you that information and a lot more. You can have the debugger stop at any line you want and look through the current assignment to the variables as well as step through the next line of code. My apologies if you are looking for something else and already knew about using a debugger client. If not do some google searches for php debugger clients (eclipse pdt and aptana both have Xdebug support).

Shawn Clark
Date: Sun, 24 May 2009 15:26:46 -0400
Subject: [xdebug-general] General question about the debugger
From: fatdogs12[@]gmail.com
To: xdebug-general[@]lists.xdebug.org
I think xdebug is very nice, especially being able to dump the stack trace to a file. My question is if it had been considered (or is possible. I'm not sure exactly) if it 
could also log the line by line execution of a file, I think this would allow you to very quickly find out what is the cause of the error and the conditions that caused it.
for example:
php source code:
$b = 2;
$c = 10;
$var = $b * $c;
if ($var > 10)
debug output code:
$b = 2;                       -> {$b = 2}
$c = 10;                     -> {$c = 10}
$var = $b * $c             -> {$var = 2 * 10}
if ($var >10)                -> {if (20 > 10) => TRUE }
    newFunction($var);  -> { newFunction(20) }
I know this is highly verbose and for complicated programs this could be a lot to sort through, 
but for all those bugs that end up taking maybe an hour or more to locate where the problem is even occurring
this seems like it could save an enormous amount of time.
Thanks very much for your time,
Internet explorer 8 lets you browse the web faster.
Received on Tue May 26 2009 - 09:54:41 BST

This archive was generated by hypermail 2.2.0 : Mon Jun 25 2018 - 06:00:04 BST