I'm also in favor of discussing this, but all I hear so far in opposition is
vague FUD... no specific examples of problems that could be caused. It would
be a lot easier to have a lively discussion about specific concerns, and I'd
love to have it!
-- Yehuda

On Tue, Feb 24, 2009 at 9:13 PM, Jim Deville <jdeville / microsoft.com> wrote:

>
>
> > -----Original Message-----
> > From: Jim Weirich [mailto:jim.weirich / gmail.com]
> > Sent: Tuesday, February 24, 2009 8:53 PM
> > To: ruby-core / ruby-lang.org
> > Subject: [ruby-core:22448] Re: YASNP (Yet Another Selector Namespace
> > Proposal)
> >
> >
> > On Feb 24, 2009, at 11:29 PM, Jim Deville wrote:
> >
> > > As an example, what if I am using Merb, and two plugins, which all
> > > define a namespaced method, which I want to change. That's three
> > > namespaces that I have to __know about__ and modify. As opposed to
> > > one now.
> >
> > I must admit, I'm a little confused by the above.  Maybe we have
> > different understandings about what selector namespaces are and what
> > they do.
> >
> > If three plugins each define a method named "xyz" in different
> > modules, you have three different methods in three modules.  Adding
> > namespaces doesn't change that.  All the namespace does is allow
> > programmers to say "Over this section of code, calling a method named
> > 'xyz' will come from this module rather than that module."
> >
> > Could some elaborate about their fears of name spaces creating
> > fences.  I don't quite understand what they are getting at.
> >
> > Thanks.
> >
> > --
> > -- Jim Weirich
> > -- jim.weirich / gmail.com
> >
> >
>
> Clarification of my example: If three namespaces define xyz, and you want
> all of the xyz's to act differently, then you need to modify three
> namespaces with monkeypatching. This way you change their effects wherever
> you use them.
>
> Rebuttal of my example: As pointed out by Charlie here and offlist, the
> proper way to handle this conflict of namespaces is to create your own
> namespace that does what you want.
>
> Overall, the example wasn't my major point, my point was in asking the same
> community that is lively about this discussion, and very creative (just see
> the Ruby projects in existence), to come up with ways that this can be
> misused. Throw them out there so we can see if there is a large downside. I
> don't know if there is. This example wasn't meant to prove it wrong, just to
> give an idea.
>
> I guess this kind of falls under bikeshedding, but I think that it is valid
> to partake in some of this kind of brainstorming before this, or any,
> proposal is accepted.
>
> JD
>
>


-- 
Yehuda Katz
Developer | Engine Yard
(ph) 718.877.1325