diff --git a/packages/language-service/src/typescript_symbols.ts b/packages/language-service/src/typescript_symbols.ts index dabd772459..7657bb7fda 100644 --- a/packages/language-service/src/typescript_symbols.ts +++ b/packages/language-service/src/typescript_symbols.ts @@ -827,7 +827,7 @@ function getTsTypeFromBuiltinType(builtinType: BuiltinType, ctx: TypeContext): t `Internal error, unhandled literal kind ${builtinType}:${BuiltinType[builtinType]}`); } const node = ts.createNode(syntaxKind); - node.parent = ctx.node; + node.parent = ts.createEmptyStatement(); return ctx.checker.getTypeAtLocation(node); }