mirror of
https://github.com/stedolan/jq.git
synced 2024-05-11 05:55:39 +00:00
chore: Improve readability (for Alternative operator '//')
The description of the Alternative operator `//` was hard for me to grasp in its wording. I suggest dividing the looong sentence into two parts. Since it is actually an alternative formulation, the sentence can be divided into the first formulation, and the alternative formulation.
This commit is contained in:
committed by
GitHub
parent
7e54d9646e
commit
2ccab044fe
@@ -2404,7 +2404,7 @@ sections:
|
||||
body: |
|
||||
|
||||
The `//` operator produces all the values of its left-hand
|
||||
side that are neither `false` nor `null`, or, if the
|
||||
side that are neither `false` nor `null`. If the
|
||||
left-hand side produces no values other than `false` or
|
||||
`null`, then `//` produces all the values of its right-hand
|
||||
side.
|
||||
|
||||
4
jq.1.prebuilt
generated
4
jq.1.prebuilt
generated
@@ -1,5 +1,5 @@
|
||||
.
|
||||
.TH "JQ" "1" "November 2023" "" ""
|
||||
.TH "JQ" "1" "December 2023" "" ""
|
||||
.
|
||||
.SH "NAME"
|
||||
\fBjq\fR \- Command\-line JSON processor
|
||||
@@ -2586,7 +2586,7 @@ jq \'[true, false | not]\'
|
||||
.IP "" 0
|
||||
.
|
||||
.SS "Alternative operator: //"
|
||||
The \fB//\fR operator produces all the values of its left\-hand side that are neither \fBfalse\fR nor \fBnull\fR, or, if the left\-hand side produces no values other than \fBfalse\fR or \fBnull\fR, then \fB//\fR produces all the values of its right\-hand side\.
|
||||
The \fB//\fR operator produces all the values of its left\-hand side that are neither \fBfalse\fR nor \fBnull\fR\. If the left\-hand side produces no values other than \fBfalse\fR or \fBnull\fR, then \fB//\fR produces all the values of its right\-hand side\.
|
||||
.
|
||||
.P
|
||||
A filter of the form \fBa // b\fR produces all the results of \fBa\fR that are not \fBfalse\fR or \fBnull\fR\. If \fBa\fR produces no results, or no results other than \fBfalse\fR or \fBnull\fR, then \fBa // b\fR produces the results of \fBb\fR\.
|
||||
|
||||
Reference in New Issue
Block a user