{"action":"created","comment":{"url":"https://api.github.com/repos/aspnet/Mvc/pulls/comments/80543370","id":80543370,"diff_hunk":"@@ -48,13 +49,13 @@ public ViewBuffer(IViewBufferScope bufferScope, string name, int pageSize)\n             _name = name;\n             _pageSize = pageSize;\n \n-            Pages = new List<ViewBufferPage>();\n+            _pages = new ViewBufferPages();\n         }\n \n         /// <summary>\n         /// Gets the backing buffer.\n         /// </summary>\n-        public IList<ViewBufferPage> Pages { get; }\n+        public IReadOnlyList<ViewBufferPage> Pages => _pages;","path":"src/Microsoft.AspNetCore.Mvc.ViewFeatures/Internal/ViewBuffer.cs","position":20,"original_position":20,"commit_id":"93e35c5882516a81d363ee74c283b3a51778e92b","original_commit_id":"93e35c5882516a81d363ee74c283b3a51778e92b","user":{"login":"Yves57","id":11701094,"avatar_url":"https://avatars.githubusercontent.com/u/11701094?v=3","gravatar_id":"","url":"https://api.github.com/users/Yves57","html_url":"https://github.com/Yves57","followers_url":"https://api.github.com/users/Yves57/followers","following_url":"https://api.github.com/users/Yves57/following{/other_user}","gists_url":"https://api.github.com/users/Yves57/gists{/gist_id}","starred_url":"https://api.github.com/users/Yves57/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yves57/subscriptions","organizations_url":"https://api.github.com/users/Yves57/orgs","repos_url":"https://api.github.com/users/Yves57/repos","events_url":"https://api.github.com/users/Yves57/events{/privacy}","received_events_url":"https://api.github.com/users/Yves57/received_events","type":"User","site_admin":false},"body":"Better idea: I will add directly a `Count` property and a `operator[]` in the ViewBuffer. It will be useful in `ViewBuffer` implementation and in the test code.","created_at":"2016-09-26T18:40:14Z","updated_at":"2016-09-26T18:40:14Z","html_url":"https://github.com/aspnet/Mvc/pull/5318#discussion_r80543370","pull_request_url":"https://api.github.com/repos/aspnet/Mvc/pulls/5318","_links":{"self":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/comments/80543370"},"html":{"href":"https://github.com/aspnet/Mvc/pull/5318#discussion_r80543370"},"pull_request":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/5318"}}},"pull_request":{"url":"https://api.github.com/repos/aspnet/Mvc/pulls/5318","id":86651549,"html_url":"https://github.com/aspnet/Mvc/pull/5318","diff_url":"https://github.com/aspnet/Mvc/pull/5318.diff","patch_url":"https://github.com/aspnet/Mvc/pull/5318.patch","issue_url":"https://api.github.com/repos/aspnet/Mvc/issues/5318","number":5318,"state":"open","locked":false,"title":"Less allocations in ViewBuffer when there is only one ViewBufferPage","user":{"login":"Yves57","id":11701094,"avatar_url":"https://avatars.githubusercontent.com/u/11701094?v=3","gravatar_id":"","url":"https://api.github.com/users/Yves57","html_url":"https://github.com/Yves57","followers_url":"https://api.github.com/users/Yves57/followers","following_url":"https://api.github.com/users/Yves57/following{/other_user}","gists_url":"https://api.github.com/users/Yves57/gists{/gist_id}","starred_url":"https://api.github.com/users/Yves57/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yves57/subscriptions","organizations_url":"https://api.github.com/users/Yves57/orgs","repos_url":"https://api.github.com/users/Yves57/repos","events_url":"https://api.github.com/users/Yves57/events{/privacy}","received_events_url":"https://api.github.com/users/Yves57/received_events","type":"User","site_admin":false},"body":"See #5284.","created_at":"2016-09-25T14:30:10Z","updated_at":"2016-09-26T18:40:14Z","closed_at":null,"merged_at":null,"merge_commit_sha":"83438a1347efa35cef1539e01e21273afca0e158","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/aspnet/Mvc/pulls/5318/commits","review_comments_url":"https://api.github.com/repos/aspnet/Mvc/pulls/5318/comments","review_comment_url":"https://api.github.com/repos/aspnet/Mvc/pulls/comments{/number}","comments_url":"https://api.github.com/repos/aspnet/Mvc/issues/5318/comments","statuses_url":"https://api.github.com/repos/aspnet/Mvc/statuses/93e35c5882516a81d363ee74c283b3a51778e92b","head":{"label":"Yves57:dev","ref":"dev","sha":"93e35c5882516a81d363ee74c283b3a51778e92b","user":{"login":"Yves57","id":11701094,"avatar_url":"https://avatars.githubusercontent.com/u/11701094?v=3","gravatar_id":"","url":"https://api.github.com/users/Yves57","html_url":"https://github.com/Yves57","followers_url":"https://api.github.com/users/Yves57/followers","following_url":"https://api.github.com/users/Yves57/following{/other_user}","gists_url":"https://api.github.com/users/Yves57/gists{/gist_id}","starred_url":"https://api.github.com/users/Yves57/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yves57/subscriptions","organizations_url":"https://api.github.com/users/Yves57/orgs","repos_url":"https://api.github.com/users/Yves57/repos","events_url":"https://api.github.com/users/Yves57/events{/privacy}","received_events_url":"https://api.github.com/users/Yves57/received_events","type":"User","site_admin":false},"repo":{"id":63844679,"name":"Mvc","full_name":"Yves57/Mvc","owner":{"login":"Yves57","id":11701094,"avatar_url":"https://avatars.githubusercontent.com/u/11701094?v=3","gravatar_id":"","url":"https://api.github.com/users/Yves57","html_url":"https://github.com/Yves57","followers_url":"https://api.github.com/users/Yves57/followers","following_url":"https://api.github.com/users/Yves57/following{/other_user}","gists_url":"https://api.github.com/users/Yves57/gists{/gist_id}","starred_url":"https://api.github.com/users/Yves57/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yves57/subscriptions","organizations_url":"https://api.github.com/users/Yves57/orgs","repos_url":"https://api.github.com/users/Yves57/repos","events_url":"https://api.github.com/users/Yves57/events{/privacy}","received_events_url":"https://api.github.com/users/Yves57/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Yves57/Mvc","description":"ASP.NET Core MVC is a model view controller framework for building dynamic web sites with clean separation of concerns, including the merged MVC, Web API, and Web Pages w/ Razor.","fork":true,"url":"https://api.github.com/repos/Yves57/Mvc","forks_url":"https://api.github.com/repos/Yves57/Mvc/forks","keys_url":"https://api.github.com/repos/Yves57/Mvc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Yves57/Mvc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Yves57/Mvc/teams","hooks_url":"https://api.github.com/repos/Yves57/Mvc/hooks","issue_events_url":"https://api.github.com/repos/Yves57/Mvc/issues/events{/number}","events_url":"https://api.github.com/repos/Yves57/Mvc/events","assignees_url":"https://api.github.com/repos/Yves57/Mvc/assignees{/user}","branches_url":"https://api.github.com/repos/Yves57/Mvc/branches{/branch}","tags_url":"https://api.github.com/repos/Yves57/Mvc/tags","blobs_url":"https://api.github.com/repos/Yves57/Mvc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Yves57/Mvc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Yves57/Mvc/git/refs{/sha}","trees_url":"https://api.github.com/repos/Yves57/Mvc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Yves57/Mvc/statuses/{sha}","languages_url":"https://api.github.com/repos/Yves57/Mvc/languages","stargazers_url":"https://api.github.com/repos/Yves57/Mvc/stargazers","contributors_url":"https://api.github.com/repos/Yves57/Mvc/contributors","subscribers_url":"https://api.github.com/repos/Yves57/Mvc/subscribers","subscription_url":"https://api.github.com/repos/Yves57/Mvc/subscription","commits_url":"https://api.github.com/repos/Yves57/Mvc/commits{/sha}","git_commits_url":"https://api.github.com/repos/Yves57/Mvc/git/commits{/sha}","comments_url":"https://api.github.com/repos/Yves57/Mvc/comments{/number}","issue_comment_url":"https://api.github.com/repos/Yves57/Mvc/issues/comments{/number}","contents_url":"https://api.github.com/repos/Yves57/Mvc/contents/{+path}","compare_url":"https://api.github.com/repos/Yves57/Mvc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Yves57/Mvc/merges","archive_url":"https://api.github.com/repos/Yves57/Mvc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Yves57/Mvc/downloads","issues_url":"https://api.github.com/repos/Yves57/Mvc/issues{/number}","pulls_url":"https://api.github.com/repos/Yves57/Mvc/pulls{/number}","milestones_url":"https://api.github.com/repos/Yves57/Mvc/milestones{/number}","notifications_url":"https://api.github.com/repos/Yves57/Mvc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Yves57/Mvc/labels{/name}","releases_url":"https://api.github.com/repos/Yves57/Mvc/releases{/id}","deployments_url":"https://api.github.com/repos/Yves57/Mvc/deployments","created_at":"2016-07-21T06:53:25Z","updated_at":"2016-07-21T06:53:35Z","pushed_at":"2016-09-25T14:56:22Z","git_url":"git://github.com/Yves57/Mvc.git","ssh_url":"git@github.com:Yves57/Mvc.git","clone_url":"https://github.com/Yves57/Mvc.git","svn_url":"https://github.com/Yves57/Mvc","homepage":"","size":23489,"stargazers_count":0,"watchers_count":0,"language":"C#","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":"dev"}},"base":{"label":"aspnet:dev","ref":"dev","sha":"0d782d9d9abb828aa23bf8d1b36ca12a771c55f8","user":{"login":"aspnet","id":6476660,"avatar_url":"https://avatars.githubusercontent.com/u/6476660?v=3","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":15126429,"name":"Mvc","full_name":"aspnet/Mvc","owner":{"login":"aspnet","id":6476660,"avatar_url":"https://avatars.githubusercontent.com/u/6476660?v=3","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/Mvc","description":"ASP.NET Core MVC is a model view controller framework for building dynamic web sites with clean separation of concerns, including the merged MVC, Web API, and Web Pages w/ Razor.","fork":false,"url":"https://api.github.com/repos/aspnet/Mvc","forks_url":"https://api.github.com/repos/aspnet/Mvc/forks","keys_url":"https://api.github.com/repos/aspnet/Mvc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/aspnet/Mvc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/aspnet/Mvc/teams","hooks_url":"https://api.github.com/repos/aspnet/Mvc/hooks","issue_events_url":"https://api.github.com/repos/aspnet/Mvc/issues/events{/number}","events_url":"https://api.github.com/repos/aspnet/Mvc/events","assignees_url":"https://api.github.com/repos/aspnet/Mvc/assignees{/user}","branches_url":"https://api.github.com/repos/aspnet/Mvc/branches{/branch}","tags_url":"https://api.github.com/repos/aspnet/Mvc/tags","blobs_url":"https://api.github.com/repos/aspnet/Mvc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/aspnet/Mvc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/aspnet/Mvc/git/refs{/sha}","trees_url":"https://api.github.com/repos/aspnet/Mvc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/aspnet/Mvc/statuses/{sha}","languages_url":"https://api.github.com/repos/aspnet/Mvc/languages","stargazers_url":"https://api.github.com/repos/aspnet/Mvc/stargazers","contributors_url":"https://api.github.com/repos/aspnet/Mvc/contributors","subscribers_url":"https://api.github.com/repos/aspnet/Mvc/subscribers","subscription_url":"https://api.github.com/repos/aspnet/Mvc/subscription","commits_url":"https://api.github.com/repos/aspnet/Mvc/commits{/sha}","git_commits_url":"https://api.github.com/repos/aspnet/Mvc/git/commits{/sha}","comments_url":"https://api.github.com/repos/aspnet/Mvc/comments{/number}","issue_comment_url":"https://api.github.com/repos/aspnet/Mvc/issues/comments{/number}","contents_url":"https://api.github.com/repos/aspnet/Mvc/contents/{+path}","compare_url":"https://api.github.com/repos/aspnet/Mvc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/aspnet/Mvc/merges","archive_url":"https://api.github.com/repos/aspnet/Mvc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/aspnet/Mvc/downloads","issues_url":"https://api.github.com/repos/aspnet/Mvc/issues{/number}","pulls_url":"https://api.github.com/repos/aspnet/Mvc/pulls{/number}","milestones_url":"https://api.github.com/repos/aspnet/Mvc/milestones{/number}","notifications_url":"https://api.github.com/repos/aspnet/Mvc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/aspnet/Mvc/labels{/name}","releases_url":"https://api.github.com/repos/aspnet/Mvc/releases{/id}","deployments_url":"https://api.github.com/repos/aspnet/Mvc/deployments","created_at":"2013-12-12T03:54:00Z","updated_at":"2016-09-26T17:27:29Z","pushed_at":"2016-09-26T17:08:56Z","git_url":"git://github.com/aspnet/Mvc.git","ssh_url":"git@github.com:aspnet/Mvc.git","clone_url":"https://github.com/aspnet/Mvc.git","svn_url":"https://github.com/aspnet/Mvc","homepage":"","size":58750,"stargazers_count":3516,"watchers_count":3516,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1390,"mirror_url":null,"open_issues_count":377,"forks":1390,"open_issues":377,"watchers":3516,"default_branch":"dev"}},"_links":{"self":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/5318"},"html":{"href":"https://github.com/aspnet/Mvc/pull/5318"},"issue":{"href":"https://api.github.com/repos/aspnet/Mvc/issues/5318"},"comments":{"href":"https://api.github.com/repos/aspnet/Mvc/issues/5318/comments"},"review_comments":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/5318/comments"},"review_comment":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/5318/commits"},"statuses":{"href":"https://api.github.com/repos/aspnet/Mvc/statuses/93e35c5882516a81d363ee74c283b3a51778e92b"}}}}
{"actor":{"display_login":"Yves57"}}