{"action":"closed","issue":{"url":"https://api.github.com/repos/facebook/flow/issues/731","repository_url":"https://api.github.com/repos/facebook/flow","labels_url":"https://api.github.com/repos/facebook/flow/issues/731/labels{/name}","comments_url":"https://api.github.com/repos/facebook/flow/issues/731/comments","events_url":"https://api.github.com/repos/facebook/flow/issues/731/events","html_url":"https://github.com/facebook/flow/issues/731","id":102255579,"number":731,"title":"Variables from destructuring assignments seem to be not correctly typechecked.","user":{"login":"Eyyub","id":1885424,"avatar_url":"https://avatars.githubusercontent.com/u/1885424?v=3","gravatar_id":"","url":"https://api.github.com/users/Eyyub","html_url":"https://github.com/Eyyub","followers_url":"https://api.github.com/users/Eyyub/followers","following_url":"https://api.github.com/users/Eyyub/following{/other_user}","gists_url":"https://api.github.com/users/Eyyub/gists{/gist_id}","starred_url":"https://api.github.com/users/Eyyub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Eyyub/subscriptions","organizations_url":"https://api.github.com/users/Eyyub/orgs","repos_url":"https://api.github.com/users/Eyyub/repos","events_url":"https://api.github.com/users/Eyyub/events{/privacy}","received_events_url":"https://api.github.com/users/Eyyub/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/facebook/flow/labels/destructuring","name":"destructuring","color":"006b75"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2015-08-20T22:48:03Z","updated_at":"2016-06-23T21:11:39Z","closed_at":"2016-06-23T21:11:39Z","body":"```js\r\n/* @flow */\r\nvar p : string = 'Hello samg';\r\np = 1; // error, correct                                                                                                     \r\n\r\nvar {foo} : {foo : string} = {foo : 'bar'};\r\nfoo = 1; // no error                                                                                                         \r\n(foo : number | string);\r\n```\r\n\r\nI would expect an error in the second case, I believe, maybe, it's because of a difference about how simple variables and destructuring assignments are initialized."}}
{"actor":{"display_login":"facebook-github-bot-2"}}