Skip to content

Instantly share code, notes, and snippets.

@gotascii
Created October 22, 2009 16:05
Show Gist options
  • Save gotascii/216053 to your computer and use it in GitHub Desktop.
Save gotascii/216053 to your computer and use it in GitHub Desktop.
def inner(&block)
@inner = block if block_given?
@inner
end
outter = lambda do
name = 'outter'
inner do
puts "inner sees #{name}"
end
end
outter.call
inner.call
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment