Displaying 1 result from an estimated 1 matches for "033bdc692487eb5166b61f1c7ee05fe5".
2013 Sep 06
1
Confusion with method call without `.` operator
I am confused on the second call :-
class Foo
def <<(param)
"hi"
end
end
foo = Foo.new
foo.<<(1) # => "hi"
foo << 1 # => "hi" # I didn''t use `.` method,then how method `<<` has
been called?
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups