From: ara.t.howard@... Date: 2006-04-14T04:26:21+09:00 Subject: Re: Question mark in attr_* On Fri, 14 Apr 2006, Justin Collins wrote: > This could be pretty handy...but I don't understand why you have the double > negation? >> define_method("#{sym}?") { !!instance_variable_get("@#{sym}") } if you like having this check out traits - it does this automatically require 'traits' class C trait 't' end c = C.new c.t = 42 p c.t #=> 42 p c.? #=> true c.t 42 # same as c.t= 42 regards. -a -- be kind whenever possible... it is always possible. - h.h. the 14th dali lama