Fix `foreach` non-progation of errors

Also add `error/0` builtin.
Add BLOCK_8() macro
Add Streaming parser (--stream)

Streaming means that outputs are produced as soon as possible.  With the
`foreach` syntax one can write programs which reduce portions of the
streaming parse of a large input (reduce into proper JSON values, for
example), and discard the rest, processing incrementally.  We should add
an exit builtin (or use `break` or `error`) and processing can even
terminate early.

This:

    $ jq -c --stream .

should produce the same output as this:

    $ jq -c '. as $dot | path(..) as $p | $dot | getpath($p) | [$p,.]'

The output of `jq --stream .` should be `[[<path>],<leaf>]`.  To prevent
ambiguities, the start of any array and object yields a path with a -1
or null (respectively) for the last component of the path, and no leaf.

Hmmm: The -1/null thing is a bit bogus.  Instead we should return empty
arrays and objects as leaves!

For example, a truncated input produces a path as soon as possible, then
later the error:

    $ printf '[0,\n'|./jq -c --stream .
    [[-1]]
    parse error: Unfinished JSON term
    $

Here's an example without that error:

    $ ./jq -c --stream .
      0 [1] [2,3] [4,[5,[6,7]]]
      [[],0]
      [[-1]]
      [[0],1]
      [[-1]]
      [[0],2]
      [[1],3]
      [[-1]]
      [[0],4]
      [[1,-1]]
      [[1,0],5]
      [[1,1,-1]]
      [[1,1,0],6]
      [[1,1,1],7]
    $

Anyways, a work in progress.

Testing will involve torture JSON inputs, and their hand-coded streamed
equivalents for comparison.

Fix streaming bugs and add tests
WIP: Always stream object/array endings

It turns out that we must always do this to avoid ambiguities.  But it's
tricky because we need to output two things in a case like `[0]`: one is
the path (`[0]`) and the leaf (`0`), and the other is the fact that this
is the end of that array.

To make it easier on the parser we output a third value, `true`, when
the path and leaf are at the end of an array/object.

To make things even weirder, we output `[<path>]` when an array/object
ends after another (e.g., `[[1]]` produces `[[0,0],1,true]` then
`[[0]]`).  That's a bit weird, but hey.

So we have three(!) output forms when streaming:

    [<path>, <leaf>]
    [<path>, <leaf>, true]
    [<path>]

That's rather strange.  Reducers will need the last two to decide when
to output something.

We should simplify this down to:

    [<path>, <leaf>]
    [<path>]