I\'m curious why Ruby\'s introspection related method to check if an object responds to a method is respond_to?
instead of responds_to?
It alwa
How do you know that the receiver is always third person singular? It is possible that the receiver be I
, we
, you
, or they
, or some other thing that represents plurality. In that case, will you still say that responds_to?
is more natural than respond_to?
? In order to preserve generality, it is better to name a method in a form as general as possible. Rather than naming a method in third person singular, it makes more sense to name it in the default, to-less infinitive form, which is also used in dictionaries.