On Wed, Jan 07, 2004 at 10:40:30AM -0800, Paul Eggert wrote: > 5) Dynamically test whether $LINENO is working inside shell functions, > and prepend the function name to $LINENO if the bug is present. A variant of this: always prepend the function name ("main" or something if in the mainline). Besides helping with the relative-LINENO thing, that: - is generally useful, as it is in compiler error messages to have both function name and (file-relative) line number - ensures that the message prologue always has the same format, whether or not the message came from a function, and whether or not the script is running in a broken shell Then mention in the docs that the line number is function-relative on older shells. -- | | /\ |-_|/ > Eric Siegerman, Toronto, Ont. erics@xxxxxxxxxxxx | | / It must be said that they would have sounded better if the singer wouldn't throw his fellow band members to the ground and toss the drum kit around during songs. - Patrick Lenneau