{"action":"created","comment":{"url":"https://api.github.com/repos/dlang/phobos/pulls/comments/132382216","pull_request_review_id":55454486,"id":132382216,"diff_hunk":"@@ -886,6 +886,130 @@ public:\n         return b;\n     }\n \n+    /**\n+      Sets all the values in the $(D BitArray) to the\n+      value specified by $(D val).\n+     */\n+    void opSliceAssign(bool val)\n+    {\n+        _ptr[0 .. fullWords] = val ? ~size_t(0) : 0;\n+        if (endBits)\n+            _ptr[fullWords] = val ?\n+                _ptr[fullWords] | endMask :\n+                _ptr[fullWords] & ~endMask;\n+    }\n+\n+    ///\n+    @system unittest\n+    {\n+        import std.algorithm.comparison : equal;\n+\n+        auto b = BitArray([1, 0, 1, 0, 1, 1]);\n+\n+        b[] = true;\n+        // all bits are set\n+        assert(b.bitsSet.equal([0, 1, 2, 3, 4, 5]));\n+\n+        b[] = false;\n+        // none of the bits are set\n+        assert(b.bitsSet.empty);\n+    }\n+\n+    /**\n+      Sets the bits of a slice of $(D BitArray) which\n+      starts at the index $(D start) and ends at the\n+      index ($D end) - 1 with the values specified by $(D val).\n+     */\n+    void opSliceAssign(bool val, size_t start, size_t end)\n+    in\n+    {\n+        assert(start >= 0 && start <= _len);\n+        assert(end >=0 && end <= _len);","path":"std/bitmanip.d","position":51,"original_position":51,"commit_id":"753f37067c45be9f3c7f8c50e351de036ed6dc90","original_commit_id":"753f37067c45be9f3c7f8c50e351de036ed6dc90","user":{"login":"RazvanN7","id":22907766,"avatar_url":"https://avatars2.githubusercontent.com/u/22907766?v=4","gravatar_id":"","url":"https://api.github.com/users/RazvanN7","html_url":"https://github.com/RazvanN7","followers_url":"https://api.github.com/users/RazvanN7/followers","following_url":"https://api.github.com/users/RazvanN7/following{/other_user}","gists_url":"https://api.github.com/users/RazvanN7/gists{/gist_id}","starred_url":"https://api.github.com/users/RazvanN7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RazvanN7/subscriptions","organizations_url":"https://api.github.com/users/RazvanN7/orgs","repos_url":"https://api.github.com/users/RazvanN7/repos","events_url":"https://api.github.com/users/RazvanN7/events{/privacy}","received_events_url":"https://api.github.com/users/RazvanN7/received_events","type":"User","site_admin":false},"body":"That is not correct. `length` is a property which simply returns `_len`. `dim` is the property which returns the number of words. I though I'd use _len to avoid the extra function call.","created_at":"2017-08-10T07:34:12Z","updated_at":"2017-08-10T07:34:12Z","html_url":"https://github.com/dlang/phobos/pull/5634#discussion_r132382216","pull_request_url":"https://api.github.com/repos/dlang/phobos/pulls/5634","_links":{"self":{"href":"https://api.github.com/repos/dlang/phobos/pulls/comments/132382216"},"html":{"href":"https://github.com/dlang/phobos/pull/5634#discussion_r132382216"},"pull_request":{"href":"https://api.github.com/repos/dlang/phobos/pulls/5634"}}},"pull_request":{"url":"https://api.github.com/repos/dlang/phobos/pulls/5634","id":131522725,"html_url":"https://github.com/dlang/phobos/pull/5634","diff_url":"https://github.com/dlang/phobos/pull/5634.diff","patch_url":"https://github.com/dlang/phobos/pull/5634.patch","issue_url":"https://api.github.com/repos/dlang/phobos/issues/5634","number":5634,"state":"open","locked":false,"title":"Fix Issue 1998 - std.bitarray should have setAll / opSliceAssign","user":{"login":"RazvanN7","id":22907766,"avatar_url":"https://avatars2.githubusercontent.com/u/22907766?v=4","gravatar_id":"","url":"https://api.github.com/users/RazvanN7","html_url":"https://github.com/RazvanN7","followers_url":"https://api.github.com/users/RazvanN7/followers","following_url":"https://api.github.com/users/RazvanN7/following{/other_user}","gists_url":"https://api.github.com/users/RazvanN7/gists{/gist_id}","starred_url":"https://api.github.com/users/RazvanN7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RazvanN7/subscriptions","organizations_url":"https://api.github.com/users/RazvanN7/orgs","repos_url":"https://api.github.com/users/RazvanN7/repos","events_url":"https://api.github.com/users/RazvanN7/events{/privacy}","received_events_url":"https://api.github.com/users/RazvanN7/received_events","type":"User","site_admin":false},"body":"This PR implements opSliceAssign(bool val)/opSliceAssign(bool val, size_t start, size_t end) and opUnary for the \"~\" operator.","created_at":"2017-07-20T10:39:59Z","updated_at":"2017-08-10T07:34:12Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6b3a7ef7961dda4755997ef9661a02e4a78d5b02","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/dlang/phobos/pulls/5634/commits","review_comments_url":"https://api.github.com/repos/dlang/phobos/pulls/5634/comments","review_comment_url":"https://api.github.com/repos/dlang/phobos/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dlang/phobos/issues/5634/comments","statuses_url":"https://api.github.com/repos/dlang/phobos/statuses/753f37067c45be9f3c7f8c50e351de036ed6dc90","head":{"label":"RazvanN7:Issue_1998","ref":"Issue_1998","sha":"753f37067c45be9f3c7f8c50e351de036ed6dc90","user":{"login":"RazvanN7","id":22907766,"avatar_url":"https://avatars2.githubusercontent.com/u/22907766?v=4","gravatar_id":"","url":"https://api.github.com/users/RazvanN7","html_url":"https://github.com/RazvanN7","followers_url":"https://api.github.com/users/RazvanN7/followers","following_url":"https://api.github.com/users/RazvanN7/following{/other_user}","gists_url":"https://api.github.com/users/RazvanN7/gists{/gist_id}","starred_url":"https://api.github.com/users/RazvanN7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RazvanN7/subscriptions","organizations_url":"https://api.github.com/users/RazvanN7/orgs","repos_url":"https://api.github.com/users/RazvanN7/repos","events_url":"https://api.github.com/users/RazvanN7/events{/privacy}","received_events_url":"https://api.github.com/users/RazvanN7/received_events","type":"User","site_admin":false},"repo":{"id":72423737,"name":"phobos","full_name":"RazvanN7/phobos","owner":{"login":"RazvanN7","id":22907766,"avatar_url":"https://avatars2.githubusercontent.com/u/22907766?v=4","gravatar_id":"","url":"https://api.github.com/users/RazvanN7","html_url":"https://github.com/RazvanN7","followers_url":"https://api.github.com/users/RazvanN7/followers","following_url":"https://api.github.com/users/RazvanN7/following{/other_user}","gists_url":"https://api.github.com/users/RazvanN7/gists{/gist_id}","starred_url":"https://api.github.com/users/RazvanN7/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RazvanN7/subscriptions","organizations_url":"https://api.github.com/users/RazvanN7/orgs","repos_url":"https://api.github.com/users/RazvanN7/repos","events_url":"https://api.github.com/users/RazvanN7/events{/privacy}","received_events_url":"https://api.github.com/users/RazvanN7/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/RazvanN7/phobos","description":"The standard library of the D programming language","fork":true,"url":"https://api.github.com/repos/RazvanN7/phobos","forks_url":"https://api.github.com/repos/RazvanN7/phobos/forks","keys_url":"https://api.github.com/repos/RazvanN7/phobos/keys{/key_id}","collaborators_url":"https://api.github.com/repos/RazvanN7/phobos/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/RazvanN7/phobos/teams","hooks_url":"https://api.github.com/repos/RazvanN7/phobos/hooks","issue_events_url":"https://api.github.com/repos/RazvanN7/phobos/issues/events{/number}","events_url":"https://api.github.com/repos/RazvanN7/phobos/events","assignees_url":"https://api.github.com/repos/RazvanN7/phobos/assignees{/user}","branches_url":"https://api.github.com/repos/RazvanN7/phobos/branches{/branch}","tags_url":"https://api.github.com/repos/RazvanN7/phobos/tags","blobs_url":"https://api.github.com/repos/RazvanN7/phobos/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/RazvanN7/phobos/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/RazvanN7/phobos/git/refs{/sha}","trees_url":"https://api.github.com/repos/RazvanN7/phobos/git/trees{/sha}","statuses_url":"https://api.github.com/repos/RazvanN7/phobos/statuses/{sha}","languages_url":"https://api.github.com/repos/RazvanN7/phobos/languages","stargazers_url":"https://api.github.com/repos/RazvanN7/phobos/stargazers","contributors_url":"https://api.github.com/repos/RazvanN7/phobos/contributors","subscribers_url":"https://api.github.com/repos/RazvanN7/phobos/subscribers","subscription_url":"https://api.github.com/repos/RazvanN7/phobos/subscription","commits_url":"https://api.github.com/repos/RazvanN7/phobos/commits{/sha}","git_commits_url":"https://api.github.com/repos/RazvanN7/phobos/git/commits{/sha}","comments_url":"https://api.github.com/repos/RazvanN7/phobos/comments{/number}","issue_comment_url":"https://api.github.com/repos/RazvanN7/phobos/issues/comments{/number}","contents_url":"https://api.github.com/repos/RazvanN7/phobos/contents/{+path}","compare_url":"https://api.github.com/repos/RazvanN7/phobos/compare/{base}...{head}","merges_url":"https://api.github.com/repos/RazvanN7/phobos/merges","archive_url":"https://api.github.com/repos/RazvanN7/phobos/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/RazvanN7/phobos/downloads","issues_url":"https://api.github.com/repos/RazvanN7/phobos/issues{/number}","pulls_url":"https://api.github.com/repos/RazvanN7/phobos/pulls{/number}","milestones_url":"https://api.github.com/repos/RazvanN7/phobos/milestones{/number}","notifications_url":"https://api.github.com/repos/RazvanN7/phobos/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/RazvanN7/phobos/labels{/name}","releases_url":"https://api.github.com/repos/RazvanN7/phobos/releases{/id}","deployments_url":"https://api.github.com/repos/RazvanN7/phobos/deployments","created_at":"2016-10-31T09:54:06Z","updated_at":"2016-10-31T09:54:10Z","pushed_at":"2017-08-10T07:23:35Z","git_url":"git://github.com/RazvanN7/phobos.git","ssh_url":"git@github.com:RazvanN7/phobos.git","clone_url":"https://github.com/RazvanN7/phobos.git","svn_url":"https://github.com/RazvanN7/phobos","homepage":"dlang.org/phobos","size":44313,"stargazers_count":0,"watchers_count":0,"language":"D","has_issues":false,"has_projects":true,"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":"dlang:master","ref":"master","sha":"41c82e5b9eb95b57c0690e790007f3ac1f8bebbc","user":{"login":"dlang","id":565913,"avatar_url":"https://avatars3.githubusercontent.com/u/565913?v=4","gravatar_id":"","url":"https://api.github.com/users/dlang","html_url":"https://github.com/dlang","followers_url":"https://api.github.com/users/dlang/followers","following_url":"https://api.github.com/users/dlang/following{/other_user}","gists_url":"https://api.github.com/users/dlang/gists{/gist_id}","starred_url":"https://api.github.com/users/dlang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlang/subscriptions","organizations_url":"https://api.github.com/users/dlang/orgs","repos_url":"https://api.github.com/users/dlang/repos","events_url":"https://api.github.com/users/dlang/events{/privacy}","received_events_url":"https://api.github.com/users/dlang/received_events","type":"Organization","site_admin":false},"repo":{"id":1257084,"name":"phobos","full_name":"dlang/phobos","owner":{"login":"dlang","id":565913,"avatar_url":"https://avatars3.githubusercontent.com/u/565913?v=4","gravatar_id":"","url":"https://api.github.com/users/dlang","html_url":"https://github.com/dlang","followers_url":"https://api.github.com/users/dlang/followers","following_url":"https://api.github.com/users/dlang/following{/other_user}","gists_url":"https://api.github.com/users/dlang/gists{/gist_id}","starred_url":"https://api.github.com/users/dlang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlang/subscriptions","organizations_url":"https://api.github.com/users/dlang/orgs","repos_url":"https://api.github.com/users/dlang/repos","events_url":"https://api.github.com/users/dlang/events{/privacy}","received_events_url":"https://api.github.com/users/dlang/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dlang/phobos","description":"The standard library of the D programming language","fork":false,"url":"https://api.github.com/repos/dlang/phobos","forks_url":"https://api.github.com/repos/dlang/phobos/forks","keys_url":"https://api.github.com/repos/dlang/phobos/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dlang/phobos/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dlang/phobos/teams","hooks_url":"https://api.github.com/repos/dlang/phobos/hooks","issue_events_url":"https://api.github.com/repos/dlang/phobos/issues/events{/number}","events_url":"https://api.github.com/repos/dlang/phobos/events","assignees_url":"https://api.github.com/repos/dlang/phobos/assignees{/user}","branches_url":"https://api.github.com/repos/dlang/phobos/branches{/branch}","tags_url":"https://api.github.com/repos/dlang/phobos/tags","blobs_url":"https://api.github.com/repos/dlang/phobos/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dlang/phobos/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dlang/phobos/git/refs{/sha}","trees_url":"https://api.github.com/repos/dlang/phobos/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dlang/phobos/statuses/{sha}","languages_url":"https://api.github.com/repos/dlang/phobos/languages","stargazers_url":"https://api.github.com/repos/dlang/phobos/stargazers","contributors_url":"https://api.github.com/repos/dlang/phobos/contributors","subscribers_url":"https://api.github.com/repos/dlang/phobos/subscribers","subscription_url":"https://api.github.com/repos/dlang/phobos/subscription","commits_url":"https://api.github.com/repos/dlang/phobos/commits{/sha}","git_commits_url":"https://api.github.com/repos/dlang/phobos/git/commits{/sha}","comments_url":"https://api.github.com/repos/dlang/phobos/comments{/number}","issue_comment_url":"https://api.github.com/repos/dlang/phobos/issues/comments{/number}","contents_url":"https://api.github.com/repos/dlang/phobos/contents/{+path}","compare_url":"https://api.github.com/repos/dlang/phobos/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dlang/phobos/merges","archive_url":"https://api.github.com/repos/dlang/phobos/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dlang/phobos/downloads","issues_url":"https://api.github.com/repos/dlang/phobos/issues{/number}","pulls_url":"https://api.github.com/repos/dlang/phobos/pulls{/number}","milestones_url":"https://api.github.com/repos/dlang/phobos/milestones{/number}","notifications_url":"https://api.github.com/repos/dlang/phobos/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dlang/phobos/labels{/name}","releases_url":"https://api.github.com/repos/dlang/phobos/releases{/id}","deployments_url":"https://api.github.com/repos/dlang/phobos/deployments","created_at":"2011-01-15T07:00:06Z","updated_at":"2017-08-09T13:53:24Z","pushed_at":"2017-08-10T07:23:38Z","git_url":"git://github.com/dlang/phobos.git","ssh_url":"git@github.com:dlang/phobos.git","clone_url":"https://github.com/dlang/phobos.git","svn_url":"https://github.com/dlang/phobos","homepage":"dlang.org/phobos","size":44331,"stargazers_count":829,"watchers_count":829,"language":"D","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":554,"mirror_url":null,"open_issues_count":98,"forks":554,"open_issues":98,"watchers":829,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dlang/phobos/pulls/5634"},"html":{"href":"https://github.com/dlang/phobos/pull/5634"},"issue":{"href":"https://api.github.com/repos/dlang/phobos/issues/5634"},"comments":{"href":"https://api.github.com/repos/dlang/phobos/issues/5634/comments"},"review_comments":{"href":"https://api.github.com/repos/dlang/phobos/pulls/5634/comments"},"review_comment":{"href":"https://api.github.com/repos/dlang/phobos/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dlang/phobos/pulls/5634/commits"},"statuses":{"href":"https://api.github.com/repos/dlang/phobos/statuses/753f37067c45be9f3c7f8c50e351de036ed6dc90"}}}}
{"actor":{"display_login":"RazvanN7"}}