Created
June 12, 2009 13:04
-
-
Save madx/128622 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
# 1.8.7, 1.9 | |
def self.build(&block) | |
new.tap {|c| c.instance_eval(&block) }.buffer | |
end | |
# old: | |
def self.build(&block) | |
c = new | |
c.instance_eval(&block) | |
c.buffer | |
end | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment