{"action":"created","comment":{"url":"https://api.github.com/repos/ramda/ramda/pulls/comments/53555792","id":53555792,"diff_hunk":"@@ -1,30 +1,29 @@\n-var _curry2 = require('./internal/_curry2');\n-var _reduce = require('./internal/_reduce');\n+var filter = require('./filter');\n+var juxt = require('./juxt');\n+var reject = require('./reject');\n \n \n /**\n- * Takes a predicate and a list and returns the pair of lists of elements which\n- * do and do not satisfy the predicate, respectively.\n+ * Takes a predicate and a list or other \"filterable\" object and returns the\n+ * pair of filterable objects of the same type of elements which do and do not\n+ * satisfy, the predicate, respectively.\n  *\n  * @func\n  * @memberOf R\n  * @since v0.1.4\n  * @category List\n- * @sig (a -> Boolean) -> [a] -> [[a],[a]]\n- * @param {Function} pred A predicate to determine which array the element belongs to.\n- * @param {Array} list The array to partition.\n- * @return {Array} A nested array, containing first an array of elements that satisfied the predicate,\n- *         and second an array of elements that did not satisfy.\n+ * @sig Filterable f => (a -> Boolean) -> f -> [f,f]","path":"src/partition.js","position":24,"original_position":24,"commit_id":"b70ce7698583dc7af5f041fa4aa67be502dfba70","original_commit_id":"b70ce7698583dc7af5f041fa4aa67be502dfba70","user":{"login":"davidchambers","id":210406,"avatar_url":"https://avatars.githubusercontent.com/u/210406?v=3","gravatar_id":"","url":"https://api.github.com/users/davidchambers","html_url":"https://github.com/davidchambers","followers_url":"https://api.github.com/users/davidchambers/followers","following_url":"https://api.github.com/users/davidchambers/following{/other_user}","gists_url":"https://api.github.com/users/davidchambers/gists{/gist_id}","starred_url":"https://api.github.com/users/davidchambers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidchambers/subscriptions","organizations_url":"https://api.github.com/users/davidchambers/orgs","repos_url":"https://api.github.com/users/davidchambers/repos","events_url":"https://api.github.com/users/davidchambers/events{/privacy}","received_events_url":"https://api.github.com/users/davidchambers/received_events","type":"User","site_admin":false},"body":"We certainly want `f a`, as Scott suggested. It may be helpful to work backwards from a concrete type:\r\n\r\n```haskell\r\n(Number -> Boolean) -> Array Number -> Pair (Array Number) (Array Number)\r\n```\r\n\r\nReplace `Number` with `a`:\r\n\r\n```haskell\r\n(a -> Boolean) -> Array a -> Pair (Array a) (Array a)\r\n```\r\n\r\nReplace `Array` with `Filterable f => f`:\r\n\r\n```haskell\r\nFilterable f => (a -> Boolean) -> f a -> Pair (f a) (f a)\r\n```\r\n\r\nThe remaining question is how to represent a pair. I favour `Pair a b` as it's unambiguous, whereas `(a, b)` collides with our representation of binary functions and `[a, b]` reuses our array notation in a conflicting manner. I'm okay with `[f a, f a]`, though.\r\n","created_at":"2016-02-20T19:30:23Z","updated_at":"2016-02-20T19:30:23Z","html_url":"https://github.com/ramda/ramda/pull/1655#discussion_r53555792","pull_request_url":"https://api.github.com/repos/ramda/ramda/pulls/1655","_links":{"self":{"href":"https://api.github.com/repos/ramda/ramda/pulls/comments/53555792"},"html":{"href":"https://github.com/ramda/ramda/pull/1655#discussion_r53555792"},"pull_request":{"href":"https://api.github.com/repos/ramda/ramda/pulls/1655"}}},"pull_request":{"url":"https://api.github.com/repos/ramda/ramda/pulls/1655","id":60050099,"html_url":"https://github.com/ramda/ramda/pull/1655","diff_url":"https://github.com/ramda/ramda/pull/1655.diff","patch_url":"https://github.com/ramda/ramda/pull/1655.patch","issue_url":"https://api.github.com/repos/ramda/ramda/issues/1655","number":1655,"state":"open","locked":false,"title":"Implement partition in terms of filter and reject","user":{"login":"asaf-romano","id":11056617,"avatar_url":"https://avatars.githubusercontent.com/u/11056617?v=3","gravatar_id":"","url":"https://api.github.com/users/asaf-romano","html_url":"https://github.com/asaf-romano","followers_url":"https://api.github.com/users/asaf-romano/followers","following_url":"https://api.github.com/users/asaf-romano/following{/other_user}","gists_url":"https://api.github.com/users/asaf-romano/gists{/gist_id}","starred_url":"https://api.github.com/users/asaf-romano/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asaf-romano/subscriptions","organizations_url":"https://api.github.com/users/asaf-romano/orgs","repos_url":"https://api.github.com/users/asaf-romano/repos","events_url":"https://api.github.com/users/asaf-romano/events{/privacy}","received_events_url":"https://api.github.com/users/asaf-romano/received_events","type":"User","site_admin":false},"body":"Closes #1651","created_at":"2016-02-20T14:51:46Z","updated_at":"2016-02-20T19:30:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e392ba86b423a95b1ecb712200c12dbb39f6f955","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ramda/ramda/pulls/1655/commits","review_comments_url":"https://api.github.com/repos/ramda/ramda/pulls/1655/comments","review_comment_url":"https://api.github.com/repos/ramda/ramda/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ramda/ramda/issues/1655/comments","statuses_url":"https://api.github.com/repos/ramda/ramda/statuses/b70ce7698583dc7af5f041fa4aa67be502dfba70","head":{"label":"asaf-romano:partition-obj","ref":"partition-obj","sha":"b70ce7698583dc7af5f041fa4aa67be502dfba70","user":{"login":"asaf-romano","id":11056617,"avatar_url":"https://avatars.githubusercontent.com/u/11056617?v=3","gravatar_id":"","url":"https://api.github.com/users/asaf-romano","html_url":"https://github.com/asaf-romano","followers_url":"https://api.github.com/users/asaf-romano/followers","following_url":"https://api.github.com/users/asaf-romano/following{/other_user}","gists_url":"https://api.github.com/users/asaf-romano/gists{/gist_id}","starred_url":"https://api.github.com/users/asaf-romano/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asaf-romano/subscriptions","organizations_url":"https://api.github.com/users/asaf-romano/orgs","repos_url":"https://api.github.com/users/asaf-romano/repos","events_url":"https://api.github.com/users/asaf-romano/events{/privacy}","received_events_url":"https://api.github.com/users/asaf-romano/received_events","type":"User","site_admin":false},"repo":{"id":36490733,"name":"ramda","full_name":"asaf-romano/ramda","owner":{"login":"asaf-romano","id":11056617,"avatar_url":"https://avatars.githubusercontent.com/u/11056617?v=3","gravatar_id":"","url":"https://api.github.com/users/asaf-romano","html_url":"https://github.com/asaf-romano","followers_url":"https://api.github.com/users/asaf-romano/followers","following_url":"https://api.github.com/users/asaf-romano/following{/other_user}","gists_url":"https://api.github.com/users/asaf-romano/gists{/gist_id}","starred_url":"https://api.github.com/users/asaf-romano/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asaf-romano/subscriptions","organizations_url":"https://api.github.com/users/asaf-romano/orgs","repos_url":"https://api.github.com/users/asaf-romano/repos","events_url":"https://api.github.com/users/asaf-romano/events{/privacy}","received_events_url":"https://api.github.com/users/asaf-romano/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/asaf-romano/ramda","description":":ram: Practical functional Javascript","fork":true,"url":"https://api.github.com/repos/asaf-romano/ramda","forks_url":"https://api.github.com/repos/asaf-romano/ramda/forks","keys_url":"https://api.github.com/repos/asaf-romano/ramda/keys{/key_id}","collaborators_url":"https://api.github.com/repos/asaf-romano/ramda/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/asaf-romano/ramda/teams","hooks_url":"https://api.github.com/repos/asaf-romano/ramda/hooks","issue_events_url":"https://api.github.com/repos/asaf-romano/ramda/issues/events{/number}","events_url":"https://api.github.com/repos/asaf-romano/ramda/events","assignees_url":"https://api.github.com/repos/asaf-romano/ramda/assignees{/user}","branches_url":"https://api.github.com/repos/asaf-romano/ramda/branches{/branch}","tags_url":"https://api.github.com/repos/asaf-romano/ramda/tags","blobs_url":"https://api.github.com/repos/asaf-romano/ramda/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/asaf-romano/ramda/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/asaf-romano/ramda/git/refs{/sha}","trees_url":"https://api.github.com/repos/asaf-romano/ramda/git/trees{/sha}","statuses_url":"https://api.github.com/repos/asaf-romano/ramda/statuses/{sha}","languages_url":"https://api.github.com/repos/asaf-romano/ramda/languages","stargazers_url":"https://api.github.com/repos/asaf-romano/ramda/stargazers","contributors_url":"https://api.github.com/repos/asaf-romano/ramda/contributors","subscribers_url":"https://api.github.com/repos/asaf-romano/ramda/subscribers","subscription_url":"https://api.github.com/repos/asaf-romano/ramda/subscription","commits_url":"https://api.github.com/repos/asaf-romano/ramda/commits{/sha}","git_commits_url":"https://api.github.com/repos/asaf-romano/ramda/git/commits{/sha}","comments_url":"https://api.github.com/repos/asaf-romano/ramda/comments{/number}","issue_comment_url":"https://api.github.com/repos/asaf-romano/ramda/issues/comments{/number}","contents_url":"https://api.github.com/repos/asaf-romano/ramda/contents/{+path}","compare_url":"https://api.github.com/repos/asaf-romano/ramda/compare/{base}...{head}","merges_url":"https://api.github.com/repos/asaf-romano/ramda/merges","archive_url":"https://api.github.com/repos/asaf-romano/ramda/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/asaf-romano/ramda/downloads","issues_url":"https://api.github.com/repos/asaf-romano/ramda/issues{/number}","pulls_url":"https://api.github.com/repos/asaf-romano/ramda/pulls{/number}","milestones_url":"https://api.github.com/repos/asaf-romano/ramda/milestones{/number}","notifications_url":"https://api.github.com/repos/asaf-romano/ramda/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/asaf-romano/ramda/labels{/name}","releases_url":"https://api.github.com/repos/asaf-romano/ramda/releases{/id}","deployments_url":"https://api.github.com/repos/asaf-romano/ramda/deployments","created_at":"2015-05-29T08:16:06Z","updated_at":"2015-05-29T08:16:07Z","pushed_at":"2016-02-20T17:02:32Z","git_url":"git://github.com/asaf-romano/ramda.git","ssh_url":"git@github.com:asaf-romano/ramda.git","clone_url":"https://github.com/asaf-romano/ramda.git","svn_url":"https://github.com/asaf-romano/ramda","homepage":"http://ramdajs.com","size":5371,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"ramda:master","ref":"master","sha":"0e6748fed234bc0e765d3408f562c1e72de7bb50","user":{"login":"ramda","id":5298359,"avatar_url":"https://avatars.githubusercontent.com/u/5298359?v=3","gravatar_id":"","url":"https://api.github.com/users/ramda","html_url":"https://github.com/ramda","followers_url":"https://api.github.com/users/ramda/followers","following_url":"https://api.github.com/users/ramda/following{/other_user}","gists_url":"https://api.github.com/users/ramda/gists{/gist_id}","starred_url":"https://api.github.com/users/ramda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ramda/subscriptions","organizations_url":"https://api.github.com/users/ramda/orgs","repos_url":"https://api.github.com/users/ramda/repos","events_url":"https://api.github.com/users/ramda/events{/privacy}","received_events_url":"https://api.github.com/users/ramda/received_events","type":"Organization","site_admin":false},"repo":{"id":10851820,"name":"ramda","full_name":"ramda/ramda","owner":{"login":"ramda","id":5298359,"avatar_url":"https://avatars.githubusercontent.com/u/5298359?v=3","gravatar_id":"","url":"https://api.github.com/users/ramda","html_url":"https://github.com/ramda","followers_url":"https://api.github.com/users/ramda/followers","following_url":"https://api.github.com/users/ramda/following{/other_user}","gists_url":"https://api.github.com/users/ramda/gists{/gist_id}","starred_url":"https://api.github.com/users/ramda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ramda/subscriptions","organizations_url":"https://api.github.com/users/ramda/orgs","repos_url":"https://api.github.com/users/ramda/repos","events_url":"https://api.github.com/users/ramda/events{/privacy}","received_events_url":"https://api.github.com/users/ramda/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ramda/ramda","description":":ram: Practical functional Javascript","fork":false,"url":"https://api.github.com/repos/ramda/ramda","forks_url":"https://api.github.com/repos/ramda/ramda/forks","keys_url":"https://api.github.com/repos/ramda/ramda/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ramda/ramda/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ramda/ramda/teams","hooks_url":"https://api.github.com/repos/ramda/ramda/hooks","issue_events_url":"https://api.github.com/repos/ramda/ramda/issues/events{/number}","events_url":"https://api.github.com/repos/ramda/ramda/events","assignees_url":"https://api.github.com/repos/ramda/ramda/assignees{/user}","branches_url":"https://api.github.com/repos/ramda/ramda/branches{/branch}","tags_url":"https://api.github.com/repos/ramda/ramda/tags","blobs_url":"https://api.github.com/repos/ramda/ramda/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ramda/ramda/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ramda/ramda/git/refs{/sha}","trees_url":"https://api.github.com/repos/ramda/ramda/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ramda/ramda/statuses/{sha}","languages_url":"https://api.github.com/repos/ramda/ramda/languages","stargazers_url":"https://api.github.com/repos/ramda/ramda/stargazers","contributors_url":"https://api.github.com/repos/ramda/ramda/contributors","subscribers_url":"https://api.github.com/repos/ramda/ramda/subscribers","subscription_url":"https://api.github.com/repos/ramda/ramda/subscription","commits_url":"https://api.github.com/repos/ramda/ramda/commits{/sha}","git_commits_url":"https://api.github.com/repos/ramda/ramda/git/commits{/sha}","comments_url":"https://api.github.com/repos/ramda/ramda/comments{/number}","issue_comment_url":"https://api.github.com/repos/ramda/ramda/issues/comments{/number}","contents_url":"https://api.github.com/repos/ramda/ramda/contents/{+path}","compare_url":"https://api.github.com/repos/ramda/ramda/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ramda/ramda/merges","archive_url":"https://api.github.com/repos/ramda/ramda/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ramda/ramda/downloads","issues_url":"https://api.github.com/repos/ramda/ramda/issues{/number}","pulls_url":"https://api.github.com/repos/ramda/ramda/pulls{/number}","milestones_url":"https://api.github.com/repos/ramda/ramda/milestones{/number}","notifications_url":"https://api.github.com/repos/ramda/ramda/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ramda/ramda/labels{/name}","releases_url":"https://api.github.com/repos/ramda/ramda/releases{/id}","deployments_url":"https://api.github.com/repos/ramda/ramda/deployments","created_at":"2013-06-21T20:32:35Z","updated_at":"2016-02-20T15:48:16Z","pushed_at":"2016-02-20T17:03:27Z","git_url":"git://github.com/ramda/ramda.git","ssh_url":"git@github.com:ramda/ramda.git","clone_url":"https://github.com/ramda/ramda.git","svn_url":"https://github.com/ramda/ramda","homepage":"http://ramdajs.com","size":6547,"stargazers_count":3781,"watchers_count":3781,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":271,"mirror_url":null,"open_issues_count":108,"forks":271,"open_issues":108,"watchers":3781,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ramda/ramda/pulls/1655"},"html":{"href":"https://github.com/ramda/ramda/pull/1655"},"issue":{"href":"https://api.github.com/repos/ramda/ramda/issues/1655"},"comments":{"href":"https://api.github.com/repos/ramda/ramda/issues/1655/comments"},"review_comments":{"href":"https://api.github.com/repos/ramda/ramda/pulls/1655/comments"},"review_comment":{"href":"https://api.github.com/repos/ramda/ramda/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ramda/ramda/pulls/1655/commits"},"statuses":{"href":"https://api.github.com/repos/ramda/ramda/statuses/b70ce7698583dc7af5f041fa4aa67be502dfba70"}}}}