Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Debugging of dynamocally defined functions
- X-seq: zsh-workers 15341
- From: Peter Stephenson <pws@xxxxxxx>
- To: zsh-workers@xxxxxxxxxx (Zsh hackers list)
- Subject: Re: Debugging of dynamocally defined functions
- Date: Mon, 09 Jul 2001 19:36:35 +0100
- In-reply-to: ""Bart Schaefer""'s message of "Mon, 09 Jul 2001 18:24:05 -0000." <1010709182405.ZM21152@xxxxxxxxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
"Bart Schaefer" wrote:
> I was fooling with almost exactly the same thing, though I'd been trying
> to figure out a nice way to embed the line number of the eval inside the
> `(eval)' string; e.g. for an eval on line 30 of the calling function you
> would see something like
>
> (30:eval):1: echo foo
> (30:eval):2: echo bar
>
> etc. However, as the placment of %i and the use of colons or whatnot is
> completely dependent on the PS4 setting, I couldn't decide how to do it
> such that it wouldn't garble somebody's pretty prompt.
Maybe we need to grab another prompt escape. Or maybe we could make a
stack of environments and line numbers and you can choose whether you want
the line number (e.g.) in the innermost eval, in the function above that,
or in the script the function is embedded in, fixing the other problem,
too --- if we can work out a way of deciding which the right one to print
at any given time is. Maybe this needs more work to make quite sure
scriptname and lineno are tied together. Maybe we can add an option to get
errors to print a backtrace of that. Maybe I'm rambling.
I've committed the patch for now.
--
Peter Stephenson <pws@xxxxxxx> Software Engineer
CSR Ltd., Unit 300, Science Park, Milton Road,
Cambridge, CB4 0XL, UK Tel: +44 (0)1223 392070
**********************************************************************
The information transmitted is intended only for the person or
entity to which it is addressed and may contain confidential
and/or privileged material.
Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by
persons or entities other than the intended recipient is
prohibited.
If you received this in error, please contact the sender and
delete the material from any computer.
**********************************************************************
Messages sorted by:
Reverse Date,
Date,
Thread,
Author