Skip to content
Myr

builtin.jq: def pick(pathexps):

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Change the name of the formal parameter.

authored by pkoppstein · committed by Nico Williams · parent 416e8ad · Browse files · 1 file+3 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+3 added−3 removed

  • other:+3 added−3 removed

1 file+3 added−3 removed

modified:src/builtin.jq+3 added-3 removed
258 unmodified lines
259 elif type == "array" then map( walk(f) ) | f260 else f261 end;262263# stream should be a stream of dot-paths264def pick(stream):263# pathexps could be a stream of dot-paths264def pick(pathexps):265 . as $in266 | reduce path(stream) as $a (null;266 | reduce path(pathexps) as $a (null;267 setpath($a; $in|getpath($a)) );268269# SQL-ish operators here:270def INDEX(stream; idx_expr):
10 unmodified lines