Debugging and the execution path
alex at tweedly.net
Wed Dec 21 20:52:40 EST 2005
Jerry Daniels wrote:
> I threw together a quick Var Watcher last night that puts the calling
> path into a pop up menu above the vars, much like Rev's Var Watcher
> does. Each item in the menu looks like this:
> stack "save test"/button "Button"/handler "mouseUp"/line: 7
I find that a bit verbose.
> The label of the pop up menu is the current execution context.
> Clicking the menu displays the calling path in order from last to
> first in the format you see above. The format is easy to change if
> you think it would look better some other way. I also thought of
> making more like the transcript syntax:
> line "7" of handler "mouseUp" of button "button" of stack "save
> Not sure which approach more clearly delineates that item as part of
> the calling path.
And that even more verbose :-)
I'd consider suppressing the stack name unless it is different from the
breakpoint's stack name.
I would like to see it as brief as possible, with an easy way to get the
full version (such as pop-up text like a tooltip for the full info, with
only object / handler / line shown normally).
> Funtionality: I made the menu switch execution contexts upon picking
> another menu item. In terms of the list of vars, upon clicking they
> are editable.
> What puzzles me is the fact that every one wanted the calling path
> when, as far as I can tell, it's already in the Rev Var Watcher. They
> call it the "execution contexts." Please tell me if I'm missing
Rev VW has only partial info - it's missing the handler name which is
one of the the most important parts.
> Conclusion: I'm not sure that the watcher I built would offer much
> new, other than the fact that it would reside in the upper two panes
> of Constellation where the props and previews sit ordinarily. I could
> make the array elements editable, I suppose.
There is lots of value waiting to be added :-)
- currently you can only see data in an array by clicking on that
variable to see each element in the "extended" display area; you could
display the first few elements in the "line per variable" display.
- same issue for multi-line variables; you could (as an option) display
e.g. "\n" or "\r\n" for the newlines, and hence show a few lines
directly in "line per var" mode
- make it an expression watcher - i.e. allow the user to specify an
expression to evaluate & display
- allow user-selection of variables to hide or display (and hence
eliminate scrolling back and forwards to see the two or three variables
that are most interesting).
- highlight values changed since last display
- allow display of variables from another context
That's enough for a (good) start :-)
Alex Tweedly http://www.tweedly.net
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.371 / Virus Database: 267.14.2/208 - Release Date: 20/12/2005
More information about the Use-livecode