Silverfrost Forums

Welcome to our forums

Error handling

14 Apr 2009 3:32 #4413

We have an existing application in FTN77 that throws errors when it calls a subroutine that takes the square root of -1. When this is encountered it goes into the debugger and shows the call stack going back to the highest level subroutine. We run the program by using RUN77 and it is not complied in debug mode.

I am trying to do something similiar in FTN95, my only problem is that without compiling in debug mode I do not get a call stack of subroutines called.

How can I do the same thing in FTN95?

Thanks.

Michael

14 Apr 2009 6:09 #4414

Just to clarify, are you asking for a trace back on runtime failure without using /debug as a compiler option?

If you do not want to slow things down by using /debug everywhere you could consider using it in parts of the code.

14 Apr 2009 6:20 #4415

Yes I would like to have trace back without compiling in debug.

15 Apr 2009 4:39 #4418

Do you not get the exception box with the stack trace?


-- Admin Silverfrost Limited
15 Apr 2009 5:02 #4420

Check to see that you are not linking with the 'notrace' option!

16 Apr 2009 12:19 #4424

I have to compile in debug or checkmate to get a trace that shows line numbers and names of routines. If I compile without that I just get the name of the lowest level routine where the error occured and some hex code values.

19 Apr 2009 7:37 #4427

Michael,

For the reason you have found, of getting a useful error message, I mostly compile with /debug. There is little overhead in run time performance with /debug, although /check has a considerable, but in most cases acceptable overhead. The first run is usually with /check. I only use /opt for mature code where performance is important.

John

20 Apr 2009 9:41 #4431

You must either use /DEBUG to get the line numbers or you can interprete the hex values in square brackets as assembly code address offsets by compiling your code using /EXPLIST.

Please login to reply.