Advertisement
Guest User

Untitled

a guest
Jul 14th, 2012
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. [1] pry(main)> module A; def x() :X end end
  2. => nil
  3. [2] pry(main)> module B; def x() :Y end end
  4. => nil
  5. [3] pry(main)> class Foo; include A; include B; end
  6. => Foo
  7. [4] pry(main)> Foo.new.x
  8. => :Y
  9. [5] pry(main)> ls Foo.new
  10. B#methods: x
  11. [6] pry(main)>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement