This is 50x slower than using typeof. http://jsperf.com/typeof-function-vs-instanceof/6

Use typeof. Ditto for isNumber.