[tnum] skip leading whitespace on conversion from strings to numbers. Also return 0 on empty string
[js] improve casting of objects and nulls to numbers
[js] add global isNaN() function
[js] test isNaN()