{"action":"closed","issue":{"url":"https://api.github.com/repos/feross/standard/issues/111","labels_url":"https://api.github.com/repos/feross/standard/issues/111/labels{/name}","comments_url":"https://api.github.com/repos/feross/standard/issues/111/comments","events_url":"https://api.github.com/repos/feross/standard/issues/111/events","html_url":"https://github.com/feross/standard/issues/111","id":67846682,"number":111,"title":"Starting lines with slashes","user":{"login":"ausi","id":367169,"avatar_url":"https://avatars.githubusercontent.com/u/367169?v=3","gravatar_id":"","url":"https://api.github.com/users/ausi","html_url":"https://github.com/ausi","followers_url":"https://api.github.com/users/ausi/followers","following_url":"https://api.github.com/users/ausi/following{/other_user}","gists_url":"https://api.github.com/users/ausi/gists{/gist_id}","starred_url":"https://api.github.com/users/ausi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ausi/subscriptions","organizations_url":"https://api.github.com/users/ausi/orgs","repos_url":"https://api.github.com/users/ausi/repos","events_url":"https://api.github.com/users/ausi/events{/privacy}","received_events_url":"https://api.github.com/users/ausi/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-04-11T23:45:57Z","updated_at":"2015-04-21T00:08:54Z","closed_at":"2015-04-21T00:08:54Z","body":"The readme says starting a line with `(` or `[` is the only gotcha with omitting semicolons, but what about starting lines with `/` e.g. with a regular expression? The following code breaks:\r\n\r\n```js\r\nvar foo = function () {}\r\nvar bar = 'baz'\r\n\r\n/baz/.test(bar) && foo(bar)\r\n```\r\n\r\n`standard` detects the error and writes `Unexpected token .`, but there are cases where `standard` isn’t able to detect such errors, e.g.:\r\n\r\n```js\r\nvar foo = function () {}\r\nvar bar = 'baz'\r\n\r\n/ bar(')/.test(/' / +bar) && foo(bar)\r\n```\r\n\r\n`standard` doesn’t find an error but the code breaks with `undefined is not a function`.\r\n\r\nOmitting semicolons would be nice, but how can I make sure I’m not falling into such ASI edge cases?"}}