From: Joel VanderWerf Date: 2005-06-03T06:43:40+09:00 Subject: Re: Interesting discovery... Jim Freeze wrote: > * Joel VanderWerf [2005-06-03 04:43:52 +0900]: > > >>Ara.T.Howard@noaa.gov wrote: >> >>> rescue_test 2.940000 0.320000 3.260000 ( 3.264758) >>> respond_to_test 0.160000 0.050000 0.210000 ( 0.208268) >>> >>> >>>looks like respond_to? is indeed faster. >> >>But if the method *is* defined, rescue is faster: > > > I'm not sure I understand. If the method exists, what is the > need for rescue to be called? I was unclear: I was hypothesizing a different test, in which a certain proportion of the objects had the method and the rest did not. It might be interesting to determine what ratio is the break-even point...