{"action":"created","comment":{"url":"https://api.github.com/repos/aspnet/Common/pulls/comments/165856975","pull_request_review_id":93857217,"id":165856975,"diff_hunk":"@@ -127,9 +127,9 @@ public bool HasValue\n         {\n             get\n             {\n-                if (index < 0 || (uint)index >= (uint)Length)\n+                if ((uint)index >= (uint)Length)\n                 {\n-                    throw new IndexOutOfRangeException();\n+                    ThrowHelper.ThrowIndexOutOfRangeException();","path":"src/Microsoft.Extensions.Primitives/StringSegment.cs","position":8,"original_position":8,"commit_id":"8cc7042337f742fc3d682406e01935c2cef2db08","original_commit_id":"8cc7042337f742fc3d682406e01935c2cef2db08","user":{"login":"davidfowl","id":95136,"avatar_url":"https://avatars3.githubusercontent.com/u/95136?v=4","gravatar_id":"","url":"https://api.github.com/users/davidfowl","html_url":"https://github.com/davidfowl","followers_url":"https://api.github.com/users/davidfowl/followers","following_url":"https://api.github.com/users/davidfowl/following{/other_user}","gists_url":"https://api.github.com/users/davidfowl/gists{/gist_id}","starred_url":"https://api.github.com/users/davidfowl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidfowl/subscriptions","organizations_url":"https://api.github.com/users/davidfowl/orgs","repos_url":"https://api.github.com/users/davidfowl/repos","events_url":"https://api.github.com/users/davidfowl/events{/privacy}","received_events_url":"https://api.github.com/users/davidfowl/received_events","type":"User","site_admin":false},"body":"Yep!","created_at":"2018-02-04T20:40:49Z","updated_at":"2018-02-04T20:40:49Z","html_url":"https://github.com/aspnet/Common/pull/306#discussion_r165856975","pull_request_url":"https://api.github.com/repos/aspnet/Common/pulls/306","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/aspnet/Common/pulls/comments/165856975"},"html":{"href":"https://github.com/aspnet/Common/pull/306#discussion_r165856975"},"pull_request":{"href":"https://api.github.com/repos/aspnet/Common/pulls/306"}},"in_reply_to_id":160054977},"pull_request":{"url":"https://api.github.com/repos/aspnet/Common/pulls/306","id":161529747,"html_url":"https://github.com/aspnet/Common/pull/306","diff_url":"https://github.com/aspnet/Common/pull/306.diff","patch_url":"https://github.com/aspnet/Common/pull/306.patch","issue_url":"https://api.github.com/repos/aspnet/Common/issues/306","number":306,"state":"open","locked":false,"title":"StringSegment better code for Indexer and Equals","user":{"login":"gfoidl","id":5755834,"avatar_url":"https://avatars2.githubusercontent.com/u/5755834?v=4","gravatar_id":"","url":"https://api.github.com/users/gfoidl","html_url":"https://github.com/gfoidl","followers_url":"https://api.github.com/users/gfoidl/followers","following_url":"https://api.github.com/users/gfoidl/following{/other_user}","gists_url":"https://api.github.com/users/gfoidl/gists{/gist_id}","starred_url":"https://api.github.com/users/gfoidl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gfoidl/subscriptions","organizations_url":"https://api.github.com/users/gfoidl/orgs","repos_url":"https://api.github.com/users/gfoidl/repos","events_url":"https://api.github.com/users/gfoidl/events{/privacy}","received_events_url":"https://api.github.com/users/gfoidl/received_events","type":"User","site_admin":false},"body":"### Indexer\r\n\r\n`if (index < 0 || (uint)index >= (uint)Length)` the first part is already covered by the second part, so it was removed.\r\n\r\n`ThrowHelper` is used for throwing the exception, so making the indexer more inlineable.\r\n\r\n### Equals\r\n\r\nThe cast was avoided due to new language features.\r\n\r\n### Side note\r\n\r\nAlthough I assume that _StringSegment_ will be replaced by something based on _Span_ there should be good code until this replacement actually happens.\r\n  ","created_at":"2018-01-07T16:59:10Z","updated_at":"2018-02-04T20:40:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"13661d08942dabe01fcce4ec93ec879c740f2d1e","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"milestone":null,"commits_url":"https://api.github.com/repos/aspnet/Common/pulls/306/commits","review_comments_url":"https://api.github.com/repos/aspnet/Common/pulls/306/comments","review_comment_url":"https://api.github.com/repos/aspnet/Common/pulls/comments{/number}","comments_url":"https://api.github.com/repos/aspnet/Common/issues/306/comments","statuses_url":"https://api.github.com/repos/aspnet/Common/statuses/8cc7042337f742fc3d682406e01935c2cef2db08","head":{"label":"gfoidl:dev","ref":"dev","sha":"8cc7042337f742fc3d682406e01935c2cef2db08","user":{"login":"gfoidl","id":5755834,"avatar_url":"https://avatars2.githubusercontent.com/u/5755834?v=4","gravatar_id":"","url":"https://api.github.com/users/gfoidl","html_url":"https://github.com/gfoidl","followers_url":"https://api.github.com/users/gfoidl/followers","following_url":"https://api.github.com/users/gfoidl/following{/other_user}","gists_url":"https://api.github.com/users/gfoidl/gists{/gist_id}","starred_url":"https://api.github.com/users/gfoidl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gfoidl/subscriptions","organizations_url":"https://api.github.com/users/gfoidl/orgs","repos_url":"https://api.github.com/users/gfoidl/repos","events_url":"https://api.github.com/users/gfoidl/events{/privacy}","received_events_url":"https://api.github.com/users/gfoidl/received_events","type":"User","site_admin":false},"repo":{"id":116572237,"name":"Common","full_name":"gfoidl/Common","owner":{"login":"gfoidl","id":5755834,"avatar_url":"https://avatars2.githubusercontent.com/u/5755834?v=4","gravatar_id":"","url":"https://api.github.com/users/gfoidl","html_url":"https://github.com/gfoidl","followers_url":"https://api.github.com/users/gfoidl/followers","following_url":"https://api.github.com/users/gfoidl/following{/other_user}","gists_url":"https://api.github.com/users/gfoidl/gists{/gist_id}","starred_url":"https://api.github.com/users/gfoidl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gfoidl/subscriptions","organizations_url":"https://api.github.com/users/gfoidl/orgs","repos_url":"https://api.github.com/users/gfoidl/repos","events_url":"https://api.github.com/users/gfoidl/events{/privacy}","received_events_url":"https://api.github.com/users/gfoidl/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/gfoidl/Common","description":"A repository for shared files to be consumed across the ASPNET repos","fork":true,"url":"https://api.github.com/repos/gfoidl/Common","forks_url":"https://api.github.com/repos/gfoidl/Common/forks","keys_url":"https://api.github.com/repos/gfoidl/Common/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gfoidl/Common/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gfoidl/Common/teams","hooks_url":"https://api.github.com/repos/gfoidl/Common/hooks","issue_events_url":"https://api.github.com/repos/gfoidl/Common/issues/events{/number}","events_url":"https://api.github.com/repos/gfoidl/Common/events","assignees_url":"https://api.github.com/repos/gfoidl/Common/assignees{/user}","branches_url":"https://api.github.com/repos/gfoidl/Common/branches{/branch}","tags_url":"https://api.github.com/repos/gfoidl/Common/tags","blobs_url":"https://api.github.com/repos/gfoidl/Common/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gfoidl/Common/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gfoidl/Common/git/refs{/sha}","trees_url":"https://api.github.com/repos/gfoidl/Common/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gfoidl/Common/statuses/{sha}","languages_url":"https://api.github.com/repos/gfoidl/Common/languages","stargazers_url":"https://api.github.com/repos/gfoidl/Common/stargazers","contributors_url":"https://api.github.com/repos/gfoidl/Common/contributors","subscribers_url":"https://api.github.com/repos/gfoidl/Common/subscribers","subscription_url":"https://api.github.com/repos/gfoidl/Common/subscription","commits_url":"https://api.github.com/repos/gfoidl/Common/commits{/sha}","git_commits_url":"https://api.github.com/repos/gfoidl/Common/git/commits{/sha}","comments_url":"https://api.github.com/repos/gfoidl/Common/comments{/number}","issue_comment_url":"https://api.github.com/repos/gfoidl/Common/issues/comments{/number}","contents_url":"https://api.github.com/repos/gfoidl/Common/contents/{+path}","compare_url":"https://api.github.com/repos/gfoidl/Common/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gfoidl/Common/merges","archive_url":"https://api.github.com/repos/gfoidl/Common/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gfoidl/Common/downloads","issues_url":"https://api.github.com/repos/gfoidl/Common/issues{/number}","pulls_url":"https://api.github.com/repos/gfoidl/Common/pulls{/number}","milestones_url":"https://api.github.com/repos/gfoidl/Common/milestones{/number}","notifications_url":"https://api.github.com/repos/gfoidl/Common/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gfoidl/Common/labels{/name}","releases_url":"https://api.github.com/repos/gfoidl/Common/releases{/id}","deployments_url":"https://api.github.com/repos/gfoidl/Common/deployments","created_at":"2018-01-07T14:31:33Z","updated_at":"2018-01-07T15:12:58Z","pushed_at":"2018-01-07T17:11:16Z","git_url":"git://github.com/gfoidl/Common.git","ssh_url":"git@github.com:gfoidl/Common.git","clone_url":"https://github.com/gfoidl/Common.git","svn_url":"https://github.com/gfoidl/Common","homepage":null,"size":834,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"dev"}},"base":{"label":"aspnet:dev","ref":"dev","sha":"e1f96c53f44ec904f5c504d0630333e8f40f6c72","user":{"login":"aspnet","id":6476660,"avatar_url":"https://avatars3.githubusercontent.com/u/6476660?v=4","gravatar_id":"","url":"https://api.github.com/users/aspnet","html_url":"https://github.com/aspnet","followers_url":"https://api.github.com/users/aspnet/followers","following_url":"https://api.github.com/users/aspnet/following{/other_user}","gists_url":"https://api.github.com/users/aspnet/gists{/gist_id}","starred_url":"https://api.github.com/users/aspnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aspnet/subscriptions","organizations_url":"https://api.github.com/users/aspnet/orgs","repos_url":"https://api.github.com/users/aspnet/repos","events_url":"https://api.github.com/users/aspnet/events{/privacy}","received_events_url":"https://api.github.com/users/aspnet/received_events","type":"Organization","site_admin":false},"repo":{"id":30932325,"name":"Common","full_name":"aspnet/Common","owner":{"login":"aspnet","id":6476660,"avatar_url":"https://avatars3.githubusercontent.com/u/6476660?v=4","gravatar_id":"","url":"https://api.github.com/users/aspnet","html_url":"https://github.com/aspnet","followers_url":"https://api.github.com/users/aspnet/followers","following_url":"https://api.github.com/users/aspnet/following{/other_user}","gists_url":"https://api.github.com/users/aspnet/gists{/gist_id}","starred_url":"https://api.github.com/users/aspnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aspnet/subscriptions","organizations_url":"https://api.github.com/users/aspnet/orgs","repos_url":"https://api.github.com/users/aspnet/repos","events_url":"https://api.github.com/users/aspnet/events{/privacy}","received_events_url":"https://api.github.com/users/aspnet/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/aspnet/Common","description":"A repository for shared files to be consumed across the ASPNET repos","fork":false,"url":"https://api.github.com/repos/aspnet/Common","forks_url":"https://api.github.com/repos/aspnet/Common/forks","keys_url":"https://api.github.com/repos/aspnet/Common/keys{/key_id}","collaborators_url":"https://api.github.com/repos/aspnet/Common/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/aspnet/Common/teams","hooks_url":"https://api.github.com/repos/aspnet/Common/hooks","issue_events_url":"https://api.github.com/repos/aspnet/Common/issues/events{/number}","events_url":"https://api.github.com/repos/aspnet/Common/events","assignees_url":"https://api.github.com/repos/aspnet/Common/assignees{/user}","branches_url":"https://api.github.com/repos/aspnet/Common/branches{/branch}","tags_url":"https://api.github.com/repos/aspnet/Common/tags","blobs_url":"https://api.github.com/repos/aspnet/Common/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/aspnet/Common/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/aspnet/Common/git/refs{/sha}","trees_url":"https://api.github.com/repos/aspnet/Common/git/trees{/sha}","statuses_url":"https://api.github.com/repos/aspnet/Common/statuses/{sha}","languages_url":"https://api.github.com/repos/aspnet/Common/languages","stargazers_url":"https://api.github.com/repos/aspnet/Common/stargazers","contributors_url":"https://api.github.com/repos/aspnet/Common/contributors","subscribers_url":"https://api.github.com/repos/aspnet/Common/subscribers","subscription_url":"https://api.github.com/repos/aspnet/Common/subscription","commits_url":"https://api.github.com/repos/aspnet/Common/commits{/sha}","git_commits_url":"https://api.github.com/repos/aspnet/Common/git/commits{/sha}","comments_url":"https://api.github.com/repos/aspnet/Common/comments{/number}","issue_comment_url":"https://api.github.com/repos/aspnet/Common/issues/comments{/number}","contents_url":"https://api.github.com/repos/aspnet/Common/contents/{+path}","compare_url":"https://api.github.com/repos/aspnet/Common/compare/{base}...{head}","merges_url":"https://api.github.com/repos/aspnet/Common/merges","archive_url":"https://api.github.com/repos/aspnet/Common/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/aspnet/Common/downloads","issues_url":"https://api.github.com/repos/aspnet/Common/issues{/number}","pulls_url":"https://api.github.com/repos/aspnet/Common/pulls{/number}","milestones_url":"https://api.github.com/repos/aspnet/Common/milestones{/number}","notifications_url":"https://api.github.com/repos/aspnet/Common/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/aspnet/Common/labels{/name}","releases_url":"https://api.github.com/repos/aspnet/Common/releases{/id}","deployments_url":"https://api.github.com/repos/aspnet/Common/deployments","created_at":"2015-02-17T19:02:08Z","updated_at":"2018-01-29T00:29:46Z","pushed_at":"2018-02-04T20:15:56Z","git_url":"git://github.com/aspnet/Common.git","ssh_url":"git@github.com:aspnet/Common.git","clone_url":"https://github.com/aspnet/Common.git","svn_url":"https://github.com/aspnet/Common","homepage":null,"size":825,"stargazers_count":103,"watchers_count":103,"language":"C#","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":52,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":52,"open_issues":6,"watchers":103,"default_branch":"dev"}},"_links":{"self":{"href":"https://api.github.com/repos/aspnet/Common/pulls/306"},"html":{"href":"https://github.com/aspnet/Common/pull/306"},"issue":{"href":"https://api.github.com/repos/aspnet/Common/issues/306"},"comments":{"href":"https://api.github.com/repos/aspnet/Common/issues/306/comments"},"review_comments":{"href":"https://api.github.com/repos/aspnet/Common/pulls/306/comments"},"review_comment":{"href":"https://api.github.com/repos/aspnet/Common/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/aspnet/Common/pulls/306/commits"},"statuses":{"href":"https://api.github.com/repos/aspnet/Common/statuses/8cc7042337f742fc3d682406e01935c2cef2db08"}},"author_association":"NONE"}}
{"actor":{"display_login":"davidfowl"}}