Fixed a crash when getting document highlights on out variance annotation (#56408)

This commit is contained in:
Mateusz Burzyński authored and GitHub committed 2023-11-15 11:34:59 -08:00
1 parent e170bc59d4
commit d1d14e67d0
3 files changed
+18

No files matched your search

+1
View File
@@ -178,6 +178,7 @@ export namespace DocumentHighlights {
case SyntaxKind.YieldKeyword:
return highlightSpans(getYieldOccurrences(node));
case SyntaxKind.InKeyword:
case SyntaxKind.OutKeyword:
return undefined;
default:
return isModifierKind(node.kind) && (isDeclaration(node.parent) || isVariableStatement(node.parent))