3 ms·
I used a similar pattern once, except _generically_ as follows: function Breakfast(my, args) { if (!(this instanceof arguments.callee)) return new ar
by eldude 15y ago
I used a similar pattern once, except _generically_ as follows:
function Breakfast(my, args) {
if (!(this instanceof arguments.callee)) return new arguments.callee(arguments);
if (Object.prototype.toString.call(arguments[0]) === '[object Arguments]') arguments.callee.apply(this, args);
}