This is not a very accorate IsObject test. I think we have something better in runtime/util.js