From: Robert Dober Date: 2010-06-04T00:04:53+09:00 Subject: Re: dynamicaly define a method which body can contain yield On Thu, Jun 3, 2010 at 3:28 PM, Regis d'Aubarede wrote: > Hello, > > So i try to define a methode by providing a bloc which can contain a > yield. This is known as the single biggest PITA of Ruby1.8, well by me. If you can, use Ruby1.9 and you can do such wonderful things as define_method :alpha do |beta, &gamma| . . gamma[...] .. end in 1.8. you have to do some nasty tricks with converting methods to blocks or use simply "eval" or "module_eval" with a string. HTH R.