mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-02-10 15:25:54 -06:00
Addressed PR
This commit is contained in:
parent
ec7e80e377
commit
91ea83c72a
@ -14075,12 +14075,12 @@ namespace ts {
|
||||
}
|
||||
|
||||
function checkBaseTypeAccessibility(type: ObjectType, node: ExpressionWithTypeArguments) {
|
||||
const typeClassDeclaration = <ClassLikeDeclaration>getClassLikeDeclarationOfSymbol(type.symbol);
|
||||
if (!isNodeWithinClass(node, typeClassDeclaration)) {
|
||||
const signatures = getSignaturesOfType(type, SignatureKind.Construct);
|
||||
if (signatures.length) {
|
||||
const declaration = signatures[0].declaration;
|
||||
if (declaration && declaration.flags & NodeFlags.Private) {
|
||||
const signatures = getSignaturesOfType(type, SignatureKind.Construct);
|
||||
if (signatures.length) {
|
||||
const declaration = signatures[0].declaration;
|
||||
if (declaration && declaration.flags & NodeFlags.Private) {
|
||||
const typeClassDeclaration = <ClassLikeDeclaration>getClassLikeDeclarationOfSymbol(type.symbol);
|
||||
if (!isNodeWithinClass(node, typeClassDeclaration)) {
|
||||
error(node, Diagnostics.Cannot_extend_a_class_0_Class_constructor_is_marked_as_private, (<Identifier>node.expression).text);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user