It looks like some objects could cause stack overflows here:

```js
var x = {};
x.x = x;
storage.x = x;
```

Would be nice if `wrapValue` would throw exceptions in such scenarios, probably by keeping temporary stack while traversing object.