From: Christoph Rippel Date: 2001-01-10T08:28:31+09:00 Subject: [ruby-talk:8967] Re: Modules and mixins > -----Original Message----- > From: Christoph Rippel [mailto:crippel@primenet.com] > Sent: Tuesday, January 09, 2001 02:45 PM > To: ruby-talk ML > Subject: [ruby-talk:8962] Re: Modules and mixins ... > class Array > def multi_each # or each_comb, iter_each ... > __e(*self) {|arg| yield arg } unless empty? > end actually def multi_each # or each_comb, iter_each ... if empty? yield nil else __e(*self) {|arg| yield arg } end end is conceptually more accurate but probably harder to swallow Christoph