{"action":"created","comment":{"url":"https://api.github.com/repos/google/auto/pulls/comments/23338152","id":23338152,"diff_hunk":"@@ -205,9 +243,40 @@ private static boolean equal(TypeMirror a, TypeMirror b, Set<ComparedElements> v\n     EqualVisitorParam p = new EqualVisitorParam();\n     p.type = b;\n     p.visiting = visiting;\n+    if (INTERSECTION_TYPE != null) {\n+      if (INTERSECTION_TYPE.isInstance(a)) {","path":"common/src/main/java/com/google/auto/common/MoreTypes.java","position":113,"original_position":113,"commit_id":"cddbcebd42c12d8e81d50c0bef50241d217f4274","original_commit_id":"cddbcebd42c12d8e81d50c0bef50241d217f4274","user":{"login":"JakeWharton","id":66577,"avatar_url":"https://avatars.githubusercontent.com/u/66577?v=3","gravatar_id":"","url":"https://api.github.com/users/JakeWharton","html_url":"https://github.com/JakeWharton","followers_url":"https://api.github.com/users/JakeWharton/followers","following_url":"https://api.github.com/users/JakeWharton/following{/other_user}","gists_url":"https://api.github.com/users/JakeWharton/gists{/gist_id}","starred_url":"https://api.github.com/users/JakeWharton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JakeWharton/subscriptions","organizations_url":"https://api.github.com/users/JakeWharton/orgs","repos_url":"https://api.github.com/users/JakeWharton/repos","events_url":"https://api.github.com/users/JakeWharton/events{/privacy}","received_events_url":"https://api.github.com/users/JakeWharton/received_events","type":"User","site_admin":false},"body":"On JavaWriter @tbroyer pointed out that the docs for `TypeMirror` discourage this.\r\n\r\n> To implement operations based on the class of an TypeMirror object, either use a visitor or use the result of the getKind() method. Using instanceof is not necessarily a reliable idiom for determining the effective class of an object in this modeling hierarchy since an implementation may choose to have a single object implement multiple TypeMirror subinterfaces.","created_at":"2015-01-21T21:58:19Z","updated_at":"2015-01-21T21:58:19Z","html_url":"https://github.com/google/auto/pull/175#discussion_r23338152","pull_request_url":"https://api.github.com/repos/google/auto/pulls/175","_links":{"self":{"href":"https://api.github.com/repos/google/auto/pulls/comments/23338152"},"html":{"href":"https://github.com/google/auto/pull/175#discussion_r23338152"},"pull_request":{"href":"https://api.github.com/repos/google/auto/pulls/175"}}},"pull_request":{"url":"https://api.github.com/repos/google/auto/pulls/175","id":27797976,"html_url":"https://github.com/google/auto/pull/175","diff_url":"https://github.com/google/auto/pull/175.diff","patch_url":"https://github.com/google/auto/pull/175.patch","issue_url":"https://api.github.com/repos/google/auto/issues/175","number":175,"state":"open","locked":false,"title":"Merge from google internal repository","user":{"login":"cgruber","id":331234,"avatar_url":"https://avatars.githubusercontent.com/u/331234?v=3","gravatar_id":"","url":"https://api.github.com/users/cgruber","html_url":"https://github.com/cgruber","followers_url":"https://api.github.com/users/cgruber/followers","following_url":"https://api.github.com/users/cgruber/following{/other_user}","gists_url":"https://api.github.com/users/cgruber/gists{/gist_id}","starred_url":"https://api.github.com/users/cgruber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cgruber/subscriptions","organizations_url":"https://api.github.com/users/cgruber/orgs","repos_url":"https://api.github.com/users/cgruber/repos","events_url":"https://api.github.com/users/cgruber/events{/privacy}","received_events_url":"https://api.github.com/users/cgruber/received_events","type":"User","site_admin":false},"body":"Changes include, primarily:\r\n\r\n  * AutoValue builders\r\n  * AnnotationValues, AnnotationMirrors utilities in common\r\n  * BasicAnnotationProcessor in common with validation and multi-round support for types which may not exist until those later rounds.\r\n  * Various fixes and improvements to auto common, notably around handling generics and union types. ","created_at":"2015-01-21T21:48:37Z","updated_at":"2015-01-21T21:58:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"dcdd4f5f644a420369ce692e4674c478363db52e","assignee":{"login":"eamonnmcmanus","id":5246810,"avatar_url":"https://avatars.githubusercontent.com/u/5246810?v=3","gravatar_id":"","url":"https://api.github.com/users/eamonnmcmanus","html_url":"https://github.com/eamonnmcmanus","followers_url":"https://api.github.com/users/eamonnmcmanus/followers","following_url":"https://api.github.com/users/eamonnmcmanus/following{/other_user}","gists_url":"https://api.github.com/users/eamonnmcmanus/gists{/gist_id}","starred_url":"https://api.github.com/users/eamonnmcmanus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eamonnmcmanus/subscriptions","organizations_url":"https://api.github.com/users/eamonnmcmanus/orgs","repos_url":"https://api.github.com/users/eamonnmcmanus/repos","events_url":"https://api.github.com/users/eamonnmcmanus/events{/privacy}","received_events_url":"https://api.github.com/users/eamonnmcmanus/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/google/auto/pulls/175/commits","review_comments_url":"https://api.github.com/repos/google/auto/pulls/175/comments","review_comment_url":"https://api.github.com/repos/google/auto/pulls/comments/{number}","comments_url":"https://api.github.com/repos/google/auto/issues/175/comments","statuses_url":"https://api.github.com/repos/google/auto/statuses/cddbcebd42c12d8e81d50c0bef50241d217f4274","head":{"label":"google:moe_writing_branch_from_449e92e4a7f035483fb938a689e286da8af749d2","ref":"moe_writing_branch_from_449e92e4a7f035483fb938a689e286da8af749d2","sha":"cddbcebd42c12d8e81d50c0bef50241d217f4274","user":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":10230369,"name":"auto","full_name":"google/auto","owner":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/google/auto","description":"A collection of source code generators for Java.","fork":false,"url":"https://api.github.com/repos/google/auto","forks_url":"https://api.github.com/repos/google/auto/forks","keys_url":"https://api.github.com/repos/google/auto/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/auto/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/auto/teams","hooks_url":"https://api.github.com/repos/google/auto/hooks","issue_events_url":"https://api.github.com/repos/google/auto/issues/events{/number}","events_url":"https://api.github.com/repos/google/auto/events","assignees_url":"https://api.github.com/repos/google/auto/assignees{/user}","branches_url":"https://api.github.com/repos/google/auto/branches{/branch}","tags_url":"https://api.github.com/repos/google/auto/tags","blobs_url":"https://api.github.com/repos/google/auto/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/auto/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/auto/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/auto/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/auto/statuses/{sha}","languages_url":"https://api.github.com/repos/google/auto/languages","stargazers_url":"https://api.github.com/repos/google/auto/stargazers","contributors_url":"https://api.github.com/repos/google/auto/contributors","subscribers_url":"https://api.github.com/repos/google/auto/subscribers","subscription_url":"https://api.github.com/repos/google/auto/subscription","commits_url":"https://api.github.com/repos/google/auto/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/auto/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/auto/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/auto/issues/comments/{number}","contents_url":"https://api.github.com/repos/google/auto/contents/{+path}","compare_url":"https://api.github.com/repos/google/auto/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/auto/merges","archive_url":"https://api.github.com/repos/google/auto/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/auto/downloads","issues_url":"https://api.github.com/repos/google/auto/issues{/number}","pulls_url":"https://api.github.com/repos/google/auto/pulls{/number}","milestones_url":"https://api.github.com/repos/google/auto/milestones{/number}","notifications_url":"https://api.github.com/repos/google/auto/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/auto/labels{/name}","releases_url":"https://api.github.com/repos/google/auto/releases{/id}","created_at":"2013-05-22T21:41:56Z","updated_at":"2015-01-21T14:33:57Z","pushed_at":"2015-01-21T21:46:24Z","git_url":"git://github.com/google/auto.git","ssh_url":"git@github.com:google/auto.git","clone_url":"https://github.com/google/auto.git","svn_url":"https://github.com/google/auto","homepage":"","size":1965,"stargazers_count":921,"watchers_count":921,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":139,"mirror_url":null,"open_issues_count":52,"forks":139,"open_issues":52,"watchers":921,"default_branch":"master"}},"base":{"label":"google:master","ref":"master","sha":"51725d66ec2abd26f8df165bb98f2d8122d4e324","user":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":10230369,"name":"auto","full_name":"google/auto","owner":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/google/auto","description":"A collection of source code generators for Java.","fork":false,"url":"https://api.github.com/repos/google/auto","forks_url":"https://api.github.com/repos/google/auto/forks","keys_url":"https://api.github.com/repos/google/auto/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/auto/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/auto/teams","hooks_url":"https://api.github.com/repos/google/auto/hooks","issue_events_url":"https://api.github.com/repos/google/auto/issues/events{/number}","events_url":"https://api.github.com/repos/google/auto/events","assignees_url":"https://api.github.com/repos/google/auto/assignees{/user}","branches_url":"https://api.github.com/repos/google/auto/branches{/branch}","tags_url":"https://api.github.com/repos/google/auto/tags","blobs_url":"https://api.github.com/repos/google/auto/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/auto/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/auto/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/auto/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/auto/statuses/{sha}","languages_url":"https://api.github.com/repos/google/auto/languages","stargazers_url":"https://api.github.com/repos/google/auto/stargazers","contributors_url":"https://api.github.com/repos/google/auto/contributors","subscribers_url":"https://api.github.com/repos/google/auto/subscribers","subscription_url":"https://api.github.com/repos/google/auto/subscription","commits_url":"https://api.github.com/repos/google/auto/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/auto/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/auto/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/auto/issues/comments/{number}","contents_url":"https://api.github.com/repos/google/auto/contents/{+path}","compare_url":"https://api.github.com/repos/google/auto/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/auto/merges","archive_url":"https://api.github.com/repos/google/auto/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/auto/downloads","issues_url":"https://api.github.com/repos/google/auto/issues{/number}","pulls_url":"https://api.github.com/repos/google/auto/pulls{/number}","milestones_url":"https://api.github.com/repos/google/auto/milestones{/number}","notifications_url":"https://api.github.com/repos/google/auto/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/auto/labels{/name}","releases_url":"https://api.github.com/repos/google/auto/releases{/id}","created_at":"2013-05-22T21:41:56Z","updated_at":"2015-01-21T14:33:57Z","pushed_at":"2015-01-21T21:46:24Z","git_url":"git://github.com/google/auto.git","ssh_url":"git@github.com:google/auto.git","clone_url":"https://github.com/google/auto.git","svn_url":"https://github.com/google/auto","homepage":"","size":1965,"stargazers_count":921,"watchers_count":921,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":139,"mirror_url":null,"open_issues_count":52,"forks":139,"open_issues":52,"watchers":921,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/google/auto/pulls/175"},"html":{"href":"https://github.com/google/auto/pull/175"},"issue":{"href":"https://api.github.com/repos/google/auto/issues/175"},"comments":{"href":"https://api.github.com/repos/google/auto/issues/175/comments"},"review_comments":{"href":"https://api.github.com/repos/google/auto/pulls/175/comments"},"review_comment":{"href":"https://api.github.com/repos/google/auto/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/google/auto/pulls/175/commits"},"statuses":{"href":"https://api.github.com/repos/google/auto/statuses/cddbcebd42c12d8e81d50c0bef50241d217f4274"}}}}