mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
24 lines
468 B
Plaintext
24 lines
468 B
Plaintext
/a.js(7,7): error TS2322: Type 'number' is not assignable to type 'T'.
|
|
|
|
|
|
==== /a.js (1 errors) ====
|
|
/**
|
|
* @typedef {object} T
|
|
* @property {boolean} await
|
|
*/
|
|
|
|
/** @type {T} */
|
|
const a = 1;
|
|
~
|
|
!!! error TS2322: Type 'number' is not assignable to type 'T'.
|
|
|
|
/** @type {T} */
|
|
const b = {
|
|
await: false,
|
|
};
|
|
|
|
/**
|
|
* @param {boolean} await
|
|
*/
|
|
function c(await) {}
|
|
|