Mercurial > js4py
view misc.js @ 162:77e87f1b5811 core-javascript
$ hg merge core-javascript.closure-exercises # done, at least for now
| author | jf3243 |
|---|---|
| date | Wed, 09 Nov 2011 17:00:38 +0000 |
| parents | 48d5ba601286 |
| children |
line wrap: on
line source
var create = function(parent){ if (typeof parent === 'object' && parent !== null){ var fn = function(){}; fn.prototype = parent; return new fn(); } return null; // Or raise an exception. };
