2 ms·
Thanks pornel and rcxdude, this makes sense to me now. I was thinking it shouldn't be dereferencing because when references were previously introduced (the prin
by dmurray 6y ago
Thanks pornel and rcxdude, this makes sense to me now. I was thinking it shouldn't be dereferencing because when references were previously introduced (the print_number example), we could call methods on the reference without any special syntax. But I guess it makes sense that instance methods work that way, while other functions need to know if we have a reference or the real object, and in this regard it works more or less like C++.