{"action":"created","issue":{"url":"https://api.github.com/repos/Microsoft/TypeScript/issues/6155","labels_url":"https://api.github.com/repos/Microsoft/TypeScript/issues/6155/labels{/name}","comments_url":"https://api.github.com/repos/Microsoft/TypeScript/issues/6155/comments","events_url":"https://api.github.com/repos/Microsoft/TypeScript/issues/6155/events","html_url":"https://github.com/Microsoft/TypeScript/issues/6155","id":123002391,"number":6155,"title":"consider allowing exhaustive switch statement","user":{"login":"aleksey-bykov","id":937933,"avatar_url":"https://avatars.githubusercontent.com/u/937933?v=3","gravatar_id":"","url":"https://api.github.com/users/aleksey-bykov","html_url":"https://github.com/aleksey-bykov","followers_url":"https://api.github.com/users/aleksey-bykov/followers","following_url":"https://api.github.com/users/aleksey-bykov/following{/other_user}","gists_url":"https://api.github.com/users/aleksey-bykov/gists{/gist_id}","starred_url":"https://api.github.com/users/aleksey-bykov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aleksey-bykov/subscriptions","organizations_url":"https://api.github.com/users/aleksey-bykov/orgs","repos_url":"https://api.github.com/users/aleksey-bykov/repos","events_url":"https://api.github.com/users/aleksey-bykov/events{/privacy}","received_events_url":"https://api.github.com/users/aleksey-bykov/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-12-18T18:27:29Z","updated_at":"2015-12-18T18:32:17Z","closed_at":null,"body":"```typescript\r\ntype foo = 'hey' | 'nay';\r\nlet value : foo = 'hey';\r\nswitch (value) {\r\n    case 'hey': doThis(); break;\r\n    case 'nay': doThat(); break;\r\n    default: void; // <-- syntax TBD that indicates 1. no other than known options are allowed 2. all known options must be considered\r\n}\r\n```"},"comment":{"url":"https://api.github.com/repos/Microsoft/TypeScript/issues/comments/165865186","html_url":"https://github.com/Microsoft/TypeScript/issues/6155#issuecomment-165865186","issue_url":"https://api.github.com/repos/Microsoft/TypeScript/issues/6155","id":165865186,"user":{"login":"weswigham","id":2932786,"avatar_url":"https://avatars.githubusercontent.com/u/2932786?v=3","gravatar_id":"","url":"https://api.github.com/users/weswigham","html_url":"https://github.com/weswigham","followers_url":"https://api.github.com/users/weswigham/followers","following_url":"https://api.github.com/users/weswigham/following{/other_user}","gists_url":"https://api.github.com/users/weswigham/gists{/gist_id}","starred_url":"https://api.github.com/users/weswigham/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/weswigham/subscriptions","organizations_url":"https://api.github.com/users/weswigham/orgs","repos_url":"https://api.github.com/users/weswigham/repos","events_url":"https://api.github.com/users/weswigham/events{/privacy}","received_events_url":"https://api.github.com/users/weswigham/received_events","type":"User","site_admin":false},"created_at":"2015-12-18T18:32:17Z","updated_at":"2015-12-18T18:32:17Z","body":"The `default` branch in your example can be triggered when `value` is `undefined` or `null` as both `let value : foo = null;` and `let value : foo = undefined;` are valid for type `foo`."}}