--- freem/src/xecline.c 2025/04/30 14:41:03 1.19 +++ freem/src/xecline.c 2025/05/01 17:02:30 1.21 @@ -1,5 +1,5 @@ /* - * $Id: xecline.c,v 1.19 2025/04/30 14:41:03 snw Exp $ + * $Id: xecline.c,v 1.21 2025/05/01 17:02:30 snw Exp $ * freem interpreter proper * * @@ -24,6 +24,12 @@ * along with FreeM. If not, see . * * $Log: xecline.c,v $ + * Revision 1.21 2025/05/01 17:02:30 snw + * Further debugging improvements + * + * Revision 1.20 2025/04/30 17:19:16 snw + * Improve backtraces in debugger + * * Revision 1.19 2025/04/30 14:41:03 snw * Further debugger work * @@ -174,7 +180,6 @@ int xecline(int typ) short new_and_set = FALSE; short new_object = FALSE; short destructor_run = FALSE; - short debug_mode = FALSE; short libcall = FALSE; char *namold; long rouoldc; @@ -197,6 +202,7 @@ int xecline(int typ) char *reeval_codptr; char reeval_code[512]; + char entryref[256]; int i; int j; @@ -247,7 +253,7 @@ int xecline(int typ) next_line: /* entry point for next command line */ if (debug_mode) { - debug_mode = debugger (DEBENTRY_LINE, codptr); + debug_mode = debugger (DEBENTRY_LINE, entryref); } job_set_status (pid, JSTAT_INTERPRETER); @@ -297,8 +303,9 @@ next_line: /* entry point for n codptr = code; next_cmnd: /* continue line entry point */ + getraddress (entryref, nstx); if (debug_mode) { - debug_mode = debugger (DEBENTRY_CMD, codptr); + debug_mode = debugger (DEBENTRY_CMD, entryref); } if (sigint_in_for) goto for_quit; @@ -6802,14 +6809,6 @@ err: stcpy (er_buf, errmes[merr ()]); stcnv_m2c (er_buf); - - /* - if (usermode == 1 && ztrap[nstx][0] == EOL && etrap[0] == '\0') { - debug_mode = TRUE; - debugger (DEBENTRY_ERROR, codptr); - } - */ - #if !defined(MSDOS) logprintf (FM_LOG_DEBUG, "xecline: interpreter error %d [%s]", ierr, er_buf);