Skip to main content
Journey Uncommon Logo
JourneyUncommon
hardRubymethod lookup and ancestorsSingle-choice MCQ

A class prepends a logging module, then both define `calc` and the module calls `super`. What do `Method#owner` and `super_method.owner` report?

module Log; def calc; "log->" + super; end; end class Calc prepend Log def calc; "base"; end end m = Calc.new.method(:calc) p m.owner p m.super_method.owner