Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Inherit method #22

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Inherit method #22

wants to merge 1 commit into from

Conversation

asiniy
Copy link

@asiniy asiniy commented Nov 29, 2016

Hello there!

I added inherit_method because of this:

require 'uber/inheritable_attr'

class A
 extend Uber::InheritableAttr

 inheritable_attr :shallow
 self.shallow = { common: {} }
end

class B < A
end

class C < A
end

B.shallow[:common][:this] = "Should be in C"
p C.shallow # => {:common=>{:this=>"shouldn't be in C"}}

@asiniy
Copy link
Author

asiniy commented Dec 1, 2016

@apotonick are you there?

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant