Guest User

Untitled

a guest
Jun 22nd, 2018
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.21 KB | None | 0 0
  1. class Foo
  2. def self.bar
  3. puts "bar"
  4. end
  5. end
  6.  
  7. bar = Foo.method(:bar)
  8.  
  9. puts Foo
  10. puts bar.owner
  11. puts Foo == bar.owner
  12.  
  13. # Foo
  14. # #<Class:Foo>
  15. # false
  16.  
  17. # what's happening here? how can i resolve this?
Add Comment
Please, Sign In to add comment