From: han.holl@... (Han Holl) Date: 2004-02-27T02:29:48+09:00 Subject: Callback Hi, The following code works, but I was wondering if the creation of the @obj instance variable is really necessary? class A def callback(name, obj) @obj = obj eval("def #{name}; @obj.keys; end") end end class B attr_reader :keys def initialize(k, cb) @keys = k cb.callback('cassette', self) end end a = A.new g = B.new([1,2,3], a) puts a.cassette