Created
April 28, 2015 12:33
-
-
Save jcoglan/0a37aee2582877b27920 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 foo(&block) | |
p [:foo, 1] | |
block.call | |
p [:foo, 2] | |
end | |
def bar(&block) | |
p [:bar, 1] | |
foo(&block) | |
p [:bar, 2] | |
end | |
def baz | |
p [:baz, 1] | |
bar { return } | |
p [:baz, 2] | |
end | |
baz |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment