'use strict';

// changeable contants
var C = 'constructor', // name of the constructor method
	X = 'extend'; // name of extend method

function Class() {}

Class[X] = function(subclass) {
	var self      = this,
		prototype = Object.create(self.prototype);

	subclass.call(prototype, self.prototype);


	var Extended = prototype.hasOwnProperty(C) ?
		prototype[C] :
		function() { prototype[C].apply(this, arguments); };

	Extended.prototype = prototype;
	Extended[X] = self[X];

	return Extended;
};
'use strict';

// changeable contants
var C = 'constructor', // name of the constructor method
	X = 'extend'; // name of extend method

function Class() {}

Class[X] = function(subclass) {
	var prototype = Object.create(this.prototype);

	subclass.call(prototype, this.prototype);


	var Extended = prototype.hasOwnProperty(C) ?
		prototype[C] :
		function() { prototype[C].apply(this, arguments); };

	Extended.prototype = prototype;
	Extended[X] = this[X];

	return Extended;
};

Remove unused 'self' variable