Trying to do a simple time command for procs...can't get output into console...
- From: daneyul <danielb@xxxxxxxxxxxxxxxxxxxxx>
- Date: 27 Apr 2007 15:10:32 -0700
Hi,
Does anyone have a good generic method of easily timing every proc in
an application for diagnostics? Something that can be turned on and
off at will by simply redefining the proc command? I'm trying from a
freewrapped app, using the following at the beginning of the script,
but I'm failing miserably...
proc TimeProcs {} {
console show
rename ::proc ::proc2
::proc2 ::proc {name vars body} {
::proc2 $name $vars "time {$body}"
}
}
While this doesn't fail, and all the procedures in the script
function, I can't come up with a way to put the time output into the
console.
Inserting a puts command before the time command in the new proc2
procedure gets me into quoting hell. No method seems to work here for
actually getting the output into the console.
Any help would be appreciated!
-Danny
.
- Prev by Date: Re: tk_getOpenFile segmentation fault with PDFs
- Next by Date: Trying to do a simple time command for procs...can't get output into console...
- Previous by thread: file: extract data after finding string match
- Next by thread: Trying to do a simple time command for procs...can't get output into console...
- Index(es):
Relevant Pages
|