Skip to content

Commit 1d4c1d1

Browse files
author
Kanchalai Tanglertsampan
committed
rename function
1 parent aff6775 commit 1d4c1d1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/compiler/checker.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7298,7 +7298,7 @@ namespace ts {
72987298
* Otherwise, return false
72997299
* @param classDecl a class declaration to check if it extends null
73007300
*/
7301-
function isClassDeclarationExtendNull(classDecl: ClassDeclaration): boolean {
7301+
function classDeclarationExtendsNull(classDecl: ClassDeclaration): boolean {
73027302
const classSymbol = getSymbolOfNode(classDecl);
73037303
const classInstanceType = <InterfaceType>getDeclaredTypeOfSymbol(classSymbol);
73047304
const baseConstructorType = getBaseConstructorTypeOfClass(classInstanceType);
@@ -7318,7 +7318,7 @@ namespace ts {
73187318

73197319
// If a containing class does not have extends clause or the class extends null
73207320
// skip checking whether super statement is called before "this" accessing.
7321-
if (baseTypeNode && !isClassDeclarationExtendNull(containingClassDecl)) {
7321+
if (baseTypeNode && !classDeclarationExtendsNull(containingClassDecl)) {
73227322
const superCall = getSuperCallInConstructor(<ConstructorDeclaration>container);
73237323

73247324
// We should give an error in the following cases:
@@ -11842,7 +11842,7 @@ namespace ts {
1184211842
// whereas constructors of derived classes must contain at least one super call somewhere in their function body.
1184311843
const containingClassDecl = <ClassDeclaration>node.parent;
1184411844
if (getClassExtendsHeritageClauseElement(containingClassDecl)) {
11845-
const isClassExtendNull = isClassDeclarationExtendNull(containingClassDecl);
11845+
const isClassExtendNull = classDeclarationExtendsNull(containingClassDecl);
1184611846

1184711847
if (getSuperCallInConstructor(node)) {
1184811848
if (isClassExtendNull) {

0 commit comments

Comments
 (0)