Skip to content

Instantly share code, notes, and snippets.

@delba
Created July 3, 2013 22:15
Show Gist options
  • Select an option

  • Save delba/5923339 to your computer and use it in GitHub Desktop.

Select an option

Save delba/5923339 to your computer and use it in GitHub Desktop.
Multi-line blocks
class Person; def hello; 'hello'; end; end;
Person.new.tap do |p|
puts p.hello
end.tap do |p|
puts p.hello
end
Person.new.tap { |p|
puts p.hello
}.tap { |p|
puts p.hello
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment