aboutsummaryrefslogtreecommitdiffstats
path: root/main.c
diff options
context:
space:
mode:
authorArnold D. Robbins <arnold@skeeve.com>2020-07-03 11:16:36 +0300
committerArnold D. Robbins <arnold@skeeve.com>2020-07-03 11:16:36 +0300
commit30a60fc794e84da90fed6871ff27d668fe4a391e (patch)
treea6294c9607f4964212c10daa3b1dde3501bf4d86 /main.c
parentc997a0e5d3857eb48e4292f0b42da9b3bbb985fb (diff)
parentf60ced696bc752cdc1a1f45ce2cc9d6149be7087 (diff)
downloadegawk-30a60fc794e84da90fed6871ff27d668fe4a391e.tar.gz
egawk-30a60fc794e84da90fed6871ff27d668fe4a391e.tar.bz2
egawk-30a60fc794e84da90fed6871ff27d668fe4a391e.zip
Merge branch 'gawk-5.1-stable'
Diffstat (limited to 'main.c')
-rw-r--r--main.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/main.c b/main.c
index 4f239dfc..b09b5f4c 100644
--- a/main.c
+++ b/main.c
@@ -205,6 +205,7 @@ static const struct option optab[] = {
{ "re-interval", no_argument, NULL, 'r' },
{ "sandbox", no_argument, NULL, 'S' },
{ "source", required_argument, NULL, 'e' },
+ { "trace", no_argument, NULL, 'I' },
{ "traditional", no_argument, NULL, 'c' },
{ "use-lc-numeric", no_argument, & use_lc_numeric, 1 },
{ "version", no_argument, & do_version, 'V' },
@@ -601,6 +602,7 @@ usage(int exitval, FILE *fp)
fputs(_("\t-g\t\t\t--gen-pot\n"), fp);
fputs(_("\t-h\t\t\t--help\n"), fp);
fputs(_("\t-i includefile\t\t--include=includefile\n"), fp);
+ fputs(_("\t-I\t\t\t--trace\n"), fp);
fputs(_("\t-l library\t\t--load=library\n"), fp);
/*
* TRANSLATORS: the "fatal", "invalid" and "no-ext" here are literal
@@ -1519,7 +1521,7 @@ parse_args(int argc, char **argv)
/*
* The + on the front tells GNU getopt not to rearrange argv.
*/
- const char *optlist = "+F:f:v:W;bcCd::D::e:E:ghi:l:L::nNo::Op::MPrSstVYZ:";
+ const char *optlist = "+F:f:v:W;bcCd::D::e:E:ghi:Il:L::nNo::Op::MPrSstVYZ:";
int old_optind;
int c;
char *scan;
@@ -1614,6 +1616,10 @@ parse_args(int argc, char **argv)
(void) add_srcfile(SRC_INC, optarg, srcfiles, NULL, NULL);
break;
+ case 'I':
+ do_flags |= DO_ITRACE;
+ break;
+
case 'l':
(void) add_srcfile(SRC_EXTLIB, optarg, srcfiles, NULL, NULL);
break;