Skip to content

Instantly share code, notes, and snippets.

@robmiller
Forked from bcardarella/gist:9451743
Created March 9, 2014 18:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save robmiller/9451784 to your computer and use it in GitHub Desktop.
Save robmiller/9451784 to your computer and use it in GitHub Desktop.
def method_a
method_b do |thing|
thing = 'hey'
end
end
def method_b
thing = nil
thing = yield thing
# expect 'hey'
puts thing
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment