payload: {"action":"opened","issue":{"url":"https://api.github.com/repos/dsherret/ts-morph/issues/728","repository_url":"https://api.github.com/repos/dsherret/ts-morph","labels_url":"https://api.github.com/repos/dsherret/ts-morph/issues/728/labels{/name}","comments_url":"https://api.github.com/repos/dsherret/ts-morph/issues/728/comments","events_url":"https://api.github.com/repos/dsherret/ts-morph/issues/728/events","html_url":"https://github.com/dsherret/ts-morph/issues/728","id":502996961,"node_id":"MDU6SXNzdWU1MDI5OTY5NjE=","number":728,"title":"TypeGuards isSemicolonToken, isInferKeyword negated will infer node as 'never'","user":{"login":"cancerberoSgx","id":112746,"node_id":"MDQ6VXNlcjExMjc0Ng==","avatar_url":"https://avatars3.githubusercontent.com/u/112746?v=4","gravatar_id":"","url":"https://api.github.com/users/cancerberoSgx","html_url":"https://github.com/cancerberoSgx","followers_url":"https://api.github.com/users/cancerberoSgx/followers","following_url":"https://api.github.com/users/cancerberoSgx/following{/other_user}","gists_url":"https://api.github.com/users/cancerberoSgx/gists{/gist_id}","starred_url":"https://api.github.com/users/cancerberoSgx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cancerberoSgx/subscriptions","organizations_url":"https://api.github.com/users/cancerberoSgx/orgs","repos_url":"https://api.github.com/users/cancerberoSgx/repos","events_url":"https://api.github.com/users/cancerberoSgx/events{/privacy}","received_events_url":"https://api.github.com/users/cancerberoSgx/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2019-10-05T18:12:19Z","updated_at":"2019-10-05T18:12:19Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"This two typeguards, isSemicolonToken, isInferKeyword , when used with negation logic operator will infer the node has type 'never' which I think is not correct, as shown :\r\n\r\n<img width=\"444\" alt=\"Screen Shot 2019-10-05 at 3 05 46 PM\" src=\"https://user-images.githubusercontent.com/112746/66258968-c72e2b80-e781-11e9-848e-d12a4f97f07e.png\">\r\n\r\nsnippet : \r\n\r\n```ts\r\nimport { Project, TypeGuards } from 'ts-morph'\r\n\r\nconst project = new Project()\r\nconst file = project.createSourceFile('f1.ts', 'var a = 1')\r\nvar n = file.getDescendants()[2]\r\nif (n && !TypeGuards.isSemicolonToken(n)) {\r\n  var c = n.getKindName()\r\n}\r\n```\r\n\r\nI think this could be a solution but I wanted to ask before PR:\r\n\r\n\r\n```ts\r\n    static readonly isSemicolonToken: (node: Node) => node is Node<ts.Token<SyntaxKind.SemicolonToken>>;\r\n```"}}
other: {"actor":{"display_login":"cancerberoSgx"}}