Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 13.8k
Bad error message for type used as index #25770
Copy link
Copy link
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: Error MessagesThe issue relates to error messagingThe issue relates to error messagingDomain: Mapped TypesThe issue relates to mapped typesThe issue relates to mapped typesHelp WantedYou can do thisYou can do this
Milestone
Description
Activity
Metadata
Metadata
Assignees
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: Error MessagesThe issue relates to error messagingThe issue relates to error messagingDomain: Mapped TypesThe issue relates to mapped typesThe issue relates to mapped typesHelp WantedYou can do thisYou can do this
TypeScript Version: 3.1.0-dev.20180717
Code
Expected behavior:
Error message telling me to use
K in S.Actual behavior:
src/a.ts:2:13 - error TS2693: 'S' only refers to a type, but is being used as a value here.