{"action":"created","issue":{"url":"https://api.github.com/repos/ceylon/ceylon/issues/6669","repository_url":"https://api.github.com/repos/ceylon/ceylon","labels_url":"https://api.github.com/repos/ceylon/ceylon/issues/6669/labels{/name}","comments_url":"https://api.github.com/repos/ceylon/ceylon/issues/6669/comments","events_url":"https://api.github.com/repos/ceylon/ceylon/issues/6669/events","html_url":"https://github.com/ceylon/ceylon/issues/6669","id":186525722,"number":6669,"title":"Object method can’t be named “get_”","user":{"login":"lucaswerkmeister","id":2346599,"avatar_url":"https://avatars.githubusercontent.com/u/2346599?v=3","gravatar_id":"","url":"https://api.github.com/users/lucaswerkmeister","html_url":"https://github.com/lucaswerkmeister","followers_url":"https://api.github.com/users/lucaswerkmeister/followers","following_url":"https://api.github.com/users/lucaswerkmeister/following{/other_user}","gists_url":"https://api.github.com/users/lucaswerkmeister/gists{/gist_id}","starred_url":"https://api.github.com/users/lucaswerkmeister/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lucaswerkmeister/subscriptions","organizations_url":"https://api.github.com/users/lucaswerkmeister/orgs","repos_url":"https://api.github.com/users/lucaswerkmeister/repos","events_url":"https://api.github.com/users/lucaswerkmeister/events{/privacy}","received_events_url":"https://api.github.com/users/lucaswerkmeister/received_events","type":"User","site_admin":false},"labels":[{"id":286511959,"url":"https://api.github.com/repos/ceylon/ceylon/labels/t-bug","name":"t-bug","color":"e10c02","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-11-01T12:46:29Z","updated_at":"2016-11-01T12:51:45Z","closed_at":null,"body":"I found this while looking at #6667:\r\n```ceylon\r\nobject foo {\r\n    shared void get_() {}\r\n}\r\n```\r\n> Ceylon backend error: method `get_()` is already defined in class `foo_`\r\n> Ceylon backend error: non-static method `get_()` cannot be referenced from a static context\r\n> CompilerBugException: Codegen Error\r\n\r\n`get_` is also the static method used to obtain the object instance. Unfortunately, that method is very much public, so we can’t just rename it without breaking BC.\r\n\r\nPerhaps the better fix would be to disallow object members ending in `_`, just like we already do for toplevel declarations?\r\n\r\nAs always, [generated code](https://gist.github.com/lucaswerkmeister/5e1e418d02dbbc5b8787f72ec80fe2a1), `@noanno`’d."},"comment":{"url":"https://api.github.com/repos/ceylon/ceylon/issues/comments/257558818","html_url":"https://github.com/ceylon/ceylon/issues/6669#issuecomment-257558818","issue_url":"https://api.github.com/repos/ceylon/ceylon/issues/6669","id":257558818,"user":{"login":"tombentley","id":879487,"avatar_url":"https://avatars.githubusercontent.com/u/879487?v=3","gravatar_id":"","url":"https://api.github.com/users/tombentley","html_url":"https://github.com/tombentley","followers_url":"https://api.github.com/users/tombentley/followers","following_url":"https://api.github.com/users/tombentley/following{/other_user}","gists_url":"https://api.github.com/users/tombentley/gists{/gist_id}","starred_url":"https://api.github.com/users/tombentley/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tombentley/subscriptions","organizations_url":"https://api.github.com/users/tombentley/orgs","repos_url":"https://api.github.com/users/tombentley/repos","events_url":"https://api.github.com/users/tombentley/events{/privacy}","received_events_url":"https://api.github.com/users/tombentley/received_events","type":"User","site_admin":false},"created_at":"2016-11-01T12:51:44Z","updated_at":"2016-11-01T12:51:44Z","body":"There used to be a compiler error for names ending `_`. I don't know what happened to that, but it should prevent you writing `get_()`"}}
{"actor":{"display_login":"tombentley"}}