Created
October 14, 2011 00:04
-
-
Save jjb/1285883 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
foo = 1 | |
[2].each{|foo| } | |
# in ruby 1.8, foo in this scope is now 2 | |
# in ruby 1.9, foo stays as it was before the block, 1. hooray! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment