犀牛书第五版读书笔记——Chapter 9. Classes, Constructors, and Prototypes(第二部分)
8.当在Complex对象上查找属性时,首先在对象本身上查找。如果属性没有找到,就查找Complex.prototype对象。最后,如果仍然没有找到,则在Object.prototype对象上查找
9.在需要的时候,用以下方式可以实现从任何对象继承,而不只是从Object类继承
PositionedRectangle.prototype = new Rectangle( );delete PositionedRectangle.prototype.width;delete PositionedRectangle.prototype.height;PositionedRectangle.prototype.constructor = PositionedRectangle;