Skip to content

Report Syntax Errors in JSDocs Type Annotations #13371

Closed
@mjbvz

Description

@mjbvz

From microsoft/vscode#18229

TypeScript Version: 2.2.0-dev.20170109

Code
In a JS file:

/**
 * @param {(x)=>void} x 
 **/
function foo(x) { }

Expected behavior:
Reports a syntax error when trying to parse the JSDoc type annotation

Actual behavior:
No error reported. x has any type

Metadata

Metadata

Assignees

Labels

FixedA PR has been merged for this issueSuggestionAn idea for TypeScriptVS Code TrackedThere is a VS Code equivalent to this issue

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions