Created
October 17, 2011 17:50
-
-
Save manuels/1293253 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module M0 | |
def foo | |
puts 'M2::foo' | |
end | |
end | |
module M1 | |
include M0 | |
def self.included(model) | |
def foo | |
puts 'M1::foo' | |
end | |
end | |
end | |
class C1 | |
include M1 | |
end | |
class C2 < C1 | |
end | |
C1.new.foo | |
C2.new.foo |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment