On 21/06/2006, at 3:07 PM, Erik de Castro Lopo wrote:
Sorry, but no, functions are not really equivalent to methods.
From:
http://en.wikipedia.org/wiki/Function
"A subroutine which has no side-effects; see functional
programming."
Sure, that's the mathematical definition of a function, but it's
certainly not the typical definition of a function in programming
circles. Functions are pretty much equivalent to methods in
languages that don't have OO as part of their dogma, and almost all
languages will permit those functions to have side-effects.
(I'm not arguing that functions with side-effects are a good thing,
by the way... quite the contrary.)
--
% Andre Pang : trust.in.love.to.save <http://www.algorithm.com.au/>
_______________________________________________
coders mailing list
[email protected]
http://lists.slug.org.au/listinfo/coders