diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2018-07-27 11:47:47 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2018-07-27 11:47:47 +0300 |
commit | 30e8a37825c9b9e67c0cf440f7617508b7898c2b (patch) | |
tree | 81df2faabd09de798f93c73b07a0e961f4674e5e /test/lintwarn.awk | |
parent | 3ddc932b0a808a4f5f55519ccf1d65f6caa41666 (diff) | |
download | egawk-30e8a37825c9b9e67c0cf440f7617508b7898c2b.tar.gz egawk-30e8a37825c9b9e67c0cf440f7617508b7898c2b.tar.bz2 egawk-30e8a37825c9b9e67c0cf440f7617508b7898c2b.zip |
Add lint warning for `print "foo" > "foo" 1'.
Diffstat (limited to 'test/lintwarn.awk')
-rw-r--r-- | test/lintwarn.awk | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/lintwarn.awk b/test/lintwarn.awk index cea76bbc..d430a2b4 100644 --- a/test/lintwarn.awk +++ b/test/lintwarn.awk @@ -36,3 +36,8 @@ function zz(aa, aa) return aa } @include "" +BEGIN { + print "foo" > "foo" 1 # should warn + print "foo" > ("foo" 1) # should not warn + system("rm -f foo1 foo2") +} |