From: "T. Onoma" Date: 2003-12-02T01:55:27+09:00 Subject: Re: anything disappearing from Ruby for 2.0? On Monday 01 December 2003 05:38 pm, Carlos wrote: > > BTW: why does this happen? > > > > a = proc { puts "p" } > > pshooter a # => p > > pshooter a { puts "block" } > > # => undefined method `a' for main:Object (NoMethodError) > > The block associates with 'a': pshooter(a { puts "block"}), so ruby > interprets 'a' as a method. In this case you should use do ... end, it is > more "loose". ah! right, right. Thanks.