{"action":"created","issue":{"url":"https://api.github.com/repos/jruby/jruby/issues/4330","repository_url":"https://api.github.com/repos/jruby/jruby","labels_url":"https://api.github.com/repos/jruby/jruby/issues/4330/labels{/name}","comments_url":"https://api.github.com/repos/jruby/jruby/issues/4330/comments","events_url":"https://api.github.com/repos/jruby/jruby/issues/4330/events","html_url":"https://github.com/jruby/jruby/issues/4330","id":191073780,"number":4330,"title":"Refinements do not refine","user":{"login":"zverok","id":129656,"avatar_url":"https://avatars.githubusercontent.com/u/129656?v=3","gravatar_id":"","url":"https://api.github.com/users/zverok","html_url":"https://github.com/zverok","followers_url":"https://api.github.com/users/zverok/followers","following_url":"https://api.github.com/users/zverok/following{/other_user}","gists_url":"https://api.github.com/users/zverok/gists{/gist_id}","starred_url":"https://api.github.com/users/zverok/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zverok/subscriptions","organizations_url":"https://api.github.com/users/zverok/orgs","repos_url":"https://api.github.com/users/zverok/repos","events_url":"https://api.github.com/users/zverok/events{/privacy}","received_events_url":"https://api.github.com/users/zverok/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-11-22T17:32:08Z","updated_at":"2017-02-04T17:11:13Z","closed_at":null,"body":"### Environment\r\n\r\n```\r\n$ ruby -v\r\njruby 9.1.6.0 (2.3.1) 2016-11-22 0150a76 OpenJDK Server VM 24.65-b04 on 1.7.0_65-b32 +jit [linux-i386]\r\n$ uname -a\r\nLinux platypus 3.13.0-37-generic #64-Ubuntu SMP Mon Sep 22 21:30:01 UTC 2014 i686 i686 i686 GNU/Linux\r\n```\r\n\r\n### Expected Behavior\r\n\r\n```ruby\r\nmodule Refinements\r\n  refine Object do\r\n    def derp\r\n      yield self\r\n    end\r\n  end\r\nend\r\n\r\nmodule A\r\n  using Refinements\r\n\r\n  def self.foo\r\n    'test'.derp { |s| '(' + s + ')' }\r\n  end\r\nend\r\n\r\np A.foo # => \"(test)\"\r\n```\r\nWorks in any MRI Ruby 2.1+\r\n\r\n### Actual Behavior\r\n\r\n```ruby\r\np A.foo\r\n#   NoMethodError: undefined method `derp' for \"test\":String\r\n#        foo at tmp/ref.rb:13\r\n#     <main> at tmp/ref.rb:17\r\n```\r\n\r\n### Note\r\n\r\nI believe, as this example is VERY basic and nobody have complained about the behavior, the refinements are really not used in community... Or JRuby users are used to not rely on them, at least. So, it is hard to estimate how severe the bug should be considered."},"comment":{"url":"https://api.github.com/repos/jruby/jruby/issues/comments/277460101","html_url":"https://github.com/jruby/jruby/issues/4330#issuecomment-277460101","issue_url":"https://api.github.com/repos/jruby/jruby/issues/4330","id":277460101,"user":{"login":"najamelan","id":449589,"avatar_url":"https://avatars.githubusercontent.com/u/449589?v=3","gravatar_id":"","url":"https://api.github.com/users/najamelan","html_url":"https://github.com/najamelan","followers_url":"https://api.github.com/users/najamelan/followers","following_url":"https://api.github.com/users/najamelan/following{/other_user}","gists_url":"https://api.github.com/users/najamelan/gists{/gist_id}","starred_url":"https://api.github.com/users/najamelan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/najamelan/subscriptions","organizations_url":"https://api.github.com/users/najamelan/orgs","repos_url":"https://api.github.com/users/najamelan/repos","events_url":"https://api.github.com/users/najamelan/events{/privacy}","received_events_url":"https://api.github.com/users/najamelan/received_events","type":"User","site_admin":false},"created_at":"2017-02-04T17:11:13Z","updated_at":"2017-02-04T17:11:13Z","body":"Isn't this the same as #3548?"}}
{"actor":{"display_login":"najamelan"}}