{"action":"created","comment":{"url":"https://api.github.com/repos/bluss/rust-itertools/pulls/comments/47600844","id":47600844,"diff_hunk":"@@ -1236,6 +1236,58 @@ pub trait Itertools : Iterator {\n     {\n         self.sorted_by(cmp)\n     }\n+\n+    /// Return the minimum and maximum element of an iterator.\n+    ///\n+    /// For the minimum, the first minimal element is returned.  For the maximum,\n+    /// the last maximal element wins.  This matches the behavior of the standard\n+    /// `Iterator::min()` and `Iterator::max()` methods.\n+    ///\n+    /// This requires `clone()`-able elements since the returned minimum and\n+    /// maximum might actually be the same item.","path":"src/lib.rs","position":12,"original_position":12,"commit_id":"93323d58968d9e5a6bae64f3a052b7cfe79a39ec","original_commit_id":"93323d58968d9e5a6bae64f3a052b7cfe79a39ec","user":{"login":"birkenfeld","id":144359,"avatar_url":"https://avatars.githubusercontent.com/u/144359?v=3","gravatar_id":"","url":"https://api.github.com/users/birkenfeld","html_url":"https://github.com/birkenfeld","followers_url":"https://api.github.com/users/birkenfeld/followers","following_url":"https://api.github.com/users/birkenfeld/following{/other_user}","gists_url":"https://api.github.com/users/birkenfeld/gists{/gist_id}","starred_url":"https://api.github.com/users/birkenfeld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/birkenfeld/subscriptions","organizations_url":"https://api.github.com/users/birkenfeld/orgs","repos_url":"https://api.github.com/users/birkenfeld/repos","events_url":"https://api.github.com/users/birkenfeld/events{/privacy}","received_events_url":"https://api.github.com/users/birkenfeld/received_events","type":"User","site_admin":false},"body":"Oh wow, didn't even know this existed in std. Well then, let's copy it shamelessly :)","created_at":"2015-12-15T06:34:13Z","updated_at":"2015-12-15T06:34:13Z","html_url":"https://github.com/bluss/rust-itertools/pull/80#discussion_r47600844","pull_request_url":"https://api.github.com/repos/bluss/rust-itertools/pulls/80","_links":{"self":{"href":"https://api.github.com/repos/bluss/rust-itertools/pulls/comments/47600844"},"html":{"href":"https://github.com/bluss/rust-itertools/pull/80#discussion_r47600844"},"pull_request":{"href":"https://api.github.com/repos/bluss/rust-itertools/pulls/80"}}},"pull_request":{"url":"https://api.github.com/repos/bluss/rust-itertools/pulls/80","id":53599092,"html_url":"https://github.com/bluss/rust-itertools/pull/80","diff_url":"https://github.com/bluss/rust-itertools/pull/80.diff","patch_url":"https://github.com/bluss/rust-itertools/pull/80.patch","issue_url":"https://api.github.com/repos/bluss/rust-itertools/issues/80","number":80,"state":"open","locked":false,"title":"Add minmax() and minmax_by_key() adapters (#79)","user":{"login":"birkenfeld","id":144359,"avatar_url":"https://avatars.githubusercontent.com/u/144359?v=3","gravatar_id":"","url":"https://api.github.com/users/birkenfeld","html_url":"https://github.com/birkenfeld","followers_url":"https://api.github.com/users/birkenfeld/followers","following_url":"https://api.github.com/users/birkenfeld/following{/other_user}","gists_url":"https://api.github.com/users/birkenfeld/gists{/gist_id}","starred_url":"https://api.github.com/users/birkenfeld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/birkenfeld/subscriptions","organizations_url":"https://api.github.com/users/birkenfeld/orgs","repos_url":"https://api.github.com/users/birkenfeld/repos","events_url":"https://api.github.com/users/birkenfeld/events{/privacy}","received_events_url":"https://api.github.com/users/birkenfeld/received_events","type":"User","site_admin":false},"body":"The Clone bound on Self::Item is pretty obvious in hindsight, but\r\nI didn't think of it when starting the implementation.  It is also\r\nthe reason for the slightly complicated fold() closure.","created_at":"2015-12-14T17:57:57Z","updated_at":"2015-12-15T06:34:13Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ffafadc23f9c46d02d1c7302075cf47da9aad3e8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/bluss/rust-itertools/pulls/80/commits","review_comments_url":"https://api.github.com/repos/bluss/rust-itertools/pulls/80/comments","review_comment_url":"https://api.github.com/repos/bluss/rust-itertools/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bluss/rust-itertools/issues/80/comments","statuses_url":"https://api.github.com/repos/bluss/rust-itertools/statuses/93323d58968d9e5a6bae64f3a052b7cfe79a39ec","head":{"label":"birkenfeld:minmax","ref":"minmax","sha":"93323d58968d9e5a6bae64f3a052b7cfe79a39ec","user":{"login":"birkenfeld","id":144359,"avatar_url":"https://avatars.githubusercontent.com/u/144359?v=3","gravatar_id":"","url":"https://api.github.com/users/birkenfeld","html_url":"https://github.com/birkenfeld","followers_url":"https://api.github.com/users/birkenfeld/followers","following_url":"https://api.github.com/users/birkenfeld/following{/other_user}","gists_url":"https://api.github.com/users/birkenfeld/gists{/gist_id}","starred_url":"https://api.github.com/users/birkenfeld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/birkenfeld/subscriptions","organizations_url":"https://api.github.com/users/birkenfeld/orgs","repos_url":"https://api.github.com/users/birkenfeld/repos","events_url":"https://api.github.com/users/birkenfeld/events{/privacy}","received_events_url":"https://api.github.com/users/birkenfeld/received_events","type":"User","site_admin":false},"repo":{"id":47989099,"name":"rust-itertools","full_name":"birkenfeld/rust-itertools","owner":{"login":"birkenfeld","id":144359,"avatar_url":"https://avatars.githubusercontent.com/u/144359?v=3","gravatar_id":"","url":"https://api.github.com/users/birkenfeld","html_url":"https://github.com/birkenfeld","followers_url":"https://api.github.com/users/birkenfeld/followers","following_url":"https://api.github.com/users/birkenfeld/following{/other_user}","gists_url":"https://api.github.com/users/birkenfeld/gists{/gist_id}","starred_url":"https://api.github.com/users/birkenfeld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/birkenfeld/subscriptions","organizations_url":"https://api.github.com/users/birkenfeld/orgs","repos_url":"https://api.github.com/users/birkenfeld/repos","events_url":"https://api.github.com/users/birkenfeld/events{/privacy}","received_events_url":"https://api.github.com/users/birkenfeld/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/birkenfeld/rust-itertools","description":"","fork":true,"url":"https://api.github.com/repos/birkenfeld/rust-itertools","forks_url":"https://api.github.com/repos/birkenfeld/rust-itertools/forks","keys_url":"https://api.github.com/repos/birkenfeld/rust-itertools/keys{/key_id}","collaborators_url":"https://api.github.com/repos/birkenfeld/rust-itertools/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/birkenfeld/rust-itertools/teams","hooks_url":"https://api.github.com/repos/birkenfeld/rust-itertools/hooks","issue_events_url":"https://api.github.com/repos/birkenfeld/rust-itertools/issues/events{/number}","events_url":"https://api.github.com/repos/birkenfeld/rust-itertools/events","assignees_url":"https://api.github.com/repos/birkenfeld/rust-itertools/assignees{/user}","branches_url":"https://api.github.com/repos/birkenfeld/rust-itertools/branches{/branch}","tags_url":"https://api.github.com/repos/birkenfeld/rust-itertools/tags","blobs_url":"https://api.github.com/repos/birkenfeld/rust-itertools/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/birkenfeld/rust-itertools/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/birkenfeld/rust-itertools/git/refs{/sha}","trees_url":"https://api.github.com/repos/birkenfeld/rust-itertools/git/trees{/sha}","statuses_url":"https://api.github.com/repos/birkenfeld/rust-itertools/statuses/{sha}","languages_url":"https://api.github.com/repos/birkenfeld/rust-itertools/languages","stargazers_url":"https://api.github.com/repos/birkenfeld/rust-itertools/stargazers","contributors_url":"https://api.github.com/repos/birkenfeld/rust-itertools/contributors","subscribers_url":"https://api.github.com/repos/birkenfeld/rust-itertools/subscribers","subscription_url":"https://api.github.com/repos/birkenfeld/rust-itertools/subscription","commits_url":"https://api.github.com/repos/birkenfeld/rust-itertools/commits{/sha}","git_commits_url":"https://api.github.com/repos/birkenfeld/rust-itertools/git/commits{/sha}","comments_url":"https://api.github.com/repos/birkenfeld/rust-itertools/comments{/number}","issue_comment_url":"https://api.github.com/repos/birkenfeld/rust-itertools/issues/comments{/number}","contents_url":"https://api.github.com/repos/birkenfeld/rust-itertools/contents/{+path}","compare_url":"https://api.github.com/repos/birkenfeld/rust-itertools/compare/{base}...{head}","merges_url":"https://api.github.com/repos/birkenfeld/rust-itertools/merges","archive_url":"https://api.github.com/repos/birkenfeld/rust-itertools/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/birkenfeld/rust-itertools/downloads","issues_url":"https://api.github.com/repos/birkenfeld/rust-itertools/issues{/number}","pulls_url":"https://api.github.com/repos/birkenfeld/rust-itertools/pulls{/number}","milestones_url":"https://api.github.com/repos/birkenfeld/rust-itertools/milestones{/number}","notifications_url":"https://api.github.com/repos/birkenfeld/rust-itertools/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/birkenfeld/rust-itertools/labels{/name}","releases_url":"https://api.github.com/repos/birkenfeld/rust-itertools/releases{/id}","created_at":"2015-12-14T17:03:07Z","updated_at":"2015-12-14T17:03:07Z","pushed_at":"2015-12-14T17:56:39Z","git_url":"git://github.com/birkenfeld/rust-itertools.git","ssh_url":"git@github.com:birkenfeld/rust-itertools.git","clone_url":"https://github.com/birkenfeld/rust-itertools.git","svn_url":"https://github.com/birkenfeld/rust-itertools","homepage":"http://bluss.github.io/rust-itertools/","size":4553,"stargazers_count":0,"watchers_count":0,"language":"Rust","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"bluss:master","ref":"master","sha":"b019ff3ef70fd9200adbf3ac2c21675943e999e0","user":{"login":"bluss","id":3209739,"avatar_url":"https://avatars.githubusercontent.com/u/3209739?v=3","gravatar_id":"","url":"https://api.github.com/users/bluss","html_url":"https://github.com/bluss","followers_url":"https://api.github.com/users/bluss/followers","following_url":"https://api.github.com/users/bluss/following{/other_user}","gists_url":"https://api.github.com/users/bluss/gists{/gist_id}","starred_url":"https://api.github.com/users/bluss/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bluss/subscriptions","organizations_url":"https://api.github.com/users/bluss/orgs","repos_url":"https://api.github.com/users/bluss/repos","events_url":"https://api.github.com/users/bluss/events{/privacy}","received_events_url":"https://api.github.com/users/bluss/received_events","type":"User","site_admin":false},"repo":{"id":22360263,"name":"rust-itertools","full_name":"bluss/rust-itertools","owner":{"login":"bluss","id":3209739,"avatar_url":"https://avatars.githubusercontent.com/u/3209739?v=3","gravatar_id":"","url":"https://api.github.com/users/bluss","html_url":"https://github.com/bluss","followers_url":"https://api.github.com/users/bluss/followers","following_url":"https://api.github.com/users/bluss/following{/other_user}","gists_url":"https://api.github.com/users/bluss/gists{/gist_id}","starred_url":"https://api.github.com/users/bluss/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bluss/subscriptions","organizations_url":"https://api.github.com/users/bluss/orgs","repos_url":"https://api.github.com/users/bluss/repos","events_url":"https://api.github.com/users/bluss/events{/privacy}","received_events_url":"https://api.github.com/users/bluss/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bluss/rust-itertools","description":"","fork":false,"url":"https://api.github.com/repos/bluss/rust-itertools","forks_url":"https://api.github.com/repos/bluss/rust-itertools/forks","keys_url":"https://api.github.com/repos/bluss/rust-itertools/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bluss/rust-itertools/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bluss/rust-itertools/teams","hooks_url":"https://api.github.com/repos/bluss/rust-itertools/hooks","issue_events_url":"https://api.github.com/repos/bluss/rust-itertools/issues/events{/number}","events_url":"https://api.github.com/repos/bluss/rust-itertools/events","assignees_url":"https://api.github.com/repos/bluss/rust-itertools/assignees{/user}","branches_url":"https://api.github.com/repos/bluss/rust-itertools/branches{/branch}","tags_url":"https://api.github.com/repos/bluss/rust-itertools/tags","blobs_url":"https://api.github.com/repos/bluss/rust-itertools/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bluss/rust-itertools/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bluss/rust-itertools/git/refs{/sha}","trees_url":"https://api.github.com/repos/bluss/rust-itertools/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bluss/rust-itertools/statuses/{sha}","languages_url":"https://api.github.com/repos/bluss/rust-itertools/languages","stargazers_url":"https://api.github.com/repos/bluss/rust-itertools/stargazers","contributors_url":"https://api.github.com/repos/bluss/rust-itertools/contributors","subscribers_url":"https://api.github.com/repos/bluss/rust-itertools/subscribers","subscription_url":"https://api.github.com/repos/bluss/rust-itertools/subscription","commits_url":"https://api.github.com/repos/bluss/rust-itertools/commits{/sha}","git_commits_url":"https://api.github.com/repos/bluss/rust-itertools/git/commits{/sha}","comments_url":"https://api.github.com/repos/bluss/rust-itertools/comments{/number}","issue_comment_url":"https://api.github.com/repos/bluss/rust-itertools/issues/comments{/number}","contents_url":"https://api.github.com/repos/bluss/rust-itertools/contents/{+path}","compare_url":"https://api.github.com/repos/bluss/rust-itertools/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bluss/rust-itertools/merges","archive_url":"https://api.github.com/repos/bluss/rust-itertools/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bluss/rust-itertools/downloads","issues_url":"https://api.github.com/repos/bluss/rust-itertools/issues{/number}","pulls_url":"https://api.github.com/repos/bluss/rust-itertools/pulls{/number}","milestones_url":"https://api.github.com/repos/bluss/rust-itertools/milestones{/number}","notifications_url":"https://api.github.com/repos/bluss/rust-itertools/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bluss/rust-itertools/labels{/name}","releases_url":"https://api.github.com/repos/bluss/rust-itertools/releases{/id}","created_at":"2014-07-28T22:34:37Z","updated_at":"2015-12-15T01:19:07Z","pushed_at":"2015-12-14T21:48:14Z","git_url":"git://github.com/bluss/rust-itertools.git","ssh_url":"git@github.com:bluss/rust-itertools.git","clone_url":"https://github.com/bluss/rust-itertools.git","svn_url":"https://github.com/bluss/rust-itertools","homepage":"http://bluss.github.io/rust-itertools/","size":4635,"stargazers_count":98,"watchers_count":98,"language":"Rust","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":29,"mirror_url":null,"open_issues_count":16,"forks":29,"open_issues":16,"watchers":98,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bluss/rust-itertools/pulls/80"},"html":{"href":"https://github.com/bluss/rust-itertools/pull/80"},"issue":{"href":"https://api.github.com/repos/bluss/rust-itertools/issues/80"},"comments":{"href":"https://api.github.com/repos/bluss/rust-itertools/issues/80/comments"},"review_comments":{"href":"https://api.github.com/repos/bluss/rust-itertools/pulls/80/comments"},"review_comment":{"href":"https://api.github.com/repos/bluss/rust-itertools/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bluss/rust-itertools/pulls/80/commits"},"statuses":{"href":"https://api.github.com/repos/bluss/rust-itertools/statuses/93323d58968d9e5a6bae64f3a052b7cfe79a39ec"}}}}