diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2011-04-24 12:45:47 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2011-04-24 12:45:47 +0300 |
commit | 8eb45b02e704c95866970005fe771e3507fb935c (patch) | |
tree | ffe48f1a5f46e15e6df6b7c509a592f7f9300f3f /doc/gawk.1 | |
parent | 203dfc888be3f45d3f70c9cdb91e870ae7796257 (diff) | |
download | egawk-8eb45b02e704c95866970005fe771e3507fb935c.tar.gz egawk-8eb45b02e704c95866970005fe771e3507fb935c.tar.bz2 egawk-8eb45b02e704c95866970005fe771e3507fb935c.zip |
Patch from John, update man page.
Diffstat (limited to 'doc/gawk.1')
-rw-r--r-- | doc/gawk.1 | 22 |
1 files changed, 22 insertions, 0 deletions
@@ -1098,6 +1098,25 @@ Supported values are \fB"unsorted"\fR. The order specification words can be truncated, or omitted (provided that at least one is present), or given in any order. +The value can also be the name of any comparison function defined +as follows: +.PP +.RS +\fBfunction cmp_func(i1, v1, i2, v2)\fR +.RE +.PP +where +.I i1 +and +.I i2 +are the indices, and +.I v1 +and +.I v2 +are the +corresponding values of the two elements being compared. +It should return a number less than, equal to, or greater than 0, +depending on how the elements of the array are to be ordered. .TP \fBPROCINFO["version"]\fP the version of @@ -2475,6 +2494,9 @@ Valid values for .I how are "ascending string", "ascending number", "descending string" and "descending number". +It can also be the name of a user-defined +comparison function as described in +\fBPROCINFO["sorted_in"]\fR. .TP "\w'\fBsprintf(\^\fIfmt\fB\^, \fIexpr-list\^\fB)\fR'u+1n" \fBasorti(\fIs \fR[\fB, \fId\fR [\fB, \fIhow\fR] ]\fB)\fR Return the number of elements in the source |