rev 704 - trunk/src

SVN User <[email protected]> Sun, 04 Jul 2004 20:20:10 -0400
Newsgroups gmane.comp.lang.prothon.cvs
Message-ID <[email protected]>
Author: mark
Date: 2004-07-04 20:20:07 -0400 (Sun, 04 Jul 2004)
New Revision: 704

Modified:
   trunk/src/console.c
   trunk/src/interp.c
   trunk/src/interp.h
Log:
put in as_str_stack reset on every console execution

Modified: trunk/src/console.c
===================================================================
--- trunk/src/console.c	2004-07-05 00:14:40 UTC (rev 703)
+++ trunk/src/console.c	2004-07-05 00:20:07 UTC (rev 704)
@@ -232,6 +232,7 @@
 			}
 			colon_flg = (strlen(line) >= 2 && line[strlen(line)-2] == ':');
 		}
+		reset_as_str_stack(ist);
 		res = exec_string(ist, src, TRUE, &frame);
 		if (check_exceptions(ist)) {
 			ist->frame = NULL;

Modified: trunk/src/interp.c
===================================================================
--- trunk/src/interp.c	2004-07-05 00:14:40 UTC (rev 703)
+++ trunk/src/interp.c	2004-07-05 00:20:07 UTC (rev 704)
@@ -90,6 +90,11 @@
 	return ist;
 }
 
+void reset_as_str_stack(isp ist) {
+	pr_free(ist->as_str_stack);
+	ist->as_str_stack = new_clist(20);
+}
+
 void trace_step(frame_p frame) {
 	int i;
 	if (!tfout) tfout = fopen("!code_trace.txt", "w");

Modified: trunk/src/interp.h
===================================================================
--- trunk/src/interp.h	2004-07-05 00:14:40 UTC (rev 703)
+++ trunk/src/interp.h	2004-07-05 00:20:07 UTC (rev 704)
@@ -139,6 +139,7 @@
 
 
 obj_p new_parmptr_obj(isp ist, int ofs);
+void reset_as_str_stack(isp ist);
 
 #define fr_next			(frame->next_frame)
 #define fr_prev			(frame->prev_frame)