Hi --

On Tue, 7 Oct 2008, Austin Ziegler wrote:

> On Mon, Oct 6, 2008 at 3:34 PM, Trans <transfire / gmail.com> wrote:
>> On Oct 6, 2:11 pm, _why <w... / ruby-lang.org> wrote:
>>> While investigating Guy Decoux's old messages, I've recently
>>> discovered a way to do exactly this.  It involves inserting a mixin
>>> into the inheritance chain and then enabling and disabling it as
>>> needed.
>>>
>>> <http://hackety.org/2008/10/06/mixingOurWayOutOfInstanceEval.html>
>>
>> Jimmy Crickets! That code is so straight forward. Er... Why isn't this
>> core Ruby?
>
> What I'm wondering is if this might be a way to do selector namespaces
> that everyone has been asking for...

I've only looked at it briefly, and maybe I'm not getting it, but it
strikes me as kind of odd to have a situation where bare method calls
go to one object and instance variables belong to another. The merit
of instance_eval is that, though it changes context, it doesn't
introduce a new kind of context.


David

-- 
Rails training from David A. Black and Ruby Power and Light:
   Intro to Ruby on Rails  January 12-15   Fort Lauderdale, FL
   Advancing with Rails    January 19-22   Fort Lauderdale, FL *
   * Co-taught with Patrick Ewing!
See http://www.rubypal.com for details and updates!