rev 727 - trunk/src
SVN User <[email protected]> Mon, 12 Jul 2004 23:27:27 -0400
| Newsgroups | gmane.comp.lang.prothon.cvs |
|---|---|
| Message-ID | <[email protected]> |
Author: mark
Date: 2004-07-12 23:27:24 -0400 (Mon, 12 Jul 2004)
New Revision: 727
Modified:
trunk/src/argproc.c
trunk/src/interp.c
trunk/src/interp.h
trunk/src/parser_routines.c
Log:
added -d@ command line switch, removed unimplmented command line help
Modified: trunk/src/argproc.c
===================================================================
--- trunk/src/argproc.c 2004-07-13 01:52:29 UTC (rev 726)
+++ trunk/src/argproc.c 2004-07-13 03:27:24 UTC (rev 727)
@@ -119,6 +119,7 @@
case 'c': trace_interpreter = 1; break;
case 'o': dump_objects_at_end = 1; break;
case 'G': disable_mem_mgr = 1; break;
+ case '@': allow_at_sign_debug = 1; break;
}
break;
case 'm':
@@ -164,18 +165,6 @@
printf("\n");
printf(" - options:\n");
printf("\n");
- printf(" -m --maxmem mem-size-in-megs\n");
- printf(" (Not implemented yet)\n");
- printf(" Maximum memory usage desired. Garbage collector thread runs \n");
- printf(" in high priority when memory reaches this level. Memory value\n");
- printf(" is a number indicating megabytes.\n");
- printf("\n");
- printf(" -l --lowmem mem-size-in-megs\n");
- printf(" (Not implemented yet)\n");
- printf(" Memory usage defined as low. Garbage collector runs at low priority\n");
- printf(" (effectively off) when memory usage is below this level. Allows \n");
- printf(" maximum speed for app. Memory value is a number indicating megabytes.\n");
- printf("\n");
printf(" -t --thread filename\n");
printf(" filename.pr will run as a seperate thread simultaneously with any other\n");
printf(" Prothon code. More than one of these options may be specified in one\n");
@@ -219,6 +208,7 @@
printf(" g: Garbage collector status messages\n");
#endif
printf(" G: Disable garbage collector\n");
+ printf(" @: Allow @ debug print symbol\n");
printf("\n");
#endif
printf(" -V -- version\n");
Modified: trunk/src/interp.c
===================================================================
--- trunk/src/interp.c 2004-07-13 01:52:29 UTC (rev 726)
+++ trunk/src/interp.c 2004-07-13 03:27:24 UTC (rev 727)
@@ -76,6 +76,7 @@
int trace_interpreter = 0;
int dump_objects_at_end = 0;
int disable_mem_mgr = 0;
+int allow_at_sign_debug = 0;
static FILE* tfout=NULL;
Modified: trunk/src/interp.h
===================================================================
--- trunk/src/interp.h 2004-07-13 01:52:29 UTC (rev 726)
+++ trunk/src/interp.h 2004-07-13 03:27:24 UTC (rev 727)
@@ -68,6 +68,7 @@
extern int trace_interpreter;
extern int dump_objects_at_end;
extern int disable_mem_mgr;
+extern int allow_at_sign_debug;
extern i32_t main_threads_started;
extern i32_t main_threads_running;
Modified: trunk/src/parser_routines.c
===================================================================
--- trunk/src/parser_routines.c 2004-07-13 01:52:29 UTC (rev 726)
+++ trunk/src/parser_routines.c 2004-07-13 03:27:24 UTC (rev 727)
@@ -293,6 +293,10 @@
int i, llen = clist_len(parm->src_objs);
obj_p str_obj;
char buf[256], *dst, *end = buf+255;
+ if (!allow_at_sign_debug) {
+ printf("Parser error, at-sign @ debug print only allowed when -d@ command-line argument used\n");
+ pr_exit(1);
+ }
apr_snprintf(buf, sizeof(buf), "@debug file %s, line ", parm->file_path);
dst = buf + strlen(buf);
for (i=0; i < llen; i++) {