From 1b1c1c570b65c2d218faef7eb6ebb7f0fb3786a6 Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Sun, 14 Oct 2018 21:10:06 -0700 Subject: doc: shorten some POSIX awk examples. * txr.1: Remove unnecessary test for the existence of a field, since the find function accepts nil. Use len instead of length. --- txr.1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/txr.1 b/txr.1 index f349b4a5..9595fff2 100644 --- a/txr.1 +++ b/txr.1 @@ -49741,7 +49741,7 @@ while the fourth one doesn't: Print lines containing a backslash in the second field: .cblk - (awk ((and [f 1] (find #\e\e [f 1])))) + (awk ((find #\e\e [f 1]))) .cble .IP 7. Print lines containing a backslash using a regex constructed @@ -49785,7 +49785,7 @@ by producing a single string first: Print lines longer than 72 characters: .cblk - (awk ((> (length rec) 72))) + (awk ((> (len rec) 72))) .cble .IP 11. Print first two fields in reverse order, separated by -- cgit v1.2.3