{"action":"created","comment":{"url":"https://api.github.com/repos/webonyx/graphql-php/pulls/comments/211225926","pull_request_review_id":147600273,"id":211225926,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxMTIyNTkyNg==","diff_hunk":"@@ -1,17 +1,23 @@\n <?php\n+\n+declare(strict_types=1);\n+\n namespace GraphQL\\Language\\AST;\n \n class ArgumentNode extends Node\n {\n+    /** @var string */\n     public $kind = NodeKind::ARGUMENT;\n \n-    /**\n-     * @var ValueNode\n-     */\n+    /** @var ValueNode */\n     public $value;\n \n-    /**\n-     * @var NameNode\n-     */\n+    /** @var NameNode */\n     public $name;\n+\n+\n+    public function getKind() : string\n+    {\n+        return NodeKind::ARGUMENT;\n+    }","path":"src/Language/AST/ArgumentNode.php","position":28,"original_position":28,"commit_id":"3c329ead34e24a3bcaca914dba3b7e6c13f0519a","original_commit_id":"d585acdd1b1795f8d2f7b38a6e94b42e1f6f2369","user":{"login":"vladar","id":115628,"node_id":"MDQ6VXNlcjExNTYyOA==","avatar_url":"https://avatars2.githubusercontent.com/u/115628?v=4","gravatar_id":"","url":"https://api.github.com/users/vladar","html_url":"https://github.com/vladar","followers_url":"https://api.github.com/users/vladar/followers","following_url":"https://api.github.com/users/vladar/following{/other_user}","gists_url":"https://api.github.com/users/vladar/gists{/gist_id}","starred_url":"https://api.github.com/users/vladar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vladar/subscriptions","organizations_url":"https://api.github.com/users/vladar/orgs","repos_url":"https://api.github.com/users/vladar/repos","events_url":"https://api.github.com/users/vladar/events{/privacy}","received_events_url":"https://api.github.com/users/vladar/received_events","type":"User","site_admin":false},"body":"Actually, your link says that getters do add a quite significant overhead to performance (8.21 vs 11.08 seconds in tests).\r\n\r\nAnd that's actually the main reason why AST is designed like this (without getters). PHP is not the best language for projects like this, so we really have to sacrifice some of the best practices for performance gains.\r\n\r\nSo I would actually suggest reverting the getKind() getter. And it's better to separate the work on the code style from changes to interfaces and logic, because those require some benchmarking first.","created_at":"2018-08-20T11:18:15Z","updated_at":"2018-08-20T11:18:16Z","html_url":"https://github.com/webonyx/graphql-php/pull/323#discussion_r211225926","pull_request_url":"https://api.github.com/repos/webonyx/graphql-php/pulls/323","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/webonyx/graphql-php/pulls/comments/211225926"},"html":{"href":"https://github.com/webonyx/graphql-php/pull/323#discussion_r211225926"},"pull_request":{"href":"https://api.github.com/repos/webonyx/graphql-php/pulls/323"}},"in_reply_to_id":211202413},"pull_request":{"url":"https://api.github.com/repos/webonyx/graphql-php/pulls/323","id":207911208,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA3OTExMjA4","html_url":"https://github.com/webonyx/graphql-php/pull/323","diff_url":"https://github.com/webonyx/graphql-php/pull/323.diff","patch_url":"https://github.com/webonyx/graphql-php/pull/323.patch","issue_url":"https://api.github.com/repos/webonyx/graphql-php/issues/323","number":323,"state":"open","locked":false,"title":"Fix CS in src/Language","user":{"login":"simPod","id":327717,"node_id":"MDQ6VXNlcjMyNzcxNw==","avatar_url":"https://avatars0.githubusercontent.com/u/327717?v=4","gravatar_id":"","url":"https://api.github.com/users/simPod","html_url":"https://github.com/simPod","followers_url":"https://api.github.com/users/simPod/followers","following_url":"https://api.github.com/users/simPod/following{/other_user}","gists_url":"https://api.github.com/users/simPod/gists{/gist_id}","starred_url":"https://api.github.com/users/simPod/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simPod/subscriptions","organizations_url":"https://api.github.com/users/simPod/orgs","repos_url":"https://api.github.com/users/simPod/repos","events_url":"https://api.github.com/users/simPod/events{/privacy}","received_events_url":"https://api.github.com/users/simPod/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-08-13T09:00:10Z","updated_at":"2018-08-20T11:18:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"86bef251b2631718b1c3d19f2f873379564d17c9","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/webonyx/graphql-php/pulls/323/commits","review_comments_url":"https://api.github.com/repos/webonyx/graphql-php/pulls/323/comments","review_comment_url":"https://api.github.com/repos/webonyx/graphql-php/pulls/comments{/number}","comments_url":"https://api.github.com/repos/webonyx/graphql-php/issues/323/comments","statuses_url":"https://api.github.com/repos/webonyx/graphql-php/statuses/3c329ead34e24a3bcaca914dba3b7e6c13f0519a","head":{"label":"simPod:language-cs","ref":"language-cs","sha":"3c329ead34e24a3bcaca914dba3b7e6c13f0519a","user":{"login":"simPod","id":327717,"node_id":"MDQ6VXNlcjMyNzcxNw==","avatar_url":"https://avatars0.githubusercontent.com/u/327717?v=4","gravatar_id":"","url":"https://api.github.com/users/simPod","html_url":"https://github.com/simPod","followers_url":"https://api.github.com/users/simPod/followers","following_url":"https://api.github.com/users/simPod/following{/other_user}","gists_url":"https://api.github.com/users/simPod/gists{/gist_id}","starred_url":"https://api.github.com/users/simPod/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simPod/subscriptions","organizations_url":"https://api.github.com/users/simPod/orgs","repos_url":"https://api.github.com/users/simPod/repos","events_url":"https://api.github.com/users/simPod/events{/privacy}","received_events_url":"https://api.github.com/users/simPod/received_events","type":"User","site_admin":false},"repo":{"id":137533565,"node_id":"MDEwOlJlcG9zaXRvcnkxMzc1MzM1NjU=","name":"graphql-php","full_name":"simPod/graphql-php","owner":{"login":"simPod","id":327717,"node_id":"MDQ6VXNlcjMyNzcxNw==","avatar_url":"https://avatars0.githubusercontent.com/u/327717?v=4","gravatar_id":"","url":"https://api.github.com/users/simPod","html_url":"https://github.com/simPod","followers_url":"https://api.github.com/users/simPod/followers","following_url":"https://api.github.com/users/simPod/following{/other_user}","gists_url":"https://api.github.com/users/simPod/gists{/gist_id}","starred_url":"https://api.github.com/users/simPod/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simPod/subscriptions","organizations_url":"https://api.github.com/users/simPod/orgs","repos_url":"https://api.github.com/users/simPod/repos","events_url":"https://api.github.com/users/simPod/events{/privacy}","received_events_url":"https://api.github.com/users/simPod/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/simPod/graphql-php","description":"A PHP port of GraphQL reference implementation","fork":true,"url":"https://api.github.com/repos/simPod/graphql-php","forks_url":"https://api.github.com/repos/simPod/graphql-php/forks","keys_url":"https://api.github.com/repos/simPod/graphql-php/keys{/key_id}","collaborators_url":"https://api.github.com/repos/simPod/graphql-php/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/simPod/graphql-php/teams","hooks_url":"https://api.github.com/repos/simPod/graphql-php/hooks","issue_events_url":"https://api.github.com/repos/simPod/graphql-php/issues/events{/number}","events_url":"https://api.github.com/repos/simPod/graphql-php/events","assignees_url":"https://api.github.com/repos/simPod/graphql-php/assignees{/user}","branches_url":"https://api.github.com/repos/simPod/graphql-php/branches{/branch}","tags_url":"https://api.github.com/repos/simPod/graphql-php/tags","blobs_url":"https://api.github.com/repos/simPod/graphql-php/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/simPod/graphql-php/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/simPod/graphql-php/git/refs{/sha}","trees_url":"https://api.github.com/repos/simPod/graphql-php/git/trees{/sha}","statuses_url":"https://api.github.com/repos/simPod/graphql-php/statuses/{sha}","languages_url":"https://api.github.com/repos/simPod/graphql-php/languages","stargazers_url":"https://api.github.com/repos/simPod/graphql-php/stargazers","contributors_url":"https://api.github.com/repos/simPod/graphql-php/contributors","subscribers_url":"https://api.github.com/repos/simPod/graphql-php/subscribers","subscription_url":"https://api.github.com/repos/simPod/graphql-php/subscription","commits_url":"https://api.github.com/repos/simPod/graphql-php/commits{/sha}","git_commits_url":"https://api.github.com/repos/simPod/graphql-php/git/commits{/sha}","comments_url":"https://api.github.com/repos/simPod/graphql-php/comments{/number}","issue_comment_url":"https://api.github.com/repos/simPod/graphql-php/issues/comments{/number}","contents_url":"https://api.github.com/repos/simPod/graphql-php/contents/{+path}","compare_url":"https://api.github.com/repos/simPod/graphql-php/compare/{base}...{head}","merges_url":"https://api.github.com/repos/simPod/graphql-php/merges","archive_url":"https://api.github.com/repos/simPod/graphql-php/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/simPod/graphql-php/downloads","issues_url":"https://api.github.com/repos/simPod/graphql-php/issues{/number}","pulls_url":"https://api.github.com/repos/simPod/graphql-php/pulls{/number}","milestones_url":"https://api.github.com/repos/simPod/graphql-php/milestones{/number}","notifications_url":"https://api.github.com/repos/simPod/graphql-php/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/simPod/graphql-php/labels{/name}","releases_url":"https://api.github.com/repos/simPod/graphql-php/releases{/id}","deployments_url":"https://api.github.com/repos/simPod/graphql-php/deployments","created_at":"2018-06-15T21:30:40Z","updated_at":"2018-08-13T07:16:10Z","pushed_at":"2018-08-20T11:08:51Z","git_url":"git://github.com/simPod/graphql-php.git","ssh_url":"git@github.com:simPod/graphql-php.git","clone_url":"https://github.com/simPod/graphql-php.git","svn_url":"https://github.com/simPod/graphql-php","homepage":"http://webonyx.github.io/graphql-php/","size":2636,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"webonyx:master","ref":"master","sha":"cc39b3ecbf75e67a907f2caf8b866f2e7007a454","user":{"login":"webonyx","id":10217474,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMjE3NDc0","avatar_url":"https://avatars3.githubusercontent.com/u/10217474?v=4","gravatar_id":"","url":"https://api.github.com/users/webonyx","html_url":"https://github.com/webonyx","followers_url":"https://api.github.com/users/webonyx/followers","following_url":"https://api.github.com/users/webonyx/following{/other_user}","gists_url":"https://api.github.com/users/webonyx/gists{/gist_id}","starred_url":"https://api.github.com/users/webonyx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webonyx/subscriptions","organizations_url":"https://api.github.com/users/webonyx/orgs","repos_url":"https://api.github.com/users/webonyx/repos","events_url":"https://api.github.com/users/webonyx/events{/privacy}","received_events_url":"https://api.github.com/users/webonyx/received_events","type":"Organization","site_admin":false},"repo":{"id":39149031,"node_id":"MDEwOlJlcG9zaXRvcnkzOTE0OTAzMQ==","name":"graphql-php","full_name":"webonyx/graphql-php","owner":{"login":"webonyx","id":10217474,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMjE3NDc0","avatar_url":"https://avatars3.githubusercontent.com/u/10217474?v=4","gravatar_id":"","url":"https://api.github.com/users/webonyx","html_url":"https://github.com/webonyx","followers_url":"https://api.github.com/users/webonyx/followers","following_url":"https://api.github.com/users/webonyx/following{/other_user}","gists_url":"https://api.github.com/users/webonyx/gists{/gist_id}","starred_url":"https://api.github.com/users/webonyx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webonyx/subscriptions","organizations_url":"https://api.github.com/users/webonyx/orgs","repos_url":"https://api.github.com/users/webonyx/repos","events_url":"https://api.github.com/users/webonyx/events{/privacy}","received_events_url":"https://api.github.com/users/webonyx/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/webonyx/graphql-php","description":"A PHP port of GraphQL reference implementation","fork":false,"url":"https://api.github.com/repos/webonyx/graphql-php","forks_url":"https://api.github.com/repos/webonyx/graphql-php/forks","keys_url":"https://api.github.com/repos/webonyx/graphql-php/keys{/key_id}","collaborators_url":"https://api.github.com/repos/webonyx/graphql-php/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/webonyx/graphql-php/teams","hooks_url":"https://api.github.com/repos/webonyx/graphql-php/hooks","issue_events_url":"https://api.github.com/repos/webonyx/graphql-php/issues/events{/number}","events_url":"https://api.github.com/repos/webonyx/graphql-php/events","assignees_url":"https://api.github.com/repos/webonyx/graphql-php/assignees{/user}","branches_url":"https://api.github.com/repos/webonyx/graphql-php/branches{/branch}","tags_url":"https://api.github.com/repos/webonyx/graphql-php/tags","blobs_url":"https://api.github.com/repos/webonyx/graphql-php/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/webonyx/graphql-php/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/webonyx/graphql-php/git/refs{/sha}","trees_url":"https://api.github.com/repos/webonyx/graphql-php/git/trees{/sha}","statuses_url":"https://api.github.com/repos/webonyx/graphql-php/statuses/{sha}","languages_url":"https://api.github.com/repos/webonyx/graphql-php/languages","stargazers_url":"https://api.github.com/repos/webonyx/graphql-php/stargazers","contributors_url":"https://api.github.com/repos/webonyx/graphql-php/contributors","subscribers_url":"https://api.github.com/repos/webonyx/graphql-php/subscribers","subscription_url":"https://api.github.com/repos/webonyx/graphql-php/subscription","commits_url":"https://api.github.com/repos/webonyx/graphql-php/commits{/sha}","git_commits_url":"https://api.github.com/repos/webonyx/graphql-php/git/commits{/sha}","comments_url":"https://api.github.com/repos/webonyx/graphql-php/comments{/number}","issue_comment_url":"https://api.github.com/repos/webonyx/graphql-php/issues/comments{/number}","contents_url":"https://api.github.com/repos/webonyx/graphql-php/contents/{+path}","compare_url":"https://api.github.com/repos/webonyx/graphql-php/compare/{base}...{head}","merges_url":"https://api.github.com/repos/webonyx/graphql-php/merges","archive_url":"https://api.github.com/repos/webonyx/graphql-php/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/webonyx/graphql-php/downloads","issues_url":"https://api.github.com/repos/webonyx/graphql-php/issues{/number}","pulls_url":"https://api.github.com/repos/webonyx/graphql-php/pulls{/number}","milestones_url":"https://api.github.com/repos/webonyx/graphql-php/milestones{/number}","notifications_url":"https://api.github.com/repos/webonyx/graphql-php/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/webonyx/graphql-php/labels{/name}","releases_url":"https://api.github.com/repos/webonyx/graphql-php/releases{/id}","deployments_url":"https://api.github.com/repos/webonyx/graphql-php/deployments","created_at":"2015-07-15T16:51:22Z","updated_at":"2018-08-20T11:11:07Z","pushed_at":"2018-08-20T11:08:53Z","git_url":"git://github.com/webonyx/graphql-php.git","ssh_url":"git@github.com:webonyx/graphql-php.git","clone_url":"https://github.com/webonyx/graphql-php.git","svn_url":"https://github.com/webonyx/graphql-php","homepage":"http://webonyx.github.io/graphql-php/","size":2622,"stargazers_count":2408,"watchers_count":2408,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":224,"mirror_url":null,"archived":false,"open_issues_count":24,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":224,"open_issues":24,"watchers":2408,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/webonyx/graphql-php/pulls/323"},"html":{"href":"https://github.com/webonyx/graphql-php/pull/323"},"issue":{"href":"https://api.github.com/repos/webonyx/graphql-php/issues/323"},"comments":{"href":"https://api.github.com/repos/webonyx/graphql-php/issues/323/comments"},"review_comments":{"href":"https://api.github.com/repos/webonyx/graphql-php/pulls/323/comments"},"review_comment":{"href":"https://api.github.com/repos/webonyx/graphql-php/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/webonyx/graphql-php/pulls/323/commits"},"statuses":{"href":"https://api.github.com/repos/webonyx/graphql-php/statuses/3c329ead34e24a3bcaca914dba3b7e6c13f0519a"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"vladar"}}