{"action":"opened","number":77,"pull_request":{"url":"https://api.github.com/repos/csyonghe/Spire/pulls/77","id":99134509,"html_url":"https://github.com/csyonghe/Spire/pull/77","diff_url":"https://github.com/csyonghe/Spire/pull/77.diff","patch_url":"https://github.com/csyonghe/Spire/pull/77.patch","issue_url":"https://api.github.com/repos/csyonghe/Spire/issues/77","number":77,"state":"open","locked":false,"title":"Unify parser handling of declarations","user":{"login":"tfoleyNV","id":10618364,"avatar_url":"https://avatars.githubusercontent.com/u/10618364?v=3","gravatar_id":"","url":"https://api.github.com/users/tfoleyNV","html_url":"https://github.com/tfoleyNV","followers_url":"https://api.github.com/users/tfoleyNV/followers","following_url":"https://api.github.com/users/tfoleyNV/following{/other_user}","gists_url":"https://api.github.com/users/tfoleyNV/gists{/gist_id}","starred_url":"https://api.github.com/users/tfoleyNV/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tfoleyNV/subscriptions","organizations_url":"https://api.github.com/users/tfoleyNV/orgs","repos_url":"https://api.github.com/users/tfoleyNV/repos","events_url":"https://api.github.com/users/tfoleyNV/events{/privacy}","received_events_url":"https://api.github.com/users/tfoleyNV/received_events","type":"User","site_admin":false},"body":"Note: this has been tested against the automated tests (such as they are), but not against the engine example (since it seems to be in a state of flux). Let me know if I should try to test against the engine before checking this in.\r\n\r\nThe big picture here is that any flavor of declaration is now allowed in any context where declarations are expected (global scope, body of a `struct`, body of a `shader`, etc.), and also any modifier keywords or attributes are allowed on any declaration (you can declare a `public param int foo;` at global scope).\r\n\r\nIt is (or rather, will be) up to later semantic analysis steps to rule out the cases that shouldn't be allowed, but we know that the parser won't stop us from supporting scenarios like:\r\n\r\n- Global variables\r\n- Member functions in `struct` types\r\n- Having component functions just be functions nested inside shader/module declarations\r\n- Struct declarations local to a module/shader\r\n- Typedefs within functions\r\n- Modules within modules\r\n\r\nYou get the point.","created_at":"2016-12-22T16:44:08Z","updated_at":"2016-12-22T16:44:08Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/csyonghe/Spire/pulls/77/commits","review_comments_url":"https://api.github.com/repos/csyonghe/Spire/pulls/77/comments","review_comment_url":"https://api.github.com/repos/csyonghe/Spire/pulls/comments{/number}","comments_url":"https://api.github.com/repos/csyonghe/Spire/issues/77/comments","statuses_url":"https://api.github.com/repos/csyonghe/Spire/statuses/bbc853e24675008d06cda80644a1e19b51b59ca2","head":{"label":"tfoleyNV:decl-parsing2","ref":"decl-parsing2","sha":"bbc853e24675008d06cda80644a1e19b51b59ca2","user":{"login":"tfoleyNV","id":10618364,"avatar_url":"https://avatars.githubusercontent.com/u/10618364?v=3","gravatar_id":"","url":"https://api.github.com/users/tfoleyNV","html_url":"https://github.com/tfoleyNV","followers_url":"https://api.github.com/users/tfoleyNV/followers","following_url":"https://api.github.com/users/tfoleyNV/following{/other_user}","gists_url":"https://api.github.com/users/tfoleyNV/gists{/gist_id}","starred_url":"https://api.github.com/users/tfoleyNV/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tfoleyNV/subscriptions","organizations_url":"https://api.github.com/users/tfoleyNV/orgs","repos_url":"https://api.github.com/users/tfoleyNV/repos","events_url":"https://api.github.com/users/tfoleyNV/events{/privacy}","received_events_url":"https://api.github.com/users/tfoleyNV/received_events","type":"User","site_admin":false},"repo":{"id":60112347,"name":"Spire","full_name":"tfoleyNV/Spire","owner":{"login":"tfoleyNV","id":10618364,"avatar_url":"https://avatars.githubusercontent.com/u/10618364?v=3","gravatar_id":"","url":"https://api.github.com/users/tfoleyNV","html_url":"https://github.com/tfoleyNV","followers_url":"https://api.github.com/users/tfoleyNV/followers","following_url":"https://api.github.com/users/tfoleyNV/following{/other_user}","gists_url":"https://api.github.com/users/tfoleyNV/gists{/gist_id}","starred_url":"https://api.github.com/users/tfoleyNV/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tfoleyNV/subscriptions","organizations_url":"https://api.github.com/users/tfoleyNV/orgs","repos_url":"https://api.github.com/users/tfoleyNV/repos","events_url":"https://api.github.com/users/tfoleyNV/events{/privacy}","received_events_url":"https://api.github.com/users/tfoleyNV/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tfoleyNV/Spire","description":null,"fork":true,"url":"https://api.github.com/repos/tfoleyNV/Spire","forks_url":"https://api.github.com/repos/tfoleyNV/Spire/forks","keys_url":"https://api.github.com/repos/tfoleyNV/Spire/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tfoleyNV/Spire/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tfoleyNV/Spire/teams","hooks_url":"https://api.github.com/repos/tfoleyNV/Spire/hooks","issue_events_url":"https://api.github.com/repos/tfoleyNV/Spire/issues/events{/number}","events_url":"https://api.github.com/repos/tfoleyNV/Spire/events","assignees_url":"https://api.github.com/repos/tfoleyNV/Spire/assignees{/user}","branches_url":"https://api.github.com/repos/tfoleyNV/Spire/branches{/branch}","tags_url":"https://api.github.com/repos/tfoleyNV/Spire/tags","blobs_url":"https://api.github.com/repos/tfoleyNV/Spire/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tfoleyNV/Spire/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tfoleyNV/Spire/git/refs{/sha}","trees_url":"https://api.github.com/repos/tfoleyNV/Spire/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tfoleyNV/Spire/statuses/{sha}","languages_url":"https://api.github.com/repos/tfoleyNV/Spire/languages","stargazers_url":"https://api.github.com/repos/tfoleyNV/Spire/stargazers","contributors_url":"https://api.github.com/repos/tfoleyNV/Spire/contributors","subscribers_url":"https://api.github.com/repos/tfoleyNV/Spire/subscribers","subscription_url":"https://api.github.com/repos/tfoleyNV/Spire/subscription","commits_url":"https://api.github.com/repos/tfoleyNV/Spire/commits{/sha}","git_commits_url":"https://api.github.com/repos/tfoleyNV/Spire/git/commits{/sha}","comments_url":"https://api.github.com/repos/tfoleyNV/Spire/comments{/number}","issue_comment_url":"https://api.github.com/repos/tfoleyNV/Spire/issues/comments{/number}","contents_url":"https://api.github.com/repos/tfoleyNV/Spire/contents/{+path}","compare_url":"https://api.github.com/repos/tfoleyNV/Spire/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tfoleyNV/Spire/merges","archive_url":"https://api.github.com/repos/tfoleyNV/Spire/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tfoleyNV/Spire/downloads","issues_url":"https://api.github.com/repos/tfoleyNV/Spire/issues{/number}","pulls_url":"https://api.github.com/repos/tfoleyNV/Spire/pulls{/number}","milestones_url":"https://api.github.com/repos/tfoleyNV/Spire/milestones{/number}","notifications_url":"https://api.github.com/repos/tfoleyNV/Spire/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tfoleyNV/Spire/labels{/name}","releases_url":"https://api.github.com/repos/tfoleyNV/Spire/releases{/id}","deployments_url":"https://api.github.com/repos/tfoleyNV/Spire/deployments","created_at":"2016-05-31T18:10:48Z","updated_at":"2016-05-31T18:10:51Z","pushed_at":"2016-12-22T16:38:57Z","git_url":"git://github.com/tfoleyNV/Spire.git","ssh_url":"git@github.com:tfoleyNV/Spire.git","clone_url":"https://github.com/tfoleyNV/Spire.git","svn_url":"https://github.com/tfoleyNV/Spire","homepage":null,"size":1057,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"csyonghe:master","ref":"master","sha":"5fe19c41ca0467567711818b267457329755083d","user":{"login":"csyonghe","id":2652293,"avatar_url":"https://avatars.githubusercontent.com/u/2652293?v=3","gravatar_id":"","url":"https://api.github.com/users/csyonghe","html_url":"https://github.com/csyonghe","followers_url":"https://api.github.com/users/csyonghe/followers","following_url":"https://api.github.com/users/csyonghe/following{/other_user}","gists_url":"https://api.github.com/users/csyonghe/gists{/gist_id}","starred_url":"https://api.github.com/users/csyonghe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/csyonghe/subscriptions","organizations_url":"https://api.github.com/users/csyonghe/orgs","repos_url":"https://api.github.com/users/csyonghe/repos","events_url":"https://api.github.com/users/csyonghe/events{/privacy}","received_events_url":"https://api.github.com/users/csyonghe/received_events","type":"User","site_admin":false},"repo":{"id":59918068,"name":"Spire","full_name":"csyonghe/Spire","owner":{"login":"csyonghe","id":2652293,"avatar_url":"https://avatars.githubusercontent.com/u/2652293?v=3","gravatar_id":"","url":"https://api.github.com/users/csyonghe","html_url":"https://github.com/csyonghe","followers_url":"https://api.github.com/users/csyonghe/followers","following_url":"https://api.github.com/users/csyonghe/following{/other_user}","gists_url":"https://api.github.com/users/csyonghe/gists{/gist_id}","starred_url":"https://api.github.com/users/csyonghe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/csyonghe/subscriptions","organizations_url":"https://api.github.com/users/csyonghe/orgs","repos_url":"https://api.github.com/users/csyonghe/repos","events_url":"https://api.github.com/users/csyonghe/events{/privacy}","received_events_url":"https://api.github.com/users/csyonghe/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/csyonghe/Spire","description":null,"fork":false,"url":"https://api.github.com/repos/csyonghe/Spire","forks_url":"https://api.github.com/repos/csyonghe/Spire/forks","keys_url":"https://api.github.com/repos/csyonghe/Spire/keys{/key_id}","collaborators_url":"https://api.github.com/repos/csyonghe/Spire/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/csyonghe/Spire/teams","hooks_url":"https://api.github.com/repos/csyonghe/Spire/hooks","issue_events_url":"https://api.github.com/repos/csyonghe/Spire/issues/events{/number}","events_url":"https://api.github.com/repos/csyonghe/Spire/events","assignees_url":"https://api.github.com/repos/csyonghe/Spire/assignees{/user}","branches_url":"https://api.github.com/repos/csyonghe/Spire/branches{/branch}","tags_url":"https://api.github.com/repos/csyonghe/Spire/tags","blobs_url":"https://api.github.com/repos/csyonghe/Spire/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/csyonghe/Spire/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/csyonghe/Spire/git/refs{/sha}","trees_url":"https://api.github.com/repos/csyonghe/Spire/git/trees{/sha}","statuses_url":"https://api.github.com/repos/csyonghe/Spire/statuses/{sha}","languages_url":"https://api.github.com/repos/csyonghe/Spire/languages","stargazers_url":"https://api.github.com/repos/csyonghe/Spire/stargazers","contributors_url":"https://api.github.com/repos/csyonghe/Spire/contributors","subscribers_url":"https://api.github.com/repos/csyonghe/Spire/subscribers","subscription_url":"https://api.github.com/repos/csyonghe/Spire/subscription","commits_url":"https://api.github.com/repos/csyonghe/Spire/commits{/sha}","git_commits_url":"https://api.github.com/repos/csyonghe/Spire/git/commits{/sha}","comments_url":"https://api.github.com/repos/csyonghe/Spire/comments{/number}","issue_comment_url":"https://api.github.com/repos/csyonghe/Spire/issues/comments{/number}","contents_url":"https://api.github.com/repos/csyonghe/Spire/contents/{+path}","compare_url":"https://api.github.com/repos/csyonghe/Spire/compare/{base}...{head}","merges_url":"https://api.github.com/repos/csyonghe/Spire/merges","archive_url":"https://api.github.com/repos/csyonghe/Spire/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/csyonghe/Spire/downloads","issues_url":"https://api.github.com/repos/csyonghe/Spire/issues{/number}","pulls_url":"https://api.github.com/repos/csyonghe/Spire/pulls{/number}","milestones_url":"https://api.github.com/repos/csyonghe/Spire/milestones{/number}","notifications_url":"https://api.github.com/repos/csyonghe/Spire/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/csyonghe/Spire/labels{/name}","releases_url":"https://api.github.com/repos/csyonghe/Spire/releases{/id}","deployments_url":"https://api.github.com/repos/csyonghe/Spire/deployments","created_at":"2016-05-28T23:11:37Z","updated_at":"2016-12-05T17:04:01Z","pushed_at":"2016-12-22T11:50:31Z","git_url":"git://github.com/csyonghe/Spire.git","ssh_url":"git@github.com:csyonghe/Spire.git","clone_url":"https://github.com/csyonghe/Spire.git","svn_url":"https://github.com/csyonghe/Spire","homepage":null,"size":494432,"stargazers_count":128,"watchers_count":128,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12,"mirror_url":null,"open_issues_count":20,"forks":12,"open_issues":20,"watchers":128,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/csyonghe/Spire/pulls/77"},"html":{"href":"https://github.com/csyonghe/Spire/pull/77"},"issue":{"href":"https://api.github.com/repos/csyonghe/Spire/issues/77"},"comments":{"href":"https://api.github.com/repos/csyonghe/Spire/issues/77/comments"},"review_comments":{"href":"https://api.github.com/repos/csyonghe/Spire/pulls/77/comments"},"review_comment":{"href":"https://api.github.com/repos/csyonghe/Spire/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/csyonghe/Spire/pulls/77/commits"},"statuses":{"href":"https://api.github.com/repos/csyonghe/Spire/statuses/bbc853e24675008d06cda80644a1e19b51b59ca2"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":4,"additions":867,"deletions":550,"changed_files":13}}
{"actor":{"display_login":"tfoleyNV"}}