diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index db95eb9bc17..41fc483f4ee 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -6114,7 +6114,7 @@ namespace ts { // know that all parameters (including 'this') have type annotations and nothing is // subject to contextual typing. const parameter = firstOrUndefined(node.parameters); - return !(parameter && parameter.name.kind === SyntaxKind.Identifier && (parameter.name).text === "this"); + return !(parameter && parameterIsThisKeyword(parameter)); } function isContextSensitiveFunctionOrObjectLiteralMethod(func: Node): func is FunctionExpression | ArrowFunction | MethodDeclaration {