Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rutgers!hal9000!root From: ken@rochester.ARPA (Ken Yap) Newsgroups: comp.lang.fortran Subject: Re: Can a subroutine find the name of the calling routine? Message-ID: <1110@hal9000.UUCP> Date: Mon, 4-May-87 14:38:09 EDT Article-I.D.: hal9000.1110 Posted: Mon May 4 14:38:09 1987 Date-Received: Tue, 5-May-87 03:24:45 EDT Sender: root@hal9000.UUCP Lines: 18 If you want to do this just for the purposes of tracing calls and you don't want to go around mucking with machine dependent stacks, you could do it with a preprocessor that inserts two extra arguments in front of every call. call foobar(1, 3.0, 4.0) becomes call foobar('parent', 3, 1, 3.0, 4.0) and the subroutine declaration has to be changed too, of course. Of course, don't do this to library routines or intrinsics. I don't have any idea how much work this is. Have fun. Ken