60efb65931
* Do not ts-ignore noImplicitAny suggestions Still need to write tests. * Add tests * More tests * Update baselines
24 lines
410 B
TypeScript
24 lines
410 B
TypeScript
/// <reference path='fourslash.ts' />
|
|
// @strict: true
|
|
/////**
|
|
//// * @template T
|
|
//// * @param {number} a
|
|
//// * @param {T} b
|
|
//// */
|
|
////function f(a, b) {
|
|
//// return a || b;
|
|
////}
|
|
|
|
verify.codeFix({
|
|
description: "Annotate with type from JSDoc",
|
|
index: 2,
|
|
newFileContent:
|
|
`/**
|
|
* @template T
|
|
* @param {number} a
|
|
* @param {T} b
|
|
*/
|
|
function f<T>(a: number, b: T) {
|
|
return a || b;
|
|
}`,
|
|
});
|