01mf02 / jaq

A jq clone focussed on correctness, speed, and simplicity

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Passing a value from stdin to jaq without cli args panics

tranzystorekk opened this issue · comments

Tested on jaq 1.2.0:

RUST_BACKTRACE=1 jaq <<< '"foo"'
thread 'main' panicked at jaq-interpret/src/filter.rs:227:16:
index out of bounds: the len is 0 but the index is 0
stack backtrace:
   0: rust_begin_unwind
   1: core::panicking::panic_fmt
   2: core::panicking::panic_bounds_check
   3: <jaq_interpret::filter::Ref as jaq_interpret::filter::FilterT>::run
   4: <&jaq_interpret::filter::Owned as jaq_interpret::filter::FilterT>::run
   5: jaq::real_main
   6: jaq::main
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

Sorry, found out this is a duplicate of #146 which is fixed on main.