Skip to content

Instantly share code, notes, and snippets.

@cilquirm
Created March 8, 2013 17:50
Show Gist options
  • Save cilquirm/5118368 to your computer and use it in GitHub Desktop.
Save cilquirm/5118368 to your computer and use it in GitHub Desktop.
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