In Ruby (actually only in Rails, apparently), I know that if I do:
some_objects.each(&:foo)
It's the same as
some_objects.each { |obj| obj.foo }
That is -- &foo creates the block { |obj| obj.foo }, turns it into a Proc, and passes it to each. Why does this work? Is it just a Ruby special case, or is there reason why this works as it does?