Emanuele Torre

Results 211 comments of Emanuele Torre
trafficstars

`src/lexer.l` is the jq lexer; not the json lexer

jq 1.6 is an old version; I tried your example and I get a parse error: ```console $ printf '1\r\x00\n\x00\n1\n\x00 \x00' | jq 1 jq: parse error: Invalid numeric literal...

> Meanwhile, `\x22\x00\x22` (" ") reports the following error, which appears to suggest that null bytes in general should not be allowed: > > > parse error: Unfinished string at...

But the parser does seem to get confused by NUL when it is used as whitespace in the input: ```console $ printf '1\0 2 ' | jq # stops parsing...

I don't see the point in restring that; `jq -n ... '$ARGS.named'` is a fairly common pattern to construct objects from some shell variables; e.g. ```sh jq -n \ --arg...

Also those functions have `0` arguments (just the input), not `1`. The error messages should say `/0`, not `/1`.

@wader Well, I checked my 2023-08-29 chat logs with @nicowilliams and that issue was about the following `jq` script (that is supposed to delete duplicate elements in the input array...

Hmm, I am closing this PR since it seems the patch does not solve any issue, and otherwise it does not accomplish anything useful.