Silence a warning from the test harness for unthreaded builds.

"The variable THREADS is defined but never used.", so, in WITH-TEST only
bind THREADS under #+SB-THREAD as all places where this variable is used
are guarded by this feature expression, too.
Improve the failure output of the test :range-reduction :x87.

Namely, output the function, argument, expected and actual result.
Prevent a make-array transform from modifying source forms.

That causes repeated compilations of inlined functions to accumulate
changes made by the transform.

Thanks to Bart Botta.
(regression since 1.0.42.11-bis)
Fix a test-case in threads.impure.lisp on -sb-thread.

A test was using make-thread without ensuring that sb-thread is enabled.

Fixes lp#1141795
New keyword argument for SB-C:DEFKNOWN: :overwrite-fndb-silently

 While not useful in the compiler itself, some libraries (not only
 contribs) define their own VOPs, transforms, etc., and the error
 when clobbering pre-existing defknowns made these libraries hard
 to reload.

 Use with :allow-other-keys for backward compatibility.
clear-output: call stream-clear-output on gray streams.

clear-output should call sb-gray:stream-clear-output instead of
sb-gray:stream-force-output.

Fixes lp#1153257.
format: Signal an error for ~<~@>

CLHS doesn't allow @ to appear in the closing directive of ~<~>.

Patch by Jan Moringen.
Fixes lp#1153148
Slightly better arglist for defmethod.

(defmethod name &rest args) instead of just (defmethod &rest args).
Better errors for package operations.

Add some missing errors, make other errors to be of type
sb-kernel:simple-package-error.

Fixes lp#1154776.

DELETE-PACKAGE should be signalling a continuable error, but wasn't
since 1.0.37.44.
Accessing &MORE arguments checks bounds.

(funcall (lambda (&rest args) (car args))) => garbage,
because &more accessing didn't check bounds.

Fixes lp#1154946.
Optimize CAD*R for &MORE args.

Call %rest-ref when possible, and SECOND-FOURTH are optimized by
extension too.
Reduce consing for find-package.

Don't use return-from inside restart-case, it causes consing even when
the branch with restart-case is not taken.
Optimize pprinting of heavily nested lists.

Declare types of PREFIX and SUFFIX slots of PRETTY-STREAM to be
(simple-array character (*)), not just simple-string.
make-array transform error on unknown element-type.

Check for the type to be known, otherwise give up transforming.
Based on a patch by James Kalenius.
Fixes lp#1156095.
faster SVREF and (SETF SVREF) compilation
micro-optimize sane-package a tiny bit more
Fix SEQUENCE:SEARCH, test seq. functions with user-defined sequences

Extending the tests in tests/seq.impure.lisp to user-defined sequences
revealed that the previous implementation produced incorrect results
for some inputs.

SEQUENCE:WITH-SEQUENCE-ITERATOR now accepts NIL in the list of
variables and generates ignored bindings for these elements.

The new implementation is also slightly faster (at least for the
inputs in tests/seq.impure.lisp).

fixes lp#1153312
minor NEWS fixups
Fix typo in comment in src/compiler/seqtran.lisp
Remove redundant LENGTH calls in NSUBSTITUTE[-IF[-NOT]]

NSUBSTITUTE, NSUBSTITUTE-IF and NSUBSTITUTE-IF used to contain

  (let ((length (length sequence))) ...

in the code path for lists. In the macroexpansion it became clear that
this recomputed and shadowed the LENGTH variables already established
by DEFINE-SEQUENCE-TRAVERSER.

A very brief test with list lengths between 5 and 500 suggests that
the speedup produced by removing the redundant computation can be
around 5 to 20 %.