-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Closed
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: JSDocRelates to JSDoc parsing and type generationRelates to JSDoc parsing and type generationFixedA PR has been merged for this issueA PR has been merged for this issue
Milestone
Description
TypeScript Version: 2.6.0-dev.20170829
/**
* @template T
*/
class MyArray {
constructor() {
/** @type {Array<T>} */
this.array = [];
}
}
/** @type {MyArray<string>} */
let x = new MyArray();Expected behavior:
x should contain an array of strings.
Actual behavior:
[js] Cannot find name 'T'.
[js] Type 'MyArray' is not generic.
tenorok, que-etc and ekulabuhov
Metadata
Metadata
Assignees
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: JSDocRelates to JSDoc parsing and type generationRelates to JSDoc parsing and type generationFixedA PR has been merged for this issueA PR has been merged for this issue