Fixes several bugs related to APPLY and COND.  Adds "primes" and "queens"
benchmarks to scripts/bench, to be run by default.

In general, this change improves QOR (fewer crashes), but adds quite a bit of
overhead.  Performance will need to be revisited.  There remains a bug in gc
mode that leads to SEGVs for primes and queens (perhaps related to partial
application)?

Changes include the following:

  - Adds a new library "functional".
  - Introduces the "apply" built-in.  With that, partial application works even
    when the first successor is an operation that returns a partial
    application.
  - Removes the use of APPLY throughout, except by the apply built-in.
  - Changes handling of conditionals (COND macro and sprite::cond).  Now the
    inductive position is saved and restored.  Also, the operation "test" is
    applied to the test expression to force it to be a Boolean.
  - Fixes bugs in the bool library that led to compile failures.

Running on yellow-eyed.
------ Config refcnt-opt ------
reverse              0:01.30
tak                  0:00.81
rfib                 0:00.19
exp3_8               0:00.20
tree_insert          0:00.55
tree_insert_32       0:00.54
primes               0:01.86
queens               0:00.41
------ Config gc-opt ------
reverse              0:00.71
tak                  0:00.75
rfib                 0:00.15
exp3_8               0:00.10
tree_insert          0:00.74
tree_insert_32       0:00.74
primes               Command terminated by signal 11
0:00.08
queens               Command terminated by signal 11
0:00.08