{"action":"created","comment":{"url":"https://api.github.com/repos/dotnet/roslyn/pulls/comments/77398896","id":77398896,"diff_hunk":"@@ -167,23 +172,50 @@ Namespace Microsoft.CodeAnalysis.VisualBasic.Symbols\n                 End Get\n             End Property\n \n-            Public Overrides ReadOnly Property SpecialType As SpecialType\n+            Private ReadOnly Property TypeId As Integer\n                 Get\n                     If _lazyTypeId = -1 Then\n-                        Dim typeId As SpecialType = SpecialType.None\n+                        Dim computedTypeId As SpecialType = SpecialType.None\n                         Dim containingAssembly As AssemblySymbol = _containingModule.ContainingAssembly\n \n                         If (Arity = 0 OrElse MangleName) AndAlso\n                            containingAssembly IsNot Nothing AndAlso containingAssembly Is containingAssembly.CorLibrary AndAlso _containingModule.Ordinal = 0 Then\n                             ' Check the name \n                             Dim emittedName As String = MetadataHelpers.BuildQualifiedName(_namespaceName, MetadataName)\n-                            typeId = SpecialTypes.GetTypeFromMetadataName(emittedName)\n+                            computedTypeId = SpecialTypes.GetTypeFromMetadataName(emittedName)\n                         End If\n \n-                        Interlocked.CompareExchange(_lazyTypeId, typeId, -1)\n+                        Interlocked.CompareExchange(_lazyTypeId, computedTypeId, -1)\n                     End If\n \n-                    Return CType(_lazyTypeId, SpecialType)\n+                    Return _lazyTypeId\n+                End Get\n+            End Property\n+\n+            Public Overrides ReadOnly Property SpecialType As SpecialType\n+                Get\n+                    Dim typeId As Integer = Me.TypeId()\n+                    Return If(typeId >= WellKnownType.First, SpecialType.None, CType(_lazyTypeId, SpecialType))\n+                End Get\n+            End Property\n+\n+            Friend Overrides ReadOnly Property ErrorInfo As DiagnosticInfo\n+                Get\n+                    Select Case Me.TypeId()","path":"src/Compilers/VisualBasic/Portable/Symbols/MissingMetadataTypeSymbol.vb","position":50,"original_position":50,"commit_id":"4ee926febf6829addbc446d8503e55270f718ccb","original_commit_id":"4ee926febf6829addbc446d8503e55270f718ccb","user":{"login":"jcouv","id":12466233,"avatar_url":"https://avatars.githubusercontent.com/u/12466233?v=3","gravatar_id":"","url":"https://api.github.com/users/jcouv","html_url":"https://github.com/jcouv","followers_url":"https://api.github.com/users/jcouv/followers","following_url":"https://api.github.com/users/jcouv/following{/other_user}","gists_url":"https://api.github.com/users/jcouv/gists{/gist_id}","starred_url":"https://api.github.com/users/jcouv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jcouv/subscriptions","organizations_url":"https://api.github.com/users/jcouv/orgs","repos_url":"https://api.github.com/users/jcouv/repos","events_url":"https://api.github.com/users/jcouv/events{/privacy}","received_events_url":"https://api.github.com/users/jcouv/received_events","type":"User","site_admin":false},"body":"Removed","created_at":"2016-09-02T19:17:36Z","updated_at":"2016-09-02T19:17:36Z","html_url":"https://github.com/dotnet/roslyn/pull/13542#discussion_r77398896","pull_request_url":"https://api.github.com/repos/dotnet/roslyn/pulls/13542","_links":{"self":{"href":"https://api.github.com/repos/dotnet/roslyn/pulls/comments/77398896"},"html":{"href":"https://github.com/dotnet/roslyn/pull/13542#discussion_r77398896"},"pull_request":{"href":"https://api.github.com/repos/dotnet/roslyn/pulls/13542"}}},"pull_request":{"url":"https://api.github.com/repos/dotnet/roslyn/pulls/13542","id":83703678,"html_url":"https://github.com/dotnet/roslyn/pull/13542","diff_url":"https://github.com/dotnet/roslyn/pull/13542.diff","patch_url":"https://github.com/dotnet/roslyn/pull/13542.patch","issue_url":"https://api.github.com/repos/dotnet/roslyn/issues/13542","number":13542,"state":"open","locked":false,"title":"Missing ValueTuple in VB should report a distinct error code","user":{"login":"jcouv","id":12466233,"avatar_url":"https://avatars.githubusercontent.com/u/12466233?v=3","gravatar_id":"","url":"https://api.github.com/users/jcouv","html_url":"https://github.com/jcouv","followers_url":"https://api.github.com/users/jcouv/followers","following_url":"https://api.github.com/users/jcouv/following{/other_user}","gists_url":"https://api.github.com/users/jcouv/gists{/gist_id}","starred_url":"https://api.github.com/users/jcouv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jcouv/subscriptions","organizations_url":"https://api.github.com/users/jcouv/orgs","repos_url":"https://api.github.com/users/jcouv/repos","events_url":"https://api.github.com/users/jcouv/events{/privacy}","received_events_url":"https://api.github.com/users/jcouv/received_events","type":"User","site_admin":false},"body":"This is the VB change corresponding to https://github.com/dotnet/roslyn/pull/13511. The purpose is to report a distinct error code so that Cyrus's code fixer can trigger easily and recommend to add the ValueTuple nuget package.\r\n\r\nThe change is modeled after the C# code: the `MissingMetadataTypeSymbol.TopLevel._lazyTypeId` field can now hold an integer that either represents a well-known type or a special type (previously it was only holding a value for special types). This field can be accessed via `TypeId` (which factors some existing code out) or `SpecialType` properties (which was simplified).\r\n\r\nAs a side-note, I noticed `ERRID.ERR_InvalidInstrumentationKind` was using a duplicate error code. I fixed it, but was surprised there was no test regression. @drognanar @JohnHamby Please take a look and add appropriate tests for this error code.\r\n\r\n@dotnet/roslyn-compiler for review.\r\nFYI for @CyrusNajmabadi \r\nRelates to https://github.com/dotnet/roslyn/issues/13375","created_at":"2016-09-01T20:45:34Z","updated_at":"2016-09-02T19:17:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fd75f3b80fc06e00fab6995a9052ab4c969d6942","assignee":{"login":"jcouv","id":12466233,"avatar_url":"https://avatars.githubusercontent.com/u/12466233?v=3","gravatar_id":"","url":"https://api.github.com/users/jcouv","html_url":"https://github.com/jcouv","followers_url":"https://api.github.com/users/jcouv/followers","following_url":"https://api.github.com/users/jcouv/following{/other_user}","gists_url":"https://api.github.com/users/jcouv/gists{/gist_id}","starred_url":"https://api.github.com/users/jcouv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jcouv/subscriptions","organizations_url":"https://api.github.com/users/jcouv/orgs","repos_url":"https://api.github.com/users/jcouv/repos","events_url":"https://api.github.com/users/jcouv/events{/privacy}","received_events_url":"https://api.github.com/users/jcouv/received_events","type":"User","site_admin":false},"assignees":[{"login":"jcouv","id":12466233,"avatar_url":"https://avatars.githubusercontent.com/u/12466233?v=3","gravatar_id":"","url":"https://api.github.com/users/jcouv","html_url":"https://github.com/jcouv","followers_url":"https://api.github.com/users/jcouv/followers","following_url":"https://api.github.com/users/jcouv/following{/other_user}","gists_url":"https://api.github.com/users/jcouv/gists{/gist_id}","starred_url":"https://api.github.com/users/jcouv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jcouv/subscriptions","organizations_url":"https://api.github.com/users/jcouv/orgs","repos_url":"https://api.github.com/users/jcouv/repos","events_url":"https://api.github.com/users/jcouv/events{/privacy}","received_events_url":"https://api.github.com/users/jcouv/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/dotnet/roslyn/milestones/15","html_url":"https://github.com/dotnet/roslyn/milestones/2.0%20(Preview%205)","labels_url":"https://api.github.com/repos/dotnet/roslyn/milestones/15/labels","id":1571383,"number":15,"title":"2.0 (Preview 5)","description":"","creator":{"login":"davkean","id":1103906,"avatar_url":"https://avatars.githubusercontent.com/u/1103906?v=3","gravatar_id":"","url":"https://api.github.com/users/davkean","html_url":"https://github.com/davkean","followers_url":"https://api.github.com/users/davkean/followers","following_url":"https://api.github.com/users/davkean/following{/other_user}","gists_url":"https://api.github.com/users/davkean/gists{/gist_id}","starred_url":"https://api.github.com/users/davkean/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davkean/subscriptions","organizations_url":"https://api.github.com/users/davkean/orgs","repos_url":"https://api.github.com/users/davkean/repos","events_url":"https://api.github.com/users/davkean/events{/privacy}","received_events_url":"https://api.github.com/users/davkean/received_events","type":"User","site_admin":false},"open_issues":812,"closed_issues":353,"state":"open","created_at":"2016-02-08T21:53:59Z","updated_at":"2016-09-02T18:51:14Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/dotnet/roslyn/pulls/13542/commits","review_comments_url":"https://api.github.com/repos/dotnet/roslyn/pulls/13542/comments","review_comment_url":"https://api.github.com/repos/dotnet/roslyn/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dotnet/roslyn/issues/13542/comments","statuses_url":"https://api.github.com/repos/dotnet/roslyn/statuses/4ee926febf6829addbc446d8503e55270f718ccb","head":{"label":"jcouv:error-code","ref":"error-code","sha":"4ee926febf6829addbc446d8503e55270f718ccb","user":{"login":"jcouv","id":12466233,"avatar_url":"https://avatars.githubusercontent.com/u/12466233?v=3","gravatar_id":"","url":"https://api.github.com/users/jcouv","html_url":"https://github.com/jcouv","followers_url":"https://api.github.com/users/jcouv/followers","following_url":"https://api.github.com/users/jcouv/following{/other_user}","gists_url":"https://api.github.com/users/jcouv/gists{/gist_id}","starred_url":"https://api.github.com/users/jcouv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jcouv/subscriptions","organizations_url":"https://api.github.com/users/jcouv/orgs","repos_url":"https://api.github.com/users/jcouv/repos","events_url":"https://api.github.com/users/jcouv/events{/privacy}","received_events_url":"https://api.github.com/users/jcouv/received_events","type":"User","site_admin":false},"repo":{"id":50162064,"name":"roslyn","full_name":"jcouv/roslyn","owner":{"login":"jcouv","id":12466233,"avatar_url":"https://avatars.githubusercontent.com/u/12466233?v=3","gravatar_id":"","url":"https://api.github.com/users/jcouv","html_url":"https://github.com/jcouv","followers_url":"https://api.github.com/users/jcouv/followers","following_url":"https://api.github.com/users/jcouv/following{/other_user}","gists_url":"https://api.github.com/users/jcouv/gists{/gist_id}","starred_url":"https://api.github.com/users/jcouv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jcouv/subscriptions","organizations_url":"https://api.github.com/users/jcouv/orgs","repos_url":"https://api.github.com/users/jcouv/repos","events_url":"https://api.github.com/users/jcouv/events{/privacy}","received_events_url":"https://api.github.com/users/jcouv/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jcouv/roslyn","description":"The .NET Compiler Platform (\"Roslyn\") provides open-source C# and Visual Basic compilers with rich code analysis APIs.","fork":true,"url":"https://api.github.com/repos/jcouv/roslyn","forks_url":"https://api.github.com/repos/jcouv/roslyn/forks","keys_url":"https://api.github.com/repos/jcouv/roslyn/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jcouv/roslyn/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jcouv/roslyn/teams","hooks_url":"https://api.github.com/repos/jcouv/roslyn/hooks","issue_events_url":"https://api.github.com/repos/jcouv/roslyn/issues/events{/number}","events_url":"https://api.github.com/repos/jcouv/roslyn/events","assignees_url":"https://api.github.com/repos/jcouv/roslyn/assignees{/user}","branches_url":"https://api.github.com/repos/jcouv/roslyn/branches{/branch}","tags_url":"https://api.github.com/repos/jcouv/roslyn/tags","blobs_url":"https://api.github.com/repos/jcouv/roslyn/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jcouv/roslyn/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jcouv/roslyn/git/refs{/sha}","trees_url":"https://api.github.com/repos/jcouv/roslyn/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jcouv/roslyn/statuses/{sha}","languages_url":"https://api.github.com/repos/jcouv/roslyn/languages","stargazers_url":"https://api.github.com/repos/jcouv/roslyn/stargazers","contributors_url":"https://api.github.com/repos/jcouv/roslyn/contributors","subscribers_url":"https://api.github.com/repos/jcouv/roslyn/subscribers","subscription_url":"https://api.github.com/repos/jcouv/roslyn/subscription","commits_url":"https://api.github.com/repos/jcouv/roslyn/commits{/sha}","git_commits_url":"https://api.github.com/repos/jcouv/roslyn/git/commits{/sha}","comments_url":"https://api.github.com/repos/jcouv/roslyn/comments{/number}","issue_comment_url":"https://api.github.com/repos/jcouv/roslyn/issues/comments{/number}","contents_url":"https://api.github.com/repos/jcouv/roslyn/contents/{+path}","compare_url":"https://api.github.com/repos/jcouv/roslyn/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jcouv/roslyn/merges","archive_url":"https://api.github.com/repos/jcouv/roslyn/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jcouv/roslyn/downloads","issues_url":"https://api.github.com/repos/jcouv/roslyn/issues{/number}","pulls_url":"https://api.github.com/repos/jcouv/roslyn/pulls{/number}","milestones_url":"https://api.github.com/repos/jcouv/roslyn/milestones{/number}","notifications_url":"https://api.github.com/repos/jcouv/roslyn/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jcouv/roslyn/labels{/name}","releases_url":"https://api.github.com/repos/jcouv/roslyn/releases{/id}","deployments_url":"https://api.github.com/repos/jcouv/roslyn/deployments","created_at":"2016-01-22T06:19:22Z","updated_at":"2016-01-22T06:19:52Z","pushed_at":"2016-09-02T18:43:35Z","git_url":"git://github.com/jcouv/roslyn.git","ssh_url":"git@github.com:jcouv/roslyn.git","clone_url":"https://github.com/jcouv/roslyn.git","svn_url":"https://github.com/jcouv/roslyn","homepage":"","size":174179,"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":"master"}},"base":{"label":"dotnet:master","ref":"master","sha":"dc423d15a1b60225d6af3e52ddcb334a619bdc49","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":29078997,"name":"roslyn","full_name":"dotnet/roslyn","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/roslyn","description":"The .NET Compiler Platform (\"Roslyn\") provides open-source C# and Visual Basic compilers with rich code analysis APIs.","fork":false,"url":"https://api.github.com/repos/dotnet/roslyn","forks_url":"https://api.github.com/repos/dotnet/roslyn/forks","keys_url":"https://api.github.com/repos/dotnet/roslyn/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dotnet/roslyn/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dotnet/roslyn/teams","hooks_url":"https://api.github.com/repos/dotnet/roslyn/hooks","issue_events_url":"https://api.github.com/repos/dotnet/roslyn/issues/events{/number}","events_url":"https://api.github.com/repos/dotnet/roslyn/events","assignees_url":"https://api.github.com/repos/dotnet/roslyn/assignees{/user}","branches_url":"https://api.github.com/repos/dotnet/roslyn/branches{/branch}","tags_url":"https://api.github.com/repos/dotnet/roslyn/tags","blobs_url":"https://api.github.com/repos/dotnet/roslyn/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dotnet/roslyn/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dotnet/roslyn/git/refs{/sha}","trees_url":"https://api.github.com/repos/dotnet/roslyn/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dotnet/roslyn/statuses/{sha}","languages_url":"https://api.github.com/repos/dotnet/roslyn/languages","stargazers_url":"https://api.github.com/repos/dotnet/roslyn/stargazers","contributors_url":"https://api.github.com/repos/dotnet/roslyn/contributors","subscribers_url":"https://api.github.com/repos/dotnet/roslyn/subscribers","subscription_url":"https://api.github.com/repos/dotnet/roslyn/subscription","commits_url":"https://api.github.com/repos/dotnet/roslyn/commits{/sha}","git_commits_url":"https://api.github.com/repos/dotnet/roslyn/git/commits{/sha}","comments_url":"https://api.github.com/repos/dotnet/roslyn/comments{/number}","issue_comment_url":"https://api.github.com/repos/dotnet/roslyn/issues/comments{/number}","contents_url":"https://api.github.com/repos/dotnet/roslyn/contents/{+path}","compare_url":"https://api.github.com/repos/dotnet/roslyn/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dotnet/roslyn/merges","archive_url":"https://api.github.com/repos/dotnet/roslyn/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dotnet/roslyn/downloads","issues_url":"https://api.github.com/repos/dotnet/roslyn/issues{/number}","pulls_url":"https://api.github.com/repos/dotnet/roslyn/pulls{/number}","milestones_url":"https://api.github.com/repos/dotnet/roslyn/milestones{/number}","notifications_url":"https://api.github.com/repos/dotnet/roslyn/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dotnet/roslyn/labels{/name}","releases_url":"https://api.github.com/repos/dotnet/roslyn/releases{/id}","deployments_url":"https://api.github.com/repos/dotnet/roslyn/deployments","created_at":"2015-01-11T02:39:03Z","updated_at":"2016-09-02T14:54:58Z","pushed_at":"2016-09-02T19:12:17Z","git_url":"git://github.com/dotnet/roslyn.git","ssh_url":"git@github.com:dotnet/roslyn.git","clone_url":"https://github.com/dotnet/roslyn.git","svn_url":"https://github.com/dotnet/roslyn","homepage":"","size":330580,"stargazers_count":6143,"watchers_count":6143,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1471,"mirror_url":null,"open_issues_count":3167,"forks":1471,"open_issues":3167,"watchers":6143,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dotnet/roslyn/pulls/13542"},"html":{"href":"https://github.com/dotnet/roslyn/pull/13542"},"issue":{"href":"https://api.github.com/repos/dotnet/roslyn/issues/13542"},"comments":{"href":"https://api.github.com/repos/dotnet/roslyn/issues/13542/comments"},"review_comments":{"href":"https://api.github.com/repos/dotnet/roslyn/pulls/13542/comments"},"review_comment":{"href":"https://api.github.com/repos/dotnet/roslyn/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dotnet/roslyn/pulls/13542/commits"},"statuses":{"href":"https://api.github.com/repos/dotnet/roslyn/statuses/4ee926febf6829addbc446d8503e55270f718ccb"}}}}
{"actor":{"display_login":"jcouv"}}