de-allocating memory used by a object literal in js
<p>I'm aware that js has garbage collection that frees up memory that are no longer referenced, but I'm curious as to wether the G.C. works on objects that reference them selves like this:</p>

<pre><code>var x = {
  b:function(){
    alert('hello');
  },
  y:function(){ //init listeners
    $(some-dom-el).click(function(){
       x.b();
    });
  },
  z:function(){
    var ex = this.r(55,9000);
  },
  r:function(a,b){
    return a + b;
  }
}

$(function(){
   x.y();
});
</code></pre>

<p>so would using <code>delete</code> on <code>var x</code> successfully remove the object (after manually removing the event listeners of course)?</p>
