Bug Report
Code does not compile.
馃攷 Search Terms
"Operator '+' cannot be applied to types".
馃晽 Version & Regression Information
4.7.4
馃捇 Code
const foo = { foo: 123, bar: 'bar' };
for (const k of ['foo', 'bar'] as const) {
const val = foo[k];
console.log(val + val);
}
馃檨 Actual behavior
src/test.ts:5:15 - error TS2365: Operator '+' cannot be applied to types 'string | number' and 'string | number'.
馃檪 Expected behavior
No error.
Bug Report
Code does not compile.
馃攷 Search Terms
"Operator '+' cannot be applied to types".
馃晽 Version & Regression Information
4.7.4
馃捇 Code
馃檨 Actual behavior
馃檪 Expected behavior
No error.