Created
March 8, 2013 17:50
-
-
Save cilquirm/5118368 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 M | |
module N | |
class C | |
def say(str) | |
puts str | |
end | |
end | |
end | |
end | |
module M | |
module N | |
class D | |
def initialize(str) | |
M::N::C.new.say str #seems like i shouldn't have to explicitly declare the full namespace for a sibling | |
end | |
end | |
end | |
end | |
module M | |
module N | |
class E | |
include M::N # seems odd to include a module that i've just declared as the parent | |
def initialize(str) | |
C.new.say str | |
end | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment