{"action":"created","comment":{"url":"https://api.github.com/repos/scala/scala/pulls/comments/57827520","id":57827520,"diff_hunk":"@@ -373,4 +373,32 @@ trait Erasure {\n       specialErasure(sym)(tp)\n     }\n   }\n+\n+  /** Does this symbol compile to the underlying platform's notion of an interface,\n+    * without requiring compiler magic before it can be instantiated?\n+    *\n+    * More specifically, we're interested in whether LambdaMetaFactory can instantiate this type,\n+    * assuming it has a single abstract method. In other words, if we were to mix this\n+    * trait into a class, it should not result in any compiler-generated members having to be\n+    * implemented in (\"mixed in to\") this class (except for the SAM).\n+    *\n+    * Thus, the type must erase to a java interface, either by virtue of being defined as one,\n+    * or by being a trait that:\n+    *   - is static (explicitouter or lambdalift may add disqualifying members)\n+    *   - extends only other traits that compile to pure interfaces (except for Any)\n+    *   - has no val/var members\n+    */","path":"src/reflect/scala/reflect/internal/transform/Erasure.scala","position":18,"original_position":18,"commit_id":"41cf8d68bc467f8aedf03e179f9a87fb7adce1a6","original_commit_id":"3d969f550bcfd4be052b6a65af7d2fe4cea897bc","user":{"login":"smarter","id":63430,"avatar_url":"https://avatars.githubusercontent.com/u/63430?v=3","gravatar_id":"","url":"https://api.github.com/users/smarter","html_url":"https://github.com/smarter","followers_url":"https://api.github.com/users/smarter/followers","following_url":"https://api.github.com/users/smarter/following{/other_user}","gists_url":"https://api.github.com/users/smarter/gists{/gist_id}","starred_url":"https://api.github.com/users/smarter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/smarter/subscriptions","organizations_url":"https://api.github.com/users/smarter/orgs","repos_url":"https://api.github.com/users/smarter/repos","events_url":"https://api.github.com/users/smarter/events{/privacy}","received_events_url":"https://api.github.com/users/smarter/received_events","type":"User","site_admin":false},"body":"(and https://github.com/lampepfl/dotty/blob/d875fef31d984198489a3f94bdb4894698ad0cdb/src/dotty/tools/dotc/config/JavaPlatform.scala#L42-L48 and https://github.com/lampepfl/dotty/blob/d875fef31d984198489a3f94bdb4894698ad0cdb/src/dotty/tools/dotc/config/SJSPlatform.scala#L14-L16)","created_at":"2016-03-30T01:46:33Z","updated_at":"2016-03-30T01:46:33Z","html_url":"https://github.com/scala/scala/pull/4971#discussion_r57827520","pull_request_url":"https://api.github.com/repos/scala/scala/pulls/4971","_links":{"self":{"href":"https://api.github.com/repos/scala/scala/pulls/comments/57827520"},"html":{"href":"https://github.com/scala/scala/pull/4971#discussion_r57827520"},"pull_request":{"href":"https://api.github.com/repos/scala/scala/pulls/4971"}}},"pull_request":{"url":"https://api.github.com/repos/scala/scala/pulls/4971","id":59584101,"html_url":"https://github.com/scala/scala/pull/4971","diff_url":"https://github.com/scala/scala/pull/4971.diff","patch_url":"https://github.com/scala/scala/pull/4971.patch","issue_url":"https://api.github.com/repos/scala/scala/issues/4971","number":4971,"state":"open","locked":false,"title":"Unify treatment of built-in functions and SAMs","user":{"login":"adriaanm","id":91083,"avatar_url":"https://avatars.githubusercontent.com/u/91083?v=3","gravatar_id":"","url":"https://api.github.com/users/adriaanm","html_url":"https://github.com/adriaanm","followers_url":"https://api.github.com/users/adriaanm/followers","following_url":"https://api.github.com/users/adriaanm/following{/other_user}","gists_url":"https://api.github.com/users/adriaanm/gists{/gist_id}","starred_url":"https://api.github.com/users/adriaanm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adriaanm/subscriptions","organizations_url":"https://api.github.com/users/adriaanm/orgs","repos_url":"https://api.github.com/users/adriaanm/repos","events_url":"https://api.github.com/users/adriaanm/events{/privacy}","received_events_url":"https://api.github.com/users/adriaanm/received_events","type":"User","site_admin":false},"body":"[description coming soon]","created_at":"2016-02-17T01:38:16Z","updated_at":"2016-03-30T01:46:33Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f512dda769d8a85ef474f899b0d4ae922d05e08e","assignee":{"login":"retronym","id":65551,"avatar_url":"https://avatars.githubusercontent.com/u/65551?v=3","gravatar_id":"","url":"https://api.github.com/users/retronym","html_url":"https://github.com/retronym","followers_url":"https://api.github.com/users/retronym/followers","following_url":"https://api.github.com/users/retronym/following{/other_user}","gists_url":"https://api.github.com/users/retronym/gists{/gist_id}","starred_url":"https://api.github.com/users/retronym/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/retronym/subscriptions","organizations_url":"https://api.github.com/users/retronym/orgs","repos_url":"https://api.github.com/users/retronym/repos","events_url":"https://api.github.com/users/retronym/events{/privacy}","received_events_url":"https://api.github.com/users/retronym/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/scala/scala/milestones/51","html_url":"https://github.com/scala/scala/milestones/2.12.0-M4","labels_url":"https://api.github.com/repos/scala/scala/milestones/51/labels","id":1337791,"number":51,"title":"2.12.0-M4","description":"Leads: @sethtisue & @adriaanm\r\n\r\n  - [X] traits: compile to interfaces with default methods (retronym, adriaanm) #5003\r\n  - [ ] SAM: enable by default, desugar function literals for non-`FunctionN` SAM types to `Function` trees and indylambda (instead of creating an anonymous class during typer) #4971\r\n  - [X] classpath: enable `-YclasspathImpl:flat` by default (lrytz) #5057\r\n  - [ ] RC1 release of scala-java8-compat: collections integration with Java 8 Streams (szeiger & ichoran)\r\n  - [X] traits: use INDY instead of static fields in implementation classes, which are no longer emitted (retronym) \r\n  - [X] optimizer: Copy propagation, remove unused values (closures!) and local variables  (lrytz)\r\n  - [X] optimizer: box-unbox elimination (lrytz)\r\n  - [X] remove genicode (ensure sbt/ide/... still works) (soc, lrytz)\r\n","creator":{"login":"lrytz","id":119636,"avatar_url":"https://avatars.githubusercontent.com/u/119636?v=3","gravatar_id":"","url":"https://api.github.com/users/lrytz","html_url":"https://github.com/lrytz","followers_url":"https://api.github.com/users/lrytz/followers","following_url":"https://api.github.com/users/lrytz/following{/other_user}","gists_url":"https://api.github.com/users/lrytz/gists{/gist_id}","starred_url":"https://api.github.com/users/lrytz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lrytz/subscriptions","organizations_url":"https://api.github.com/users/lrytz/orgs","repos_url":"https://api.github.com/users/lrytz/repos","events_url":"https://api.github.com/users/lrytz/events{/privacy}","received_events_url":"https://api.github.com/users/lrytz/received_events","type":"User","site_admin":false},"open_issues":3,"closed_issues":126,"state":"open","created_at":"2015-10-05T09:46:45Z","updated_at":"2016-03-29T21:28:05Z","due_on":"2016-03-28T07:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/scala/scala/pulls/4971/commits","review_comments_url":"https://api.github.com/repos/scala/scala/pulls/4971/comments","review_comment_url":"https://api.github.com/repos/scala/scala/pulls/comments{/number}","comments_url":"https://api.github.com/repos/scala/scala/issues/4971/comments","statuses_url":"https://api.github.com/repos/scala/scala/statuses/41cf8d68bc467f8aedf03e179f9a87fb7adce1a6","head":{"label":"adriaanm:genbcode-delambdafy","ref":"genbcode-delambdafy","sha":"41cf8d68bc467f8aedf03e179f9a87fb7adce1a6","user":{"login":"adriaanm","id":91083,"avatar_url":"https://avatars.githubusercontent.com/u/91083?v=3","gravatar_id":"","url":"https://api.github.com/users/adriaanm","html_url":"https://github.com/adriaanm","followers_url":"https://api.github.com/users/adriaanm/followers","following_url":"https://api.github.com/users/adriaanm/following{/other_user}","gists_url":"https://api.github.com/users/adriaanm/gists{/gist_id}","starred_url":"https://api.github.com/users/adriaanm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adriaanm/subscriptions","organizations_url":"https://api.github.com/users/adriaanm/orgs","repos_url":"https://api.github.com/users/adriaanm/repos","events_url":"https://api.github.com/users/adriaanm/events{/privacy}","received_events_url":"https://api.github.com/users/adriaanm/received_events","type":"User","site_admin":false},"repo":{"id":2890393,"name":"scala","full_name":"adriaanm/scala","owner":{"login":"adriaanm","id":91083,"avatar_url":"https://avatars.githubusercontent.com/u/91083?v=3","gravatar_id":"","url":"https://api.github.com/users/adriaanm","html_url":"https://github.com/adriaanm","followers_url":"https://api.github.com/users/adriaanm/followers","following_url":"https://api.github.com/users/adriaanm/following{/other_user}","gists_url":"https://api.github.com/users/adriaanm/gists{/gist_id}","starred_url":"https://api.github.com/users/adriaanm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adriaanm/subscriptions","organizations_url":"https://api.github.com/users/adriaanm/orgs","repos_url":"https://api.github.com/users/adriaanm/repos","events_url":"https://api.github.com/users/adriaanm/events{/privacy}","received_events_url":"https://api.github.com/users/adriaanm/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/adriaanm/scala","description":"The Scala programming language","fork":true,"url":"https://api.github.com/repos/adriaanm/scala","forks_url":"https://api.github.com/repos/adriaanm/scala/forks","keys_url":"https://api.github.com/repos/adriaanm/scala/keys{/key_id}","collaborators_url":"https://api.github.com/repos/adriaanm/scala/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/adriaanm/scala/teams","hooks_url":"https://api.github.com/repos/adriaanm/scala/hooks","issue_events_url":"https://api.github.com/repos/adriaanm/scala/issues/events{/number}","events_url":"https://api.github.com/repos/adriaanm/scala/events","assignees_url":"https://api.github.com/repos/adriaanm/scala/assignees{/user}","branches_url":"https://api.github.com/repos/adriaanm/scala/branches{/branch}","tags_url":"https://api.github.com/repos/adriaanm/scala/tags","blobs_url":"https://api.github.com/repos/adriaanm/scala/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/adriaanm/scala/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/adriaanm/scala/git/refs{/sha}","trees_url":"https://api.github.com/repos/adriaanm/scala/git/trees{/sha}","statuses_url":"https://api.github.com/repos/adriaanm/scala/statuses/{sha}","languages_url":"https://api.github.com/repos/adriaanm/scala/languages","stargazers_url":"https://api.github.com/repos/adriaanm/scala/stargazers","contributors_url":"https://api.github.com/repos/adriaanm/scala/contributors","subscribers_url":"https://api.github.com/repos/adriaanm/scala/subscribers","subscription_url":"https://api.github.com/repos/adriaanm/scala/subscription","commits_url":"https://api.github.com/repos/adriaanm/scala/commits{/sha}","git_commits_url":"https://api.github.com/repos/adriaanm/scala/git/commits{/sha}","comments_url":"https://api.github.com/repos/adriaanm/scala/comments{/number}","issue_comment_url":"https://api.github.com/repos/adriaanm/scala/issues/comments{/number}","contents_url":"https://api.github.com/repos/adriaanm/scala/contents/{+path}","compare_url":"https://api.github.com/repos/adriaanm/scala/compare/{base}...{head}","merges_url":"https://api.github.com/repos/adriaanm/scala/merges","archive_url":"https://api.github.com/repos/adriaanm/scala/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/adriaanm/scala/downloads","issues_url":"https://api.github.com/repos/adriaanm/scala/issues{/number}","pulls_url":"https://api.github.com/repos/adriaanm/scala/pulls{/number}","milestones_url":"https://api.github.com/repos/adriaanm/scala/milestones{/number}","notifications_url":"https://api.github.com/repos/adriaanm/scala/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/adriaanm/scala/labels{/name}","releases_url":"https://api.github.com/repos/adriaanm/scala/releases{/id}","deployments_url":"https://api.github.com/repos/adriaanm/scala/deployments","created_at":"2011-12-01T10:52:13Z","updated_at":"2016-02-09T02:28:16Z","pushed_at":"2016-03-30T01:36:12Z","git_url":"git://github.com/adriaanm/scala.git","ssh_url":"git@github.com:adriaanm/scala.git","clone_url":"https://github.com/adriaanm/scala.git","svn_url":"https://github.com/adriaanm/scala","homepage":"http://www.scala-lang.org/","size":86197,"stargazers_count":4,"watchers_count":4,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":4,"default_branch":"2.12.x"}},"base":{"label":"scala:2.12.x","ref":"2.12.x","sha":"0e4c39aee4196573e8fb94a01fd92e0be4e4dd05","user":{"login":"scala","id":57059,"avatar_url":"https://avatars.githubusercontent.com/u/57059?v=3","gravatar_id":"","url":"https://api.github.com/users/scala","html_url":"https://github.com/scala","followers_url":"https://api.github.com/users/scala/followers","following_url":"https://api.github.com/users/scala/following{/other_user}","gists_url":"https://api.github.com/users/scala/gists{/gist_id}","starred_url":"https://api.github.com/users/scala/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scala/subscriptions","organizations_url":"https://api.github.com/users/scala/orgs","repos_url":"https://api.github.com/users/scala/repos","events_url":"https://api.github.com/users/scala/events{/privacy}","received_events_url":"https://api.github.com/users/scala/received_events","type":"Organization","site_admin":false},"repo":{"id":2888818,"name":"scala","full_name":"scala/scala","owner":{"login":"scala","id":57059,"avatar_url":"https://avatars.githubusercontent.com/u/57059?v=3","gravatar_id":"","url":"https://api.github.com/users/scala","html_url":"https://github.com/scala","followers_url":"https://api.github.com/users/scala/followers","following_url":"https://api.github.com/users/scala/following{/other_user}","gists_url":"https://api.github.com/users/scala/gists{/gist_id}","starred_url":"https://api.github.com/users/scala/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scala/subscriptions","organizations_url":"https://api.github.com/users/scala/orgs","repos_url":"https://api.github.com/users/scala/repos","events_url":"https://api.github.com/users/scala/events{/privacy}","received_events_url":"https://api.github.com/users/scala/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/scala/scala","description":"The Scala programming language","fork":false,"url":"https://api.github.com/repos/scala/scala","forks_url":"https://api.github.com/repos/scala/scala/forks","keys_url":"https://api.github.com/repos/scala/scala/keys{/key_id}","collaborators_url":"https://api.github.com/repos/scala/scala/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/scala/scala/teams","hooks_url":"https://api.github.com/repos/scala/scala/hooks","issue_events_url":"https://api.github.com/repos/scala/scala/issues/events{/number}","events_url":"https://api.github.com/repos/scala/scala/events","assignees_url":"https://api.github.com/repos/scala/scala/assignees{/user}","branches_url":"https://api.github.com/repos/scala/scala/branches{/branch}","tags_url":"https://api.github.com/repos/scala/scala/tags","blobs_url":"https://api.github.com/repos/scala/scala/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/scala/scala/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/scala/scala/git/refs{/sha}","trees_url":"https://api.github.com/repos/scala/scala/git/trees{/sha}","statuses_url":"https://api.github.com/repos/scala/scala/statuses/{sha}","languages_url":"https://api.github.com/repos/scala/scala/languages","stargazers_url":"https://api.github.com/repos/scala/scala/stargazers","contributors_url":"https://api.github.com/repos/scala/scala/contributors","subscribers_url":"https://api.github.com/repos/scala/scala/subscribers","subscription_url":"https://api.github.com/repos/scala/scala/subscription","commits_url":"https://api.github.com/repos/scala/scala/commits{/sha}","git_commits_url":"https://api.github.com/repos/scala/scala/git/commits{/sha}","comments_url":"https://api.github.com/repos/scala/scala/comments{/number}","issue_comment_url":"https://api.github.com/repos/scala/scala/issues/comments{/number}","contents_url":"https://api.github.com/repos/scala/scala/contents/{+path}","compare_url":"https://api.github.com/repos/scala/scala/compare/{base}...{head}","merges_url":"https://api.github.com/repos/scala/scala/merges","archive_url":"https://api.github.com/repos/scala/scala/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/scala/scala/downloads","issues_url":"https://api.github.com/repos/scala/scala/issues{/number}","pulls_url":"https://api.github.com/repos/scala/scala/pulls{/number}","milestones_url":"https://api.github.com/repos/scala/scala/milestones{/number}","notifications_url":"https://api.github.com/repos/scala/scala/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/scala/scala/labels{/name}","releases_url":"https://api.github.com/repos/scala/scala/releases{/id}","deployments_url":"https://api.github.com/repos/scala/scala/deployments","created_at":"2011-12-01T05:02:34Z","updated_at":"2016-03-30T01:13:16Z","pushed_at":"2016-03-30T01:36:15Z","git_url":"git://github.com/scala/scala.git","ssh_url":"git@github.com:scala/scala.git","clone_url":"https://github.com/scala/scala.git","svn_url":"https://github.com/scala/scala","homepage":"http://www.scala-lang.org/","size":141389,"stargazers_count":5872,"watchers_count":5872,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1472,"mirror_url":null,"open_issues_count":30,"forks":1472,"open_issues":30,"watchers":5872,"default_branch":"2.12.x"}},"_links":{"self":{"href":"https://api.github.com/repos/scala/scala/pulls/4971"},"html":{"href":"https://github.com/scala/scala/pull/4971"},"issue":{"href":"https://api.github.com/repos/scala/scala/issues/4971"},"comments":{"href":"https://api.github.com/repos/scala/scala/issues/4971/comments"},"review_comments":{"href":"https://api.github.com/repos/scala/scala/pulls/4971/comments"},"review_comment":{"href":"https://api.github.com/repos/scala/scala/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/scala/scala/pulls/4971/commits"},"statuses":{"href":"https://api.github.com/repos/scala/scala/statuses/41cf8d68bc467f8aedf03e179f9a87fb7adce1a6"}}}}