You use the function caller (see Perl Programming chapter 22) and use 0 for current stack, 1 for the caller, 2 for caller's caller, etc.
To see who I am, caller(0). To see who called me, caller(1). Wags ;) -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 16, 2002 11:15 To: [EMAIL PROTECTED] Subject: determine the invoking function Hello, is it possible to determine within a function from which module/function this one was called? for instance: sub test1 { test2(); } sub test2 { .... you were called from function test1. } thanks in advance, Christian -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]