From: "Florian Groß" Date: 2005-07-15T22:17:38+09:00 Subject: Re: Difference between Class.new and class Robert Klemme wrote: > A disadvantage of the latter approach is that you cannot define methods > that receive a block. There is no equivalent (yet) for "def foo(&b) > b.call(1) end" with define_method, because you cannot do > define_method(:foo) {|&b| b.call(1)}. Also, you cannot have default > values for method arguments with define_value. The bottom line is: use > the block form only if you need anonymous classes or have to otherwise. But you can use def in Class.new blocks: Bar = Class.new do def two_times(&block) 2.times(&block) end end Bar.new.two_times { puts "Hello World!"} This is on 1.8.2.