{"action":"created","comment":{"url":"https://api.github.com/repos/rust-lang/rust/pulls/comments/41253227","id":41253227,"diff_hunk":"@@ -1,9 +1,10 @@\n % Closures\n \n-Rust not only has named functions, but anonymous functions as well. Anonymous\n-functions that have an associated environment are called ‘closures’, because they\n-close over an environment. Rust has a really great implementation of them, as\n-we’ll see.\n+Sometimes it is useful to wrap up a function and free variables for better\n+clarity and reuse. The _free variables_ that can be used come from the\n+enclosing scope and are \"closed over\" when used in the function. From this, we","path":"src/doc/trpl/closures.md","position":9,"original_position":9,"commit_id":"a78a874ebb8c3348f2e1cb7a687636ab26a85a1c","original_commit_id":"a78a874ebb8c3348f2e1cb7a687636ab26a85a1c","user":{"login":"steveklabnik","id":27786,"avatar_url":"https://avatars.githubusercontent.com/u/27786?v=3","gravatar_id":"","url":"https://api.github.com/users/steveklabnik","html_url":"https://github.com/steveklabnik","followers_url":"https://api.github.com/users/steveklabnik/followers","following_url":"https://api.github.com/users/steveklabnik/following{/other_user}","gists_url":"https://api.github.com/users/steveklabnik/gists{/gist_id}","starred_url":"https://api.github.com/users/steveklabnik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/steveklabnik/subscriptions","organizations_url":"https://api.github.com/users/steveklabnik/orgs","repos_url":"https://api.github.com/users/steveklabnik/repos","events_url":"https://api.github.com/users/steveklabnik/events{/privacy}","received_events_url":"https://api.github.com/users/steveklabnik/received_events","type":"User","site_admin":false},"body":"these should be single, curly quotes, not double straight quotes","created_at":"2015-10-06T11:38:53Z","updated_at":"2015-10-06T11:38:53Z","html_url":"https://github.com/rust-lang/rust/pull/28856#discussion_r41253227","pull_request_url":"https://api.github.com/repos/rust-lang/rust/pulls/28856","_links":{"self":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/comments/41253227"},"html":{"href":"https://github.com/rust-lang/rust/pull/28856#discussion_r41253227"},"pull_request":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/28856"}}},"pull_request":{"url":"https://api.github.com/repos/rust-lang/rust/pulls/28856","id":46856624,"html_url":"https://github.com/rust-lang/rust/pull/28856","diff_url":"https://github.com/rust-lang/rust/pull/28856.diff","patch_url":"https://github.com/rust-lang/rust/pull/28856.patch","issue_url":"https://api.github.com/repos/rust-lang/rust/issues/28856","number":28856,"state":"open","locked":false,"title":"trpl: Clarify closure terminology","user":{"login":"chills42","id":800409,"avatar_url":"https://avatars.githubusercontent.com/u/800409?v=3","gravatar_id":"","url":"https://api.github.com/users/chills42","html_url":"https://github.com/chills42","followers_url":"https://api.github.com/users/chills42/followers","following_url":"https://api.github.com/users/chills42/following{/other_user}","gists_url":"https://api.github.com/users/chills42/gists{/gist_id}","starred_url":"https://api.github.com/users/chills42/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chills42/subscriptions","organizations_url":"https://api.github.com/users/chills42/orgs","repos_url":"https://api.github.com/users/chills42/repos","events_url":"https://api.github.com/users/chills42/events{/privacy}","received_events_url":"https://api.github.com/users/chills42/received_events","type":"User","site_admin":false},"body":"This is to address issue #28803 by improving some of the references to closures, to explain what they are more clearly, while hopefully still being concise.\r\n\r\nr? @steveklabnik","created_at":"2015-10-06T02:28:24Z","updated_at":"2015-10-06T11:38:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2496c7efdf75eb26569037c273df7e643b63eb27","assignee":{"login":"steveklabnik","id":27786,"avatar_url":"https://avatars.githubusercontent.com/u/27786?v=3","gravatar_id":"","url":"https://api.github.com/users/steveklabnik","html_url":"https://github.com/steveklabnik","followers_url":"https://api.github.com/users/steveklabnik/followers","following_url":"https://api.github.com/users/steveklabnik/following{/other_user}","gists_url":"https://api.github.com/users/steveklabnik/gists{/gist_id}","starred_url":"https://api.github.com/users/steveklabnik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/steveklabnik/subscriptions","organizations_url":"https://api.github.com/users/steveklabnik/orgs","repos_url":"https://api.github.com/users/steveklabnik/repos","events_url":"https://api.github.com/users/steveklabnik/events{/privacy}","received_events_url":"https://api.github.com/users/steveklabnik/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/rust-lang/rust/pulls/28856/commits","review_comments_url":"https://api.github.com/repos/rust-lang/rust/pulls/28856/comments","review_comment_url":"https://api.github.com/repos/rust-lang/rust/pulls/comments{/number}","comments_url":"https://api.github.com/repos/rust-lang/rust/issues/28856/comments","statuses_url":"https://api.github.com/repos/rust-lang/rust/statuses/a78a874ebb8c3348f2e1cb7a687636ab26a85a1c","head":{"label":"chills42:master","ref":"master","sha":"a78a874ebb8c3348f2e1cb7a687636ab26a85a1c","user":{"login":"chills42","id":800409,"avatar_url":"https://avatars.githubusercontent.com/u/800409?v=3","gravatar_id":"","url":"https://api.github.com/users/chills42","html_url":"https://github.com/chills42","followers_url":"https://api.github.com/users/chills42/followers","following_url":"https://api.github.com/users/chills42/following{/other_user}","gists_url":"https://api.github.com/users/chills42/gists{/gist_id}","starred_url":"https://api.github.com/users/chills42/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chills42/subscriptions","organizations_url":"https://api.github.com/users/chills42/orgs","repos_url":"https://api.github.com/users/chills42/repos","events_url":"https://api.github.com/users/chills42/events{/privacy}","received_events_url":"https://api.github.com/users/chills42/received_events","type":"User","site_admin":false},"repo":{"id":43725598,"name":"rust","full_name":"chills42/rust","owner":{"login":"chills42","id":800409,"avatar_url":"https://avatars.githubusercontent.com/u/800409?v=3","gravatar_id":"","url":"https://api.github.com/users/chills42","html_url":"https://github.com/chills42","followers_url":"https://api.github.com/users/chills42/followers","following_url":"https://api.github.com/users/chills42/following{/other_user}","gists_url":"https://api.github.com/users/chills42/gists{/gist_id}","starred_url":"https://api.github.com/users/chills42/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chills42/subscriptions","organizations_url":"https://api.github.com/users/chills42/orgs","repos_url":"https://api.github.com/users/chills42/repos","events_url":"https://api.github.com/users/chills42/events{/privacy}","received_events_url":"https://api.github.com/users/chills42/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/chills42/rust","description":"A safe, concurrent, practical language.","fork":true,"url":"https://api.github.com/repos/chills42/rust","forks_url":"https://api.github.com/repos/chills42/rust/forks","keys_url":"https://api.github.com/repos/chills42/rust/keys{/key_id}","collaborators_url":"https://api.github.com/repos/chills42/rust/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/chills42/rust/teams","hooks_url":"https://api.github.com/repos/chills42/rust/hooks","issue_events_url":"https://api.github.com/repos/chills42/rust/issues/events{/number}","events_url":"https://api.github.com/repos/chills42/rust/events","assignees_url":"https://api.github.com/repos/chills42/rust/assignees{/user}","branches_url":"https://api.github.com/repos/chills42/rust/branches{/branch}","tags_url":"https://api.github.com/repos/chills42/rust/tags","blobs_url":"https://api.github.com/repos/chills42/rust/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/chills42/rust/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/chills42/rust/git/refs{/sha}","trees_url":"https://api.github.com/repos/chills42/rust/git/trees{/sha}","statuses_url":"https://api.github.com/repos/chills42/rust/statuses/{sha}","languages_url":"https://api.github.com/repos/chills42/rust/languages","stargazers_url":"https://api.github.com/repos/chills42/rust/stargazers","contributors_url":"https://api.github.com/repos/chills42/rust/contributors","subscribers_url":"https://api.github.com/repos/chills42/rust/subscribers","subscription_url":"https://api.github.com/repos/chills42/rust/subscription","commits_url":"https://api.github.com/repos/chills42/rust/commits{/sha}","git_commits_url":"https://api.github.com/repos/chills42/rust/git/commits{/sha}","comments_url":"https://api.github.com/repos/chills42/rust/comments{/number}","issue_comment_url":"https://api.github.com/repos/chills42/rust/issues/comments{/number}","contents_url":"https://api.github.com/repos/chills42/rust/contents/{+path}","compare_url":"https://api.github.com/repos/chills42/rust/compare/{base}...{head}","merges_url":"https://api.github.com/repos/chills42/rust/merges","archive_url":"https://api.github.com/repos/chills42/rust/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/chills42/rust/downloads","issues_url":"https://api.github.com/repos/chills42/rust/issues{/number}","pulls_url":"https://api.github.com/repos/chills42/rust/pulls{/number}","milestones_url":"https://api.github.com/repos/chills42/rust/milestones{/number}","notifications_url":"https://api.github.com/repos/chills42/rust/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/chills42/rust/labels{/name}","releases_url":"https://api.github.com/repos/chills42/rust/releases{/id}","created_at":"2015-10-06T02:19:03Z","updated_at":"2015-10-06T02:19:54Z","pushed_at":"2015-10-06T02:32:54Z","git_url":"git://github.com/chills42/rust.git","ssh_url":"git@github.com:chills42/rust.git","clone_url":"https://github.com/chills42/rust.git","svn_url":"https://github.com/chills42/rust","homepage":"http://www.rust-lang.org","size":322463,"stargazers_count":0,"watchers_count":0,"language":"Rust","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"rust-lang:master","ref":"master","sha":"32a8567ea4ded47ac4cfd39bc808bb8d6f2e119c","user":{"login":"rust-lang","id":5430905,"avatar_url":"https://avatars.githubusercontent.com/u/5430905?v=3","gravatar_id":"","url":"https://api.github.com/users/rust-lang","html_url":"https://github.com/rust-lang","followers_url":"https://api.github.com/users/rust-lang/followers","following_url":"https://api.github.com/users/rust-lang/following{/other_user}","gists_url":"https://api.github.com/users/rust-lang/gists{/gist_id}","starred_url":"https://api.github.com/users/rust-lang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rust-lang/subscriptions","organizations_url":"https://api.github.com/users/rust-lang/orgs","repos_url":"https://api.github.com/users/rust-lang/repos","events_url":"https://api.github.com/users/rust-lang/events{/privacy}","received_events_url":"https://api.github.com/users/rust-lang/received_events","type":"Organization","site_admin":false},"repo":{"id":724712,"name":"rust","full_name":"rust-lang/rust","owner":{"login":"rust-lang","id":5430905,"avatar_url":"https://avatars.githubusercontent.com/u/5430905?v=3","gravatar_id":"","url":"https://api.github.com/users/rust-lang","html_url":"https://github.com/rust-lang","followers_url":"https://api.github.com/users/rust-lang/followers","following_url":"https://api.github.com/users/rust-lang/following{/other_user}","gists_url":"https://api.github.com/users/rust-lang/gists{/gist_id}","starred_url":"https://api.github.com/users/rust-lang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rust-lang/subscriptions","organizations_url":"https://api.github.com/users/rust-lang/orgs","repos_url":"https://api.github.com/users/rust-lang/repos","events_url":"https://api.github.com/users/rust-lang/events{/privacy}","received_events_url":"https://api.github.com/users/rust-lang/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/rust-lang/rust","description":"A safe, concurrent, practical language.","fork":false,"url":"https://api.github.com/repos/rust-lang/rust","forks_url":"https://api.github.com/repos/rust-lang/rust/forks","keys_url":"https://api.github.com/repos/rust-lang/rust/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rust-lang/rust/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rust-lang/rust/teams","hooks_url":"https://api.github.com/repos/rust-lang/rust/hooks","issue_events_url":"https://api.github.com/repos/rust-lang/rust/issues/events{/number}","events_url":"https://api.github.com/repos/rust-lang/rust/events","assignees_url":"https://api.github.com/repos/rust-lang/rust/assignees{/user}","branches_url":"https://api.github.com/repos/rust-lang/rust/branches{/branch}","tags_url":"https://api.github.com/repos/rust-lang/rust/tags","blobs_url":"https://api.github.com/repos/rust-lang/rust/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rust-lang/rust/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rust-lang/rust/git/refs{/sha}","trees_url":"https://api.github.com/repos/rust-lang/rust/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rust-lang/rust/statuses/{sha}","languages_url":"https://api.github.com/repos/rust-lang/rust/languages","stargazers_url":"https://api.github.com/repos/rust-lang/rust/stargazers","contributors_url":"https://api.github.com/repos/rust-lang/rust/contributors","subscribers_url":"https://api.github.com/repos/rust-lang/rust/subscribers","subscription_url":"https://api.github.com/repos/rust-lang/rust/subscription","commits_url":"https://api.github.com/repos/rust-lang/rust/commits{/sha}","git_commits_url":"https://api.github.com/repos/rust-lang/rust/git/commits{/sha}","comments_url":"https://api.github.com/repos/rust-lang/rust/comments{/number}","issue_comment_url":"https://api.github.com/repos/rust-lang/rust/issues/comments{/number}","contents_url":"https://api.github.com/repos/rust-lang/rust/contents/{+path}","compare_url":"https://api.github.com/repos/rust-lang/rust/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rust-lang/rust/merges","archive_url":"https://api.github.com/repos/rust-lang/rust/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rust-lang/rust/downloads","issues_url":"https://api.github.com/repos/rust-lang/rust/issues{/number}","pulls_url":"https://api.github.com/repos/rust-lang/rust/pulls{/number}","milestones_url":"https://api.github.com/repos/rust-lang/rust/milestones{/number}","notifications_url":"https://api.github.com/repos/rust-lang/rust/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rust-lang/rust/labels{/name}","releases_url":"https://api.github.com/repos/rust-lang/rust/releases{/id}","created_at":"2010-06-16T20:39:03Z","updated_at":"2015-10-06T08:20:43Z","pushed_at":"2015-10-06T10:37:03Z","git_url":"git://github.com/rust-lang/rust.git","ssh_url":"git@github.com:rust-lang/rust.git","clone_url":"https://github.com/rust-lang/rust.git","svn_url":"https://github.com/rust-lang/rust","homepage":"http://www.rust-lang.org","size":690599,"stargazers_count":13685,"watchers_count":13685,"language":"Rust","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2650,"mirror_url":null,"open_issues_count":2236,"forks":2650,"open_issues":2236,"watchers":13685,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/28856"},"html":{"href":"https://github.com/rust-lang/rust/pull/28856"},"issue":{"href":"https://api.github.com/repos/rust-lang/rust/issues/28856"},"comments":{"href":"https://api.github.com/repos/rust-lang/rust/issues/28856/comments"},"review_comments":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/28856/comments"},"review_comment":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/rust-lang/rust/pulls/28856/commits"},"statuses":{"href":"https://api.github.com/repos/rust-lang/rust/statuses/a78a874ebb8c3348f2e1cb7a687636ab26a85a1c"}}}}