Created
August 7, 2013 14:05
-
-
Save undecided/6174360 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
def a(p) | |
p.call() | |
raise "The world is safe" | |
end | |
def b | |
x = Proc.new { return Proc.new { return false } } | |
a(x).call | |
raise 'Maybe here, we might save the world. Let us do that.' | |
end | |
def c | |
b | |
raise 'Bang! Nuclear explosion. You are dead.' | |
end | |
c #=> Would you expect this to destroy the earth? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment