Skip to content

Commit 90baf15

Browse files
authored
Fix resolution of type of void keyword (microsoft#728)
1 parent f572432 commit 90baf15

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

internal/ast/utilities.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1825,6 +1825,8 @@ func IsPartOfTypeNode(node *Node) bool {
18251825
KindBooleanKeyword, KindSymbolKeyword, KindObjectKeyword, KindUndefinedKeyword, KindNullKeyword,
18261826
KindNeverKeyword:
18271827
return true
1828+
case KindVoidKeyword:
1829+
return node.Parent.Kind != KindVoidExpression
18281830
case KindExpressionWithTypeArguments:
18291831
return isPartOfTypeExpressionWithTypeArguments(node)
18301832
case KindTypeParameter:

0 commit comments

Comments
 (0)