1 // Copyright 2014 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 /** 6 * @fileoverview Provides a partial copy of goog.inherits, so inheritance works 7 * even in the absence of Closure. 8 */ 9 'use strict'; 10 11 // A partial copy of goog.inherits, so inheritance works even in the absence of 12 // Closure. 13 function inherits(childCtor, parentCtor) { 14 /** @constructor */ 15 function tempCtor() { 16 } 17 tempCtor.prototype = parentCtor.prototype; 18 childCtor.prototype = new tempCtor; 19 childCtor.prototype.constructor = childCtor; 20 } 21