TypeScript/tests/cases/conformance/salsa/annotatedThisPropertyInitializerDoesntNarrow.ts

18 lines
373 B
TypeScript
Raw Normal View History

// @noEmit: true
// @allowJs: true
// @checkJs: true
// @Filename: Compilation.js
// from webpack/lib/Compilation.js and filed at #26427
/** @param {{ [s: string]: number }} map */
function mappy(map) {}
export class C {
constructor() {
/** @type {{ [assetName: string]: number}} */
this.assets = {};
}
m() {
mappy(this.assets)
}
}