Re: Debug ops?

2004-11-01 Thread Nicholas Clark
On Mon, Nov 01, 2004 at 08:24:34PM +0100, Leopold Toetsch wrote: > Dan Sugalski <[EMAIL PROTECTED]> wrote: > > Sounds like a job for pre and post handlers for subs and methods > > Pah. Sounds like a debug variable in the interpreter context (what we > already have for errors and warnings - we

Re: Debug ops?

2004-11-01 Thread Leopold Toetsch
Dan Sugalski <[EMAIL PROTECTED]> wrote: >>This allows for example to run all your code with fatal threshold and >>then, when running into sub-that-is-supposed-to-be-all-bugged, you just >>activate debug level, and return to fatal after leaving it. This way you >>only get the traces you wanted - in

Re: Debug ops?

2004-11-01 Thread Dan Sugalski
At 7:17 PM +0100 11/1/04, Jerome Quelin wrote: On 04/11/01 11:17 -0500, Sam Ruby wrote: But either at startup or dynamically, individual loggers can be enabled to start (or stop) outputing messages that exceed a given threshhold (debug, info, warn, error, fatal). One thing that I really m

Re: Debug ops?

2004-11-01 Thread Jerome Quelin
On 04/11/01 11:17 -0500, Sam Ruby wrote: > But either at startup or dynamically, individual loggers can be > enabled to start (or stop) outputing messages that exceed a given > threshhold (debug, info, warn, error, fatal). One thing that I really miss in this kind of logging framework is t

Re: Debug ops?

2004-11-01 Thread Dan Sugalski
At 11:17 AM -0500 11/1/04, Sam Ruby wrote: Dan Sugalski wrote: I'm considering adding in some new ops and a command-line switch to help debug parrot code, but before I did I figured I'd better throw it out to the list for some debugging. (This seems like something which could be of good general

Re: Debug ops?

2004-11-01 Thread Dan Sugalski
y DS> to have more branching ops they can be left out. some random comments: it looks like you have only one debug flag/level. would multiple flags/levels be useful or hard to add? it would mean adding another arg to the debug ops. if given no arg, it would default to level 1/flag 1 or someth

Re: Debug ops?

2004-11-01 Thread Matt Fowles
All~ My work has a really useful macro trace that expands as followed #define trace(name_str, format_str, ...); \ { \ static bool traceMe = DO_WE_TRACE_THIS(name_str); \ if(traceMe) { \ DO_THE_TRACING(name_str, format_str, __VA_ARGS__); \ } \ } Where DO_WE_TRACE_THIS can use whatever heirachica

Re: Debug ops?

2004-11-01 Thread Leopold Toetsch
Dan Sugalski <[EMAIL PROTECTED]> wrote: > dprinterr [PISN]x - Like printerr, but only when running in debug mode > ifdebug label - If debug's on, branch to label > unlessdebug label - branch to label unless debugging's on > debugbsr label - do a bsr to the label if debugging's on Ok. > (

Re: Debug ops?

2004-11-01 Thread Timm Murray
On Monday 01 November 2004 10:17 am, Sam Ruby wrote: > Dan Sugalski wrote: > > I'm considering adding in some new ops and a command-line switch to help > > debug parrot code, but before I did I figured I'd better throw it out to > > the list for some debugging. (This seems like something which coul

Re: Debug ops?

2004-11-01 Thread Leopold Toetsch
Kj <[EMAIL PROTECTED]> wrote: > Maybe a bit off-topic (as it concerns pir syntax), but wouldn't it be > usefull if we had multi-line comments? =for comment =cut leo

Re: Debug ops?

2004-11-01 Thread Uri Guttman
ey can be left out. some random comments: it looks like you have only one debug flag/level. would multiple flags/levels be useful or hard to add? it would mean adding another arg to the debug ops. if given no arg, it would default to level 1/flag 1 or something like that. what about a compile time (byte

Re: Debug ops?

2004-11-01 Thread Sam Ruby
Dan Sugalski wrote: I'm considering adding in some new ops and a command-line switch to help debug parrot code, but before I did I figured I'd better throw it out to the list for some debugging. (This seems like something which could be of good general use, and as such I'd like to hash it out, d

Re: Debug ops?

2004-11-01 Thread Dan Sugalski
At 4:57 PM +0100 11/1/04, KJ wrote: Dan Sugalski wrote: I'm considering adding in some new ops and a command-line switch to help debug parrot code, but before I did I figured I'd better throw it out to the list for some debugging. (This seems like something which could be of good general use, an

Re: Debug ops?

2004-11-01 Thread KJ
Dan Sugalski wrote: I'm considering adding in some new ops and a command-line switch to help debug parrot code, but before I did I figured I'd better throw it out to the list for some debugging. (This seems like something which could be of good general use, and as such I'd like to hash it out, d

Debug ops?

2004-11-01 Thread Dan Sugalski
I'm considering adding in some new ops and a command-line switch to help debug parrot code, but before I did I figured I'd better throw it out to the list for some debugging. (This seems like something which could be of good general use, and as such I'd like to hash it out, do it once, and do i