Created
December 19, 2015 01:10
-
-
Save tenderlove/7e0fb0deea591aecd283 to your computer and use it in GitHub Desktop.
This file contains 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 A | |
def foo; end | |
end | |
class B | |
def foo; end | |
end | |
def omg obj | |
obj.foo # `obj` is only ever two types: A and B | |
end | |
omg A.new | |
omg B.new |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment