Does Erlang have methods? -


e.g. there this:

o = widget:new(), o:whirl() 

i seem recall seeing code (maybe imagining it), haven't seen in tutorials i've read. i've seen, closest thing this:

o = widget:new(), widget:whirl(o) 

that's not bad, not having repeat widget: in second expression nice.

this syntax parametrized modules removed erlang in r16 (2012).


Popular posts from this blog