It’s funny but I never really understood yield before I saw code like
this
def a( n, &blk )
blk.call n
end
instead of
def a n
yield n
end
maybe some hidden Smalltalk genes, now in my mind whenever I see
yield(…) I replace it with Proc.new.call(…) in my mind.
Hope that adds some more insight
Robert
–
http://ruby-smalltalk.blogspot.com/
Whereof one cannot speak, thereof one must be silent.
Ludwig Wittgenstein