From: Kirk Haines Date: 2006-06-16T23:42:38+09:00 Subject: Re: API style preference? a.b=c or a(:b=>c) On Friday 16 June 2006 6:30 am, benjohn@fysh.org wrote: > I don't like either :) If you only set up a constant in one place, and > you use require to make sure that file's only parsed once, then why > would you want that behaviour? ... There's probably a good reason, but > maybe there's a better solution to the problem? :) Because the class definition is not required, and may indeed be evaluated multiple times. And there isn't really a better solution because the point of the reloading is to pick up changes to the code dynamically, without restarting a long running process. So, getting back to the point of the question, you'd prefer multiple lines all with the const_defined? check explicitly attached. Fair enough. However, what if the api in question weren't dealing with constants, but was something else entirely? zoom.Foo = :bar zoom(:Foo => :bar) Preference? Thanks, Kirk Haines