cth.js: define `print` for node, cscript

use cth (console test harness) to define functions
for console runner.  V8, Spidermonkey (js) and JavaScriptCore (jsc)
provide a function `print`.  Provide a default `print` for node
and cscript
sta.js: make $ERROR a var so it's overridable

make $ERROR a var
set $ERROR to function $ERROR so it can be overridden if
needed
set print_handle to 'print' by default (can still override)
for cscript: wrap tests in try/catch so we get syntax errors