summaryrefslogtreecommitdiff
diff options
authorArnold D. Robbins <[email protected]>2025-10-25 20:29:53 +0300
committerArnold D. Robbins <[email protected]>2025-10-25 20:29:53 +0300
commita52a2aca56574dafc2cb1edadb92982a9366a060 (patch)
tree1311e746087feedad6d0e0ed0ee7824d27567f75
parent4ed4edfe04512c5b2a2c08ff7c4ce43b5593e7a4 (diff)
downloadgawk-master.tar.gz
Fix some lint checks and messages.HEADmaster
-rw-r--r--ChangeLog7
-rw-r--r--field.c6
-rw-r--r--io.c2
3 files changed, 11 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 5754e0e3..e52c35e6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2025-10-25 Arnold D. Robbins <[email protected]>
+
+ * field.c (do_split, do_patsplit): Use do_lint_extensions before
+ warning about extensions.
+ (set_FPAT): Clean up a lint warning.
+ * io.c (set_RS): Ditto.
+
2025-10-23 Arnold D. Robbins <[email protected]>
* field.c (do_split): If someone passed a Node_elem_new
diff --git a/field.c b/field.c
index 42d07b48..9a6b5b96 100644
--- a/field.c
+++ b/field.c
@@ -1152,7 +1152,7 @@ do_split(int nargs)
// Someone passed an array element to be turned into
// a subarray, so let's warn about it.
static bool warned = false;
- if (do_lint && ! warned && arr->parent_array != NULL) {
+ if (do_lint_extensions && ! warned && arr->parent_array != NULL) {
warned = true;
lintwarn(_("multidimensional arrays are a gawk extension"));
}
@@ -1257,7 +1257,7 @@ do_patsplit(int nargs)
// Someone passed an array element to be turned into
// a subarray, so let's warn about it.
static bool warned = false;
- if (do_lint && ! warned && arr->parent_array != NULL) {
+ if (do_lint_extensions && ! warned && arr->parent_array != NULL) {
warned = true;
lintwarn(_("multidimensional arrays are a gawk extension"));
}
@@ -1654,7 +1654,7 @@ set_FPAT()
if (do_lint_extensions && ! warned) {
warned = true;
- lintwarn(_("`FPAT' is a gawk extension"));
+ lintwarn(_("FPAT is a gawk extension"));
}
if (do_traditional) /* quick and dirty, does the trick */
return;
diff --git a/io.c b/io.c
index 1372ebf5..321c2719 100644
--- a/io.c
+++ b/io.c
@@ -4212,7 +4212,7 @@ set_RS()
matchrec = rsrescan;
if (do_lint_extensions && ! warned) {
- lintwarn(_("multicharacter value of `RS' is a gawk extension"));
+ lintwarn(_("multicharacter value of RS is a gawk extension"));
warned = true;
}
} else {