{"action":"created","comment":{"url":"https://api.github.com/repos/dotnet/codeformatter/pulls/comments/28283251","id":28283251,"diff_hunk":"@@ -0,0 +1,55 @@\n+// Copyright (c) Microsoft. All rights reserved.\n+// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n+\n+using Microsoft.CodeAnalysis;\n+\n+namespace Microsoft.DotNet.CodeFormatting\n+{\n+    /// <summary>\n+    /// Commonly used name functions\n+    /// </summary>\n+    internal static class NameHelper\n+    {\n+        /// <summary>\n+        /// Get the full name of a symbol. So a field might look like\n+        /// \"OuterNamespace.Inner.ClassName.FieldName\"\n+        /// </summary>\n+        /// <param name=\"symbol\">symbol to get name of</param>\n+        /// <returns>Full display name for a symbol</returns>\n+        internal static string GetFullName(ISymbol symbol)\n+        {\n+            return GetFullName(symbol.ContainingType) + \".\" + symbol.Name;","path":"src/Microsoft.DotNet.CodeFormatting/NameHelper.cs","position":21,"original_position":21,"commit_id":"011326bf944ec310dbae54e1a93cde4ee275b473","original_commit_id":"011326bf944ec310dbae54e1a93cde4ee275b473","user":{"login":"jaredpar","id":146967,"avatar_url":"https://avatars.githubusercontent.com/u/146967?v=3","gravatar_id":"","url":"https://api.github.com/users/jaredpar","html_url":"https://github.com/jaredpar","followers_url":"https://api.github.com/users/jaredpar/followers","following_url":"https://api.github.com/users/jaredpar/following{/other_user}","gists_url":"https://api.github.com/users/jaredpar/gists{/gist_id}","starred_url":"https://api.github.com/users/jaredpar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaredpar/subscriptions","organizations_url":"https://api.github.com/users/jaredpar/orgs","repos_url":"https://api.github.com/users/jaredpar/repos","events_url":"https://api.github.com/users/jaredpar/events{/privacy}","received_events_url":"https://api.github.com/users/jaredpar/received_events","type":"User","site_admin":false},"body":"Don't believe this will work for nested types.  They should use `+` instead of `.`","created_at":"2015-04-13T21:54:06Z","updated_at":"2015-04-13T21:54:06Z","html_url":"https://github.com/dotnet/codeformatter/pull/109#discussion_r28283251","pull_request_url":"https://api.github.com/repos/dotnet/codeformatter/pulls/109","_links":{"self":{"href":"https://api.github.com/repos/dotnet/codeformatter/pulls/comments/28283251"},"html":{"href":"https://github.com/dotnet/codeformatter/pull/109#discussion_r28283251"},"pull_request":{"href":"https://api.github.com/repos/dotnet/codeformatter/pulls/109"}}},"pull_request":{"url":"https://api.github.com/repos/dotnet/codeformatter/pulls/109","id":33184343,"html_url":"https://github.com/dotnet/codeformatter/pull/109","diff_url":"https://github.com/dotnet/codeformatter/pull/109.diff","patch_url":"https://github.com/dotnet/codeformatter/pull/109.patch","issue_url":"https://api.github.com/repos/dotnet/codeformatter/issues/109","number":109,"state":"open","locked":false,"title":"Readonly field formatter","user":{"login":"ChadNedzlek","id":11790765,"avatar_url":"https://avatars.githubusercontent.com/u/11790765?v=3","gravatar_id":"","url":"https://api.github.com/users/ChadNedzlek","html_url":"https://github.com/ChadNedzlek","followers_url":"https://api.github.com/users/ChadNedzlek/followers","following_url":"https://api.github.com/users/ChadNedzlek/following{/other_user}","gists_url":"https://api.github.com/users/ChadNedzlek/gists{/gist_id}","starred_url":"https://api.github.com/users/ChadNedzlek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ChadNedzlek/subscriptions","organizations_url":"https://api.github.com/users/ChadNedzlek/orgs","repos_url":"https://api.github.com/users/ChadNedzlek/repos","events_url":"https://api.github.com/users/ChadNedzlek/events{/privacy}","received_events_url":"https://api.github.com/users/ChadNedzlek/received_events","type":"User","site_admin":false},"body":"Add the readonly keyword to fields that are provably never written\r\nto. Only mark private and internal fields, and the following\r\nare considered \"writing\" to a field:\r\n\r\n- Assignments (_field = 5)\r\n- Compound assignments (_field += 5)\r\n- ref/out calls (Method(ref _field))\r\n- ref of parent to extern method. While not technically required\r\n  the fields can possibly change (even when marked readonly)\r\n- internal fields that are exposed via InternalsVisibleTo an\r\n  assembly that is not in the input project\r\n\r\nFix #104","created_at":"2015-04-13T17:24:39Z","updated_at":"2015-04-13T21:54:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fe55e181d45149a236aae4ae35900bf85fbf904b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/dotnet/codeformatter/pulls/109/commits","review_comments_url":"https://api.github.com/repos/dotnet/codeformatter/pulls/109/comments","review_comment_url":"https://api.github.com/repos/dotnet/codeformatter/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dotnet/codeformatter/issues/109/comments","statuses_url":"https://api.github.com/repos/dotnet/codeformatter/statuses/011326bf944ec310dbae54e1a93cde4ee275b473","head":{"label":"ChadNedzlek:readonly-field-submit","ref":"readonly-field-submit","sha":"011326bf944ec310dbae54e1a93cde4ee275b473","user":{"login":"ChadNedzlek","id":11790765,"avatar_url":"https://avatars.githubusercontent.com/u/11790765?v=3","gravatar_id":"","url":"https://api.github.com/users/ChadNedzlek","html_url":"https://github.com/ChadNedzlek","followers_url":"https://api.github.com/users/ChadNedzlek/followers","following_url":"https://api.github.com/users/ChadNedzlek/following{/other_user}","gists_url":"https://api.github.com/users/ChadNedzlek/gists{/gist_id}","starred_url":"https://api.github.com/users/ChadNedzlek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ChadNedzlek/subscriptions","organizations_url":"https://api.github.com/users/ChadNedzlek/orgs","repos_url":"https://api.github.com/users/ChadNedzlek/repos","events_url":"https://api.github.com/users/ChadNedzlek/events{/privacy}","received_events_url":"https://api.github.com/users/ChadNedzlek/received_events","type":"User","site_admin":false},"repo":{"id":33525606,"name":"codeformatter","full_name":"ChadNedzlek/codeformatter","owner":{"login":"ChadNedzlek","id":11790765,"avatar_url":"https://avatars.githubusercontent.com/u/11790765?v=3","gravatar_id":"","url":"https://api.github.com/users/ChadNedzlek","html_url":"https://github.com/ChadNedzlek","followers_url":"https://api.github.com/users/ChadNedzlek/followers","following_url":"https://api.github.com/users/ChadNedzlek/following{/other_user}","gists_url":"https://api.github.com/users/ChadNedzlek/gists{/gist_id}","starred_url":"https://api.github.com/users/ChadNedzlek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ChadNedzlek/subscriptions","organizations_url":"https://api.github.com/users/ChadNedzlek/orgs","repos_url":"https://api.github.com/users/ChadNedzlek/repos","events_url":"https://api.github.com/users/ChadNedzlek/events{/privacy}","received_events_url":"https://api.github.com/users/ChadNedzlek/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ChadNedzlek/codeformatter","description":"Tool that uses Roslyn to automatically rewrite the source to follow our coding styles","fork":true,"url":"https://api.github.com/repos/ChadNedzlek/codeformatter","forks_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/forks","keys_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/teams","hooks_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/hooks","issue_events_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/issues/events{/number}","events_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/events","assignees_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/assignees{/user}","branches_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/branches{/branch}","tags_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/tags","blobs_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/git/refs{/sha}","trees_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/statuses/{sha}","languages_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/languages","stargazers_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/stargazers","contributors_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/contributors","subscribers_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/subscribers","subscription_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/subscription","commits_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/commits{/sha}","git_commits_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/git/commits{/sha}","comments_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/comments{/number}","issue_comment_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/issues/comments{/number}","contents_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/contents/{+path}","compare_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/merges","archive_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/downloads","issues_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/issues{/number}","pulls_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/pulls{/number}","milestones_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/milestones{/number}","notifications_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/labels{/name}","releases_url":"https://api.github.com/repos/ChadNedzlek/codeformatter/releases{/id}","created_at":"2015-04-07T06:13:34Z","updated_at":"2015-04-09T01:31:54Z","pushed_at":"2015-04-13T21:42:51Z","git_url":"git://github.com/ChadNedzlek/codeformatter.git","ssh_url":"git@github.com:ChadNedzlek/codeformatter.git","clone_url":"https://github.com/ChadNedzlek/codeformatter.git","svn_url":"https://github.com/ChadNedzlek/codeformatter","homepage":"","size":612,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":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":"dotnet:master","ref":"master","sha":"0ac40694d26ae8afd653a794cbe9fd56ef189a7b","user":{"login":"dotnet","id":9141961,"avatar_url":"https://avatars.githubusercontent.com/u/9141961?v=3","gravatar_id":"","url":"https://api.github.com/users/dotnet","html_url":"https://github.com/dotnet","followers_url":"https://api.github.com/users/dotnet/followers","following_url":"https://api.github.com/users/dotnet/following{/other_user}","gists_url":"https://api.github.com/users/dotnet/gists{/gist_id}","starred_url":"https://api.github.com/users/dotnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dotnet/subscriptions","organizations_url":"https://api.github.com/users/dotnet/orgs","repos_url":"https://api.github.com/users/dotnet/repos","events_url":"https://api.github.com/users/dotnet/events{/privacy}","received_events_url":"https://api.github.com/users/dotnet/received_events","type":"Organization","site_admin":false},"repo":{"id":28896487,"name":"codeformatter","full_name":"dotnet/codeformatter","owner":{"login":"dotnet","id":9141961,"avatar_url":"https://avatars.githubusercontent.com/u/9141961?v=3","gravatar_id":"","url":"https://api.github.com/users/dotnet","html_url":"https://github.com/dotnet","followers_url":"https://api.github.com/users/dotnet/followers","following_url":"https://api.github.com/users/dotnet/following{/other_user}","gists_url":"https://api.github.com/users/dotnet/gists{/gist_id}","starred_url":"https://api.github.com/users/dotnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dotnet/subscriptions","organizations_url":"https://api.github.com/users/dotnet/orgs","repos_url":"https://api.github.com/users/dotnet/repos","events_url":"https://api.github.com/users/dotnet/events{/privacy}","received_events_url":"https://api.github.com/users/dotnet/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dotnet/codeformatter","description":"Tool that uses Roslyn to automatically rewrite the source to follow our coding styles","fork":false,"url":"https://api.github.com/repos/dotnet/codeformatter","forks_url":"https://api.github.com/repos/dotnet/codeformatter/forks","keys_url":"https://api.github.com/repos/dotnet/codeformatter/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dotnet/codeformatter/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dotnet/codeformatter/teams","hooks_url":"https://api.github.com/repos/dotnet/codeformatter/hooks","issue_events_url":"https://api.github.com/repos/dotnet/codeformatter/issues/events{/number}","events_url":"https://api.github.com/repos/dotnet/codeformatter/events","assignees_url":"https://api.github.com/repos/dotnet/codeformatter/assignees{/user}","branches_url":"https://api.github.com/repos/dotnet/codeformatter/branches{/branch}","tags_url":"https://api.github.com/repos/dotnet/codeformatter/tags","blobs_url":"https://api.github.com/repos/dotnet/codeformatter/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dotnet/codeformatter/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dotnet/codeformatter/git/refs{/sha}","trees_url":"https://api.github.com/repos/dotnet/codeformatter/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dotnet/codeformatter/statuses/{sha}","languages_url":"https://api.github.com/repos/dotnet/codeformatter/languages","stargazers_url":"https://api.github.com/repos/dotnet/codeformatter/stargazers","contributors_url":"https://api.github.com/repos/dotnet/codeformatter/contributors","subscribers_url":"https://api.github.com/repos/dotnet/codeformatter/subscribers","subscription_url":"https://api.github.com/repos/dotnet/codeformatter/subscription","commits_url":"https://api.github.com/repos/dotnet/codeformatter/commits{/sha}","git_commits_url":"https://api.github.com/repos/dotnet/codeformatter/git/commits{/sha}","comments_url":"https://api.github.com/repos/dotnet/codeformatter/comments{/number}","issue_comment_url":"https://api.github.com/repos/dotnet/codeformatter/issues/comments{/number}","contents_url":"https://api.github.com/repos/dotnet/codeformatter/contents/{+path}","compare_url":"https://api.github.com/repos/dotnet/codeformatter/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dotnet/codeformatter/merges","archive_url":"https://api.github.com/repos/dotnet/codeformatter/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dotnet/codeformatter/downloads","issues_url":"https://api.github.com/repos/dotnet/codeformatter/issues{/number}","pulls_url":"https://api.github.com/repos/dotnet/codeformatter/pulls{/number}","milestones_url":"https://api.github.com/repos/dotnet/codeformatter/milestones{/number}","notifications_url":"https://api.github.com/repos/dotnet/codeformatter/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dotnet/codeformatter/labels{/name}","releases_url":"https://api.github.com/repos/dotnet/codeformatter/releases{/id}","created_at":"2015-01-07T03:28:44Z","updated_at":"2015-04-11T21:10:01Z","pushed_at":"2015-04-13T21:42:51Z","git_url":"git://github.com/dotnet/codeformatter.git","ssh_url":"git@github.com:dotnet/codeformatter.git","clone_url":"https://github.com/dotnet/codeformatter.git","svn_url":"https://github.com/dotnet/codeformatter","homepage":"","size":1776,"stargazers_count":360,"watchers_count":360,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":50,"mirror_url":null,"open_issues_count":35,"forks":50,"open_issues":35,"watchers":360,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dotnet/codeformatter/pulls/109"},"html":{"href":"https://github.com/dotnet/codeformatter/pull/109"},"issue":{"href":"https://api.github.com/repos/dotnet/codeformatter/issues/109"},"comments":{"href":"https://api.github.com/repos/dotnet/codeformatter/issues/109/comments"},"review_comments":{"href":"https://api.github.com/repos/dotnet/codeformatter/pulls/109/comments"},"review_comment":{"href":"https://api.github.com/repos/dotnet/codeformatter/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dotnet/codeformatter/pulls/109/commits"},"statuses":{"href":"https://api.github.com/repos/dotnet/codeformatter/statuses/011326bf944ec310dbae54e1a93cde4ee275b473"}}}}