Skip to main content
Journey Uncommon Logo
JourneyUncommon
hardRubyinclude prepend extend on the chainSingle-choice MCQ

A class is reopened to prepend a module AFTER an instance already exists. Does the live instance see the prepended override?

class Live def x; "orig"; end end inst = Live.new module Patch; def x; "patched->#{super}"; end; end Live.prepend(Patch) p inst.x