From: Trans Date: 2005-01-27T01:00:56+09:00 Subject: Re: attr Update: I've now fixed #attr to be backward compatible. The only caveat being that one mustuse true (or false or nil) for it to work. ie. | attr :a, "as if it were true" will not work. But as Florian pointed out, this is fairly insignificant. The feature BTW is a bit extended. It can now take more than one attribute as follows: | attr :a, :b, :c, true And all three will get writers too. One last thing, it doesn't just create writers but the "contra-positive" of the attributes you can give it. In other words: | attr :a=, true Will also create a reader. And attr :a?, true Will get a writer (#a=). Note that casting can not be used with this notation. So attr :a => :to_s, true Will not work. This is b/c casted attributes must always be at then end of the argument list (it's a hash after all). Oh, one last thing. All the "attr_*" methods are still there but now they accept casting and I've added #attr_tester (for #a? methods) Hope you like. It will be available when I release Carats in a month or two. (Sooner if I can find a helping hand.) T.