{"action":"created","comment":{"url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/comments/133743522","pull_request_review_id":56950158,"id":133743522,"diff_hunk":"@@ -3175,26 +3176,23 @@ \\subsubsection{Function Declaration}\n \\subsection{Event Loop}\n \\label{subsec:eventloop}\n \n-\\dart{} supports asynchronous execution of code with async functions and await expressions.\n-We introduce an event loop to define the behaviour of asynchronous code.\n+\\dart{} supports asynchronous execution of code with async functions, await expressions, and asynchronous for-in loops.\n+We introduce an event loop component to represent Dart's event loop.\n We denote the event loop with $\\eventloop$.\n-$\\eventloop$ represents a list of event continuations, elements of $\\dncont$.\n+$\\eventloop$ is a list of event continuations, elements of $\\dncont$.\n \\[\n     \\eventloop \\in \\mlist{\\dncont}\n \\]\n \n The event loop is a list and it supports the operations defined in Section~\\ref{subsubsec:semantic-list}.\n \n-The event loop appears on the left and the right-hand side of all configurations, therefore we omit it from rules where the same queue just passed from one state to the other.\n-We assume it is implicit and we explicitly mention the cases when the event loop on the right-hand side is not the same as the one passed in the next state.\n-\n \\subsubsection{Async}\n \\label{subsubsec:async}\n \n-Asynchronous execution in \\dart{} is supported with async functions or asynchronous for in loops.\n-In \\kernel{} await is an expression and here we present the behaviour of invocation of asynchronous functions.\n-Asynchronous for-in loops occur as statements.\n-The semantics of the await expression in \\kernel{} for expressions other then the above mentioned does not modify the event loop.\n+Asynchronous execution in \\dart{} is supported with async functions, await expressions, and asynchronous for-in loops.\n+In \\kernel{} $\\AwaitExpression{}$ is an expression and here we present the behaviour of invocation of asynchronous functions.\n+Asynchronous \\synt{for in} loops occur as statements.","path":"documentation/kernel-semantics.tex","position":null,"original_position":61,"commit_id":"a08939645e6715ea9c498f767b503fa16f33589a","original_commit_id":"e26f1317dad3a721558a44b815e12b874466a828","user":{"login":"stefantsov","id":519320,"avatar_url":"https://avatars1.githubusercontent.com/u/519320?v=4","gravatar_id":"","url":"https://api.github.com/users/stefantsov","html_url":"https://github.com/stefantsov","followers_url":"https://api.github.com/users/stefantsov/followers","following_url":"https://api.github.com/users/stefantsov/following{/other_user}","gists_url":"https://api.github.com/users/stefantsov/gists{/gist_id}","starred_url":"https://api.github.com/users/stefantsov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stefantsov/subscriptions","organizations_url":"https://api.github.com/users/stefantsov/orgs","repos_url":"https://api.github.com/users/stefantsov/repos","events_url":"https://api.github.com/users/stefantsov/events{/privacy}","received_events_url":"https://api.github.com/users/stefantsov/received_events","type":"User","site_admin":false},"body":"There is a special macro defined for it: `$\\forin$` :)","created_at":"2017-08-17T15:17:12Z","updated_at":"2017-08-17T15:21:23Z","html_url":"https://github.com/zhivkag/dart-kernel-semantics/pull/18#discussion_r133743522","pull_request_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/18","_links":{"self":{"href":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/comments/133743522"},"html":{"href":"https://github.com/zhivkag/dart-kernel-semantics/pull/18#discussion_r133743522"},"pull_request":{"href":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/18"}}},"pull_request":{"url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/18","id":135578688,"html_url":"https://github.com/zhivkag/dart-kernel-semantics/pull/18","diff_url":"https://github.com/zhivkag/dart-kernel-semantics/pull/18.diff","patch_url":"https://github.com/zhivkag/dart-kernel-semantics/pull/18.patch","issue_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues/18","number":18,"state":"open","locked":false,"title":"Initial specification for Asyc","user":{"login":"zhivkag","id":26061341,"avatar_url":"https://avatars3.githubusercontent.com/u/26061341?v=4","gravatar_id":"","url":"https://api.github.com/users/zhivkag","html_url":"https://github.com/zhivkag","followers_url":"https://api.github.com/users/zhivkag/followers","following_url":"https://api.github.com/users/zhivkag/following{/other_user}","gists_url":"https://api.github.com/users/zhivkag/gists{/gist_id}","starred_url":"https://api.github.com/users/zhivkag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhivkag/subscriptions","organizations_url":"https://api.github.com/users/zhivkag/orgs","repos_url":"https://api.github.com/users/zhivkag/repos","events_url":"https://api.github.com/users/zhivkag/events{/privacy}","received_events_url":"https://api.github.com/users/zhivkag/received_events","type":"User","site_admin":false},"body":"This PR proposes an architecture for the evaluation of invocation of async functions and await expressions with an event loop and Futures.\r\n\r\nNote that:\r\n- These rules do not specify the behavior of `await for( ... )`, which occurs as a statement in Kernel.\r\n- Elements of the newly introduced domain of values, FutureValue, are not fully specified.\r\n- Rules for invocation of async function other then static invocation, while being analogous to the former, are not specified.\r\n\r\nException handlers should be updated as follows: \r\n- A new top level exception handler needs to be added, to handle the case when an exception is not handled by a try/catch in the event continuation.\r\n- Future is completed in the top level exception handler with the error and the stack trace and execution of the program continues normally.\r\n\r\nI am creating this change as a PR, since it is based on Dima's proposal for invocation of async static functions with await, but are not a direct transcription of the proposed rules, and I would like him to review it before we add it to the spec. \r\n","created_at":"2017-08-14T11:35:26Z","updated_at":"2017-08-17T15:21:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"55278020cd7af442737596640fefe1c7b7a0927b","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/18/commits","review_comments_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/18/comments","review_comment_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/comments{/number}","comments_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues/18/comments","statuses_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/statuses/a08939645e6715ea9c498f767b503fa16f33589a","head":{"label":"zhivkag:async","ref":"async","sha":"a08939645e6715ea9c498f767b503fa16f33589a","user":{"login":"zhivkag","id":26061341,"avatar_url":"https://avatars3.githubusercontent.com/u/26061341?v=4","gravatar_id":"","url":"https://api.github.com/users/zhivkag","html_url":"https://github.com/zhivkag","followers_url":"https://api.github.com/users/zhivkag/followers","following_url":"https://api.github.com/users/zhivkag/following{/other_user}","gists_url":"https://api.github.com/users/zhivkag/gists{/gist_id}","starred_url":"https://api.github.com/users/zhivkag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhivkag/subscriptions","organizations_url":"https://api.github.com/users/zhivkag/orgs","repos_url":"https://api.github.com/users/zhivkag/repos","events_url":"https://api.github.com/users/zhivkag/events{/privacy}","received_events_url":"https://api.github.com/users/zhivkag/received_events","type":"User","site_admin":false},"repo":{"id":93613107,"name":"dart-kernel-semantics","full_name":"zhivkag/dart-kernel-semantics","owner":{"login":"zhivkag","id":26061341,"avatar_url":"https://avatars3.githubusercontent.com/u/26061341?v=4","gravatar_id":"","url":"https://api.github.com/users/zhivkag","html_url":"https://github.com/zhivkag","followers_url":"https://api.github.com/users/zhivkag/followers","following_url":"https://api.github.com/users/zhivkag/following{/other_user}","gists_url":"https://api.github.com/users/zhivkag/gists{/gist_id}","starred_url":"https://api.github.com/users/zhivkag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhivkag/subscriptions","organizations_url":"https://api.github.com/users/zhivkag/orgs","repos_url":"https://api.github.com/users/zhivkag/repos","events_url":"https://api.github.com/users/zhivkag/events{/privacy}","received_events_url":"https://api.github.com/users/zhivkag/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/zhivkag/dart-kernel-semantics","description":null,"fork":false,"url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics","forks_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/forks","keys_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/teams","hooks_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/hooks","issue_events_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues/events{/number}","events_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/events","assignees_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/assignees{/user}","branches_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/branches{/branch}","tags_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/tags","blobs_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/refs{/sha}","trees_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/statuses/{sha}","languages_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/languages","stargazers_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/stargazers","contributors_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/contributors","subscribers_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/subscribers","subscription_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/subscription","commits_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/commits{/sha}","git_commits_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/commits{/sha}","comments_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/comments{/number}","issue_comment_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues/comments{/number}","contents_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/contents/{+path}","compare_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/merges","archive_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/downloads","issues_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues{/number}","pulls_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls{/number}","milestones_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/milestones{/number}","notifications_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/labels{/name}","releases_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/releases{/id}","deployments_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/deployments","created_at":"2017-06-07T08:46:27Z","updated_at":"2017-07-17T08:29:02Z","pushed_at":"2017-08-17T13:14:57Z","git_url":"git://github.com/zhivkag/dart-kernel-semantics.git","ssh_url":"git@github.com:zhivkag/dart-kernel-semantics.git","clone_url":"https://github.com/zhivkag/dart-kernel-semantics.git","svn_url":"https://github.com/zhivkag/dart-kernel-semantics","homepage":null,"size":1868,"stargazers_count":0,"watchers_count":0,"language":"Coq","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":3,"forks":0,"open_issues":3,"watchers":0,"default_branch":"master"}},"base":{"label":"zhivkag:master","ref":"master","sha":"e033f936c117f7a337c11cd100fd35c210df75cd","user":{"login":"zhivkag","id":26061341,"avatar_url":"https://avatars3.githubusercontent.com/u/26061341?v=4","gravatar_id":"","url":"https://api.github.com/users/zhivkag","html_url":"https://github.com/zhivkag","followers_url":"https://api.github.com/users/zhivkag/followers","following_url":"https://api.github.com/users/zhivkag/following{/other_user}","gists_url":"https://api.github.com/users/zhivkag/gists{/gist_id}","starred_url":"https://api.github.com/users/zhivkag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhivkag/subscriptions","organizations_url":"https://api.github.com/users/zhivkag/orgs","repos_url":"https://api.github.com/users/zhivkag/repos","events_url":"https://api.github.com/users/zhivkag/events{/privacy}","received_events_url":"https://api.github.com/users/zhivkag/received_events","type":"User","site_admin":false},"repo":{"id":93613107,"name":"dart-kernel-semantics","full_name":"zhivkag/dart-kernel-semantics","owner":{"login":"zhivkag","id":26061341,"avatar_url":"https://avatars3.githubusercontent.com/u/26061341?v=4","gravatar_id":"","url":"https://api.github.com/users/zhivkag","html_url":"https://github.com/zhivkag","followers_url":"https://api.github.com/users/zhivkag/followers","following_url":"https://api.github.com/users/zhivkag/following{/other_user}","gists_url":"https://api.github.com/users/zhivkag/gists{/gist_id}","starred_url":"https://api.github.com/users/zhivkag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhivkag/subscriptions","organizations_url":"https://api.github.com/users/zhivkag/orgs","repos_url":"https://api.github.com/users/zhivkag/repos","events_url":"https://api.github.com/users/zhivkag/events{/privacy}","received_events_url":"https://api.github.com/users/zhivkag/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/zhivkag/dart-kernel-semantics","description":null,"fork":false,"url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics","forks_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/forks","keys_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/teams","hooks_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/hooks","issue_events_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues/events{/number}","events_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/events","assignees_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/assignees{/user}","branches_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/branches{/branch}","tags_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/tags","blobs_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/refs{/sha}","trees_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/statuses/{sha}","languages_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/languages","stargazers_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/stargazers","contributors_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/contributors","subscribers_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/subscribers","subscription_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/subscription","commits_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/commits{/sha}","git_commits_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/git/commits{/sha}","comments_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/comments{/number}","issue_comment_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues/comments{/number}","contents_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/contents/{+path}","compare_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/merges","archive_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/downloads","issues_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues{/number}","pulls_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls{/number}","milestones_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/milestones{/number}","notifications_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/labels{/name}","releases_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/releases{/id}","deployments_url":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/deployments","created_at":"2017-06-07T08:46:27Z","updated_at":"2017-07-17T08:29:02Z","pushed_at":"2017-08-17T13:14:57Z","git_url":"git://github.com/zhivkag/dart-kernel-semantics.git","ssh_url":"git@github.com:zhivkag/dart-kernel-semantics.git","clone_url":"https://github.com/zhivkag/dart-kernel-semantics.git","svn_url":"https://github.com/zhivkag/dart-kernel-semantics","homepage":null,"size":1868,"stargazers_count":0,"watchers_count":0,"language":"Coq","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":3,"forks":0,"open_issues":3,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/18"},"html":{"href":"https://github.com/zhivkag/dart-kernel-semantics/pull/18"},"issue":{"href":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues/18"},"comments":{"href":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/issues/18/comments"},"review_comments":{"href":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/18/comments"},"review_comment":{"href":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/pulls/18/commits"},"statuses":{"href":"https://api.github.com/repos/zhivkag/dart-kernel-semantics/statuses/a08939645e6715ea9c498f767b503fa16f33589a"}}}}
{"actor":{"display_login":"stefantsov"}}