[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Need standard kernel supported class in Lua, was: Macros and expressivity
- From: Miles Bader <miles@...>
- Date: Wed, 16 Jan 2008 11:39:26 +0900
"Eric Tetz" <erictetz@gmail.com> writes:
> 10 programmers contributing ten different OO schemes to a project,
> with 10 copies of similar yet incompatible code, to be distasteful
"incompatible"? I'd say "compatible"...
Lua emphasizes _interfaces_, and packages in Lua tend to stick to them,
regardless of whatever other features they have. This means that
different OO systems in Lua tend to mix quite happily.
A method call is always a:b(...), data access is always a.b, and this is
true regardless of what OO system is used.
This means you can even "rejig" objects after the fact, seamlessly.
E.g., I have a lot of "objects" created by SWIG, but sometimes I replace
them with wrappers in Lua that use a different OO system, because I need
some extra functionality -- and the code using these objects doesn't
even realize the difference.
-Miles
--
Come now, if we were really planning to harm you, would we be waiting here,
beside the path, in the very darkest part of the forest?
- References:
- Re: Need standard kernel supported class in Lua, was: Macros and expressivity, Eric Tetz
- RE: Need standard kernel supported class in Lua, was: Macros and expressivity, Jerome Vuarand
- Re: Need standard kernel supported class in Lua, was: Macros and expressivity, Eric Tetz
- Re: Need standard kernel supported class in Lua, was: Macros and expressivity, Javier Guerra Giraldez
- Re: Need standard kernel supported class in Lua, was: Macros and expressivity, David Haley
- Re: Need standard kernel supported class in Lua, was: Macros and expressivity, Eric Tetz