Last active
April 13, 2016 16:56
-
-
Save skatenerd/75306c4302e963f00c9fc92953cce2e8 to your computer and use it in GitHub Desktop.
what's gonna happen?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Foo | |
def yes | |
puts "BORING" | |
end | |
end | |
class Bar | |
def self.go(x) | |
puts x.yes | |
end | |
end | |
module Refiner | |
refine Foo do | |
def yes | |
puts "GOT IT!" | |
end | |
end | |
end | |
class Test | |
using Refiner | |
def self.execute | |
puts Foo.new.yes | |
Bar.go(Foo.new) | |
end | |
end | |
Test.execute |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment