diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 2ff2c8590d0..04d8ce937d0 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -10449,7 +10449,10 @@ namespace ts { case SyntaxKind.FunctionExpression: case SyntaxKind.FunctionDeclaration: case SyntaxKind.ArrowFunction: - case SyntaxKind.ObjectLiteralExpression: return false; + case SyntaxKind.ClassExpression: + case SyntaxKind.ClassDeclaration: + case SyntaxKind.GetAccessor: + case SyntaxKind.SetAccessor: return false; default: return forEachChild(n, containsSuperCall); } }