diff --git a/lib/delegate.rb b/lib/delegate.rb index c540c2ec77..d6fb90bdbf 100644 --- a/lib/delegate.rb +++ b/lib/delegate.rb @@ -21,6 +21,8 @@ # SimpleDelegator's implementation serves as a nice example of the use of # Delegator: # +# require 'delegate' +# # class SimpleDelegator < Delegator # def __getobj__ # @delegate_sd_obj # return object we are delegating to, required @@ -253,6 +255,8 @@ end # end # end # +# require 'delegate' +# # class UserDecorator < SimpleDelegator # def birth_year # born_on.year