Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: pws-22: killing the ZSH loops problem



On Jun 21, 11:08am, Andrej Borsenkow wrote:
} Subject: RE: pws-22: killing the ZSH loops problem
}
} > } We need it only if MONITOR is set
} >
} > Not true!  MONITOR only affects handling of ^Z, not of ^C.  We need to be
} > able to properly interrupt such loops in any shell.
} 
} Ahem ... yes. What about "only in interactive shells?"

What about "kill -INT"?  What about a shell script that isn't interactive
but that's running in the foreground?

} If don't miss something again: we have to fork only for the loop as whole.

That's right, but the reason we don't do this now is so that parameter
assignments inside the loop are visible after the loop terminates.  That
doesn't work in most other shells.

} ... so, it seems, execution time penalty is acceptable.  After all, you
} don't use loops on every prompt.

The execution time isn't as much at issue as is the process table space.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com



Messages sorted by: Reverse Date, Date, Thread, Author