草庐IT

UnboundMethod

全部标签

Ruby 函数与方法

在RubyProgrammingLanguage,第6章(第二段)他们说:Manylanguagesdistinguishbetweenfunctions,whichhavenoassociatedobject,andmethods,whichareinvokedonareceiverobject.BecauseRubyisapurelyobjectorientedlanguage,allmethodsaretruemethodsandareassociatedwithatleastoneobject.然后在第6段的中间:Bothprocsandlambdasarefunctionsr