{"action":"created","issue":{"url":"https://api.github.com/repos/feross/standard/issues/581","repository_url":"https://api.github.com/repos/feross/standard","labels_url":"https://api.github.com/repos/feross/standard/issues/581/labels{/name}","comments_url":"https://api.github.com/repos/feross/standard/issues/581/comments","events_url":"https://api.github.com/repos/feross/standard/issues/581/events","html_url":"https://github.com/feross/standard/issues/581","id":169060441,"number":581,"title":"Omitting semicolons is not future-proof","user":{"login":"bakkot","id":1653598,"avatar_url":"https://avatars.githubusercontent.com/u/1653598?v=3","gravatar_id":"","url":"https://api.github.com/users/bakkot","html_url":"https://github.com/bakkot","followers_url":"https://api.github.com/users/bakkot/followers","following_url":"https://api.github.com/users/bakkot/following{/other_user}","gists_url":"https://api.github.com/users/bakkot/gists{/gist_id}","starred_url":"https://api.github.com/users/bakkot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bakkot/subscriptions","organizations_url":"https://api.github.com/users/bakkot/orgs","repos_url":"https://api.github.com/users/bakkot/repos","events_url":"https://api.github.com/users/bakkot/events{/privacy}","received_events_url":"https://api.github.com/users/bakkot/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/feross/standard/labels/question","name":"question","color":"cc317c"}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-08-03T06:50:04Z","updated_at":"2016-08-03T17:15:54Z","closed_at":"2016-08-03T12:21:29Z","body":"Consider for example the [public fields proposal](https://jeffmo.github.io/es-class-public-fields/).\r\n\r\nUnder it, this is valid code:\r\n\r\n```js\r\nclass A {\r\n  get;\r\n  set;\r\n}\r\n```\r\n\r\nand this is a syntax error:\r\n```js\r\nclass A {\r\n  get\r\n  set\r\n}\r\n```\r\n\r\nYou could add a rule which says that class fields must always start or end with a semicolon (or some other, even more special-case-y rule), but it's more overhead to remember.\r\n\r\nI don't mean to rehash the great semicolon debate; I just wanted to point out that this style is only going to become harder and harder to follow as the language evolves.\r\n\r\n(Incidentally, Babel's parsing of class properties is fairly broken, so don't rely on it as an oracle here.)\r\n\r\n--\r\n\r\n```js\r\nclass A {\r\n  x\r\n  y\r\n}\r\n```\r\nis legal; it's just 'get', 'set', 'static', and similar names which have this issue. ASI will not put a semicolon in the second snippet above because in class bodies an identifier such as 'set' is in fact a legal token to follow 'get' without an intervening semicolon."},"comment":{"url":"https://api.github.com/repos/feross/standard/issues/comments/237303373","html_url":"https://github.com/feross/standard/issues/581#issuecomment-237303373","issue_url":"https://api.github.com/repos/feross/standard/issues/581","id":237303373,"user":{"login":"bakkot","id":1653598,"avatar_url":"https://avatars.githubusercontent.com/u/1653598?v=3","gravatar_id":"","url":"https://api.github.com/users/bakkot","html_url":"https://github.com/bakkot","followers_url":"https://api.github.com/users/bakkot/followers","following_url":"https://api.github.com/users/bakkot/following{/other_user}","gists_url":"https://api.github.com/users/bakkot/gists{/gist_id}","starred_url":"https://api.github.com/users/bakkot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bakkot/subscriptions","organizations_url":"https://api.github.com/users/bakkot/orgs","repos_url":"https://api.github.com/users/bakkot/repos","events_url":"https://api.github.com/users/bakkot/events{/privacy}","received_events_url":"https://api.github.com/users/bakkot/received_events","type":"User","site_admin":false},"created_at":"2016-08-03T17:15:54Z","updated_at":"2016-08-03T17:15:54Z","body":"For posterity, this is related to https://github.com/feross/standard/issues/372."}}
{"actor":{"display_login":"bakkot"}}