Fixes #23 - Fix exceptions accessing undefined properties or properties of null/undefined values.

Compare with null because `x == null` is always `false` unless x is `null` or `undefined`. For values that require extra numeric formatting (memory, rounding etc.) there is an extra `isNaN` check.