Created
November 29, 2011 03:17
-
-
Save arwagner/1403218 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
class Foo | |
def initialize | |
@x = 3 | |
end | |
def fiddle &block | |
instance_eval &block | |
end | |
end | |
puts Foo.new.fiddle { @x } | |
x = lambda { @x } | |
puts Foo.new.fiddle &x |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment