You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// noImplicitAny must be enabled.typeOptions="A"|"B"|"C"constMappedOptions: {[optioninOptions]: number}={A: 2,B: 3,C: 4}for(constkeyinMappedOptions){alert(MappedOptions[key])}
Expected behavior:
This compiles, as the index type of MappedOptions is Options.
Actual behavior:
A compile-time error occurs as MappedOptions has no index signature.
The text was updated successfully, but these errors were encountered:
Automatically closing this issue for housekeeping purposes. The issue labels indicate that it is unactionable at the moment or has already been addressed.
TypeScript Version: 2.2.1
Code
Expected behavior:
This compiles, as the index type of MappedOptions is Options.
Actual behavior:
A compile-time error occurs as MappedOptions has no index signature.
The text was updated successfully, but these errors were encountered: