Potential memory leak due to closures?
<p>I'm trying to approximate a class structure in javascript with the ability to use a "super" method (call the method on parent class) and was wondering if I'm setting myself up for memory leaks.</p>

<pre><code>//The function I use to create inheritance is:
/*
* see http://michaux.ca/articles/class-based-inheritance-in-javascript
*/
function extend(subclass, superclass) {
       function Dummy() {}
       Dummy.prototype = superclass.prototype;
       subclass.prototype = new Dummy();
       subclass.prototype.constructor = subclass;
       subclass.superclass = superclass;
       subclass.superproto = superclass.prototype;
       subclass.prototype._super=function(){
        return superclass.prototype
       };
};

//I then created a global function to approximate the use of "super":

function Super(c,m){
    return function(){
        var args=[].slice.apply(arguments);
        c._super()[m].apply(c,args);
    };
};

//They way it all ties together is:

//-------------------------------
//parent class
//-------------------------------
function pp(){  
};

pp.prototype.msg=function(f,b){
    console.log("pp hi f="+f+" b="+b);
};

//-------------------------------
//child class
//-------------------------------
function zz(){
    zz.superclass.call(this);
};

//create the inherientance
extend(zz,pp);

zz.prototype.msg=function(b){
    console.log("zz hi");
    Super(this,"msg")("foo",b);
};

//-------------------------------
//test it all
//-------------------------------
var m = new zz();
m.msg("bar");
</code></pre>

<p>So, I'm I setting myself up for memory leaks using the closures?</p>
