fix(48851): exclude in from document highlights (#48853)

This commit is contained in:
Oleksandr T
2022-04-27 17:51:05 -07:00
committed by GitHub
parent 0885482eeb
commit 9b3853d49e
2 changed files with 15 additions and 0 deletions
+2
View File
@@ -93,6 +93,8 @@ namespace ts {
return highlightSpans(getAsyncAndAwaitOccurrences(node));
case SyntaxKind.YieldKeyword:
return highlightSpans(getYieldOccurrences(node));
case SyntaxKind.InKeyword:
return undefined;
default:
return isModifierKind(node.kind) && (isDeclaration(node.parent) || isVariableStatement(node.parent))
? highlightSpans(getModifierOccurrences(node.kind, node.parent))
@@ -0,0 +1,13 @@
/// <reference path='fourslash.ts'/>
////export type Foo<T> = {
//// [K [|in|] keyof T]: any;
////}
////
////"a" [|in|] {};
////
////for (let a [|in|] {}) {}
for (let range of test.ranges()) {
verify.noDocumentHighlights(range);
}