MLUG: Re: [MLUG] guess what
Re: [MLUG] guess what
Email address obfuscation in effect -- please click here to turn it off.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
> The *point*, though, is that this is a demonstration of what true
> lexical scoping would really look like and what it allows.  There is
> a lot more out there than Python.  I don't have any more time to
> talk about lexical closures and their uses.  Just google it,
> Michael.

Lexical closures are quite useful. Perl has had them since 1995.
Java got them with "Inner Classes" in 1.4, I believe.

Damien Conway in his "OO Perl" book (Manning), gives a convincing argument that
lexical closures are the only way to get "truly" private object attributes in
languages that expose "namespaces" and class definitions through "reflection".

His book is is really more about the interesting nooks of OO, multiple
inheritance, data inheritance vs method inheritance, closures, public/private
object interfaces, methods as objects and data as objects, and the like, than
about Perl, but really shows how OO Perl *can be*.

Mike/

---------------------------------------------
http://www.valuenet.net


_______________________________________________
members mailing list
EMAIL:PROTECTED
http://mlug.missouri.edu/mailman/listinfo/members