summaryrefslogtreecommitdiff
path: root/awkgram.y
diff options
context:
space:
mode:
authorArnold D. Robbins <arnold@skeeve.com>2019-05-22 20:59:05 +0300
committerArnold D. Robbins <arnold@skeeve.com>2019-05-22 20:59:05 +0300
commit875f2de7fd309eed6096e2f51415aa3ea3666f27 (patch)
tree9b0b073f5f522c560fbb4538a8d8d891f74ca903 /awkgram.y
parent990649951e7fa34ae589a19ac686ffcc655d584b (diff)
downloadgawk-875f2de7fd309eed6096e2f51415aa3ea3666f27.tar.gz
Add --lint=no-ext to disable "xxx is a gawk extension" warnings.
Diffstat (limited to 'awkgram.y')
-rw-r--r--awkgram.y6
1 files changed, 3 insertions, 3 deletions
diff --git a/awkgram.y b/awkgram.y
index 08bd096e..3cbcfd31 100644
--- a/awkgram.y
+++ b/awkgram.y
@@ -4379,7 +4379,7 @@ retry:
}
if (do_lint) {
- if ((tokentab[mid].flags & GAWKX) != 0 && (warntab[mid] & GAWKX) == 0) {
+ if (do_lint_extensions && (tokentab[mid].flags & GAWKX) != 0 && (warntab[mid] & GAWKX) == 0) {
lintwarn(_("`%s' is a gawk extension"),
tokentab[mid].operator);
warntab[mid] |= GAWKX;
@@ -4702,7 +4702,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
(void) mk_rexp(arg);
if (nexp == 3) { /* 3rd argument there */
- if (do_lint && ! warned) {
+ if (do_lint_extensions && ! warned) {
warned = true;
lintwarn(_("match: third argument is a gawk extension"));
}
@@ -4759,7 +4759,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
} else if (r->builtin == do_close) {
static bool warned = false;
if (nexp == 2) {
- if (do_lint && ! warned) {
+ if (do_lint_extensions && ! warned) {
warned = true;
lintwarn(_("close: second argument is a gawk extension"));
}