On Apr 18, 2011, at 9:39 AM, Jarmo Pertman wrote: > On Apr 18, 4:21 pm, David Chelimsky <dchelim...@gmail.com> wrote: >>> but it doesn't >>> conflict with matcher's #in anyway. >> >> It conflicts with the name :) It's a problem when we have one name that >> means completely different things in different contexts. > > It depends :) That's the point of OOP that the methods with the same > name can mean different things if they're in different context (e.g. > class).
Disagree 100%. The point of polymorphism is that a client can talk to different objects in the same way and expect the same range of results, whereas the actual implementation can differ from object to object. That has nothing to do with the idea that #in in one context means "I am in this array" and in another context means "I'd better finish within this time." These are completely different concepts at an abstract level. > And it's #in vs #in?. Anyway i'm of course open for all > suggestions. It would still confuse people. > I'll see how #within_duration feels like in different situations. I > like the shortness of #in :) What do you think of within(n).seconds { ... }? David _______________________________________________ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users