Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Redefining TRAPDEBUG causes loop?
- X-seq: zsh-workers 49375
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: Zsh hackers list <zsh-workers@xxxxxxx>
- Subject: Redefining TRAPDEBUG causes loop?
- Date: Sat, 4 Sep 2021 20:07:11 -0700
- Archived-at: <https://zsh.org/workers/49375>
- List-id: <zsh-workers.zsh.org>
I haven't worked out a simple test case yet, but several times while
playing with Zach Riggle's question about ZSH_DEBUG_CMD, I managed to
put the shell into an infinite loop by redefining TRAPDEBUG() { ... }
at the command line without first doing unfunction TRAPDEBUG.
This probably requires making a reference to $ZSH_DEBUG_CMD in the
function body (and therefore requires DEBUG_BEFORE_CMD) but I'm not
certain.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author