add existence check to t.inherits
This commit is contained in:
parent
bd052aea50
commit
c828688d21
@ -278,6 +278,8 @@ export function inheritsComments(child: Object, parent: Object): Object {
|
||||
*/
|
||||
|
||||
export function inherits(child: Object, parent: Object): Object {
|
||||
if (!child || !parent) return child;
|
||||
|
||||
child._declarations = parent._declarations;
|
||||
child._scopeInfo = parent._scopeInfo;
|
||||
child.range = parent.range;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user