On Tue, 13 Oct 2009, ara.t.howard wrote:

> On Mon, Oct 12, 2009 at 17:48, David A. Black <dblack / rubypal.com> wrote:
>> that does not imply that these should be
>> typed out by hand anew every time they're going to be used.
>
> ??

I was responding to your comments about this being re-invented
repeatedly, which is not what I had been recommending. I wanted to
make that clear.

> the OP simply asked why a useful idiom wasn't supported in core, which
> includes it's libraries. he very clearly asked for "the best solution
> in use."  the subsequent posts responded as to why we shouldn't change
> the language, which was never suggested, and a critique of the of the
> example code, which was never asked for.
>
> the implication was quite clear: that there isn't a best practice and
> that solution should be typed out by hand since "you can make what are
> essentially language-level-like constructs from a few lines of code in
> Ruby"

But *not* typed out by hand anew every time they're going to be used.
The operative word in my statement was "anew".

> honestly, if you read the thread start to finish, i do not think the
> OP's question was given due consideration and i also think his intent
> was co-opted into a request for a language change.

The beginning of the first post is:

>> I'm having trouble understanding why this isn't available from the
>> Ruby core?  Does core not provide an alternative / satisfactory
>> implementation of this?

I'm a bit puzzled by what you're saying. It would never occur to me to
"co-opt" a question. But let's move on.

> i'm simply requesting that the group focus on a good, concrete,
> solution for a hard problem instead of simply telling people that the
> issue is so easy that it's not even worth solving.
>
> i'd love to see some thinking about the various attempts at a complete
> solution.  the OP has already noted that the most common are flawed
> for even moderately complex use cases, maybe the collective can narrow
> in on, and even improve upon, the better ones.  i've personally spent
> a week or two trying to solve this problem in the general case and
> have found it profoundly slippery to get right.  i've already posted
> my attempt at a minimal but complete solution (fattr) but would love
> to hear some legitimate and thoughtful analysis of other approaches.
> if a particular solution could gain some momentum as being best
> practice it would a big help for the next generation of ruby
> programmers - so much so that an RCR, or whatever they are called
> these days, might really be in order.

Coming at it from the other angle, I'd be interested in seeing more
use cases -- not that there aren't some around, but most of the ones
I've seen seem to lend themselves to relatively simple solutions. That
probably means I haven't looked at the right ones....


David

-- 
The          Ruby training with D. Black, G. Brown, J.McAnally
Compleat     Jan 22-23, 2010, Tampa, FL
Rubyist      http://www.thecompleatrubyist.com

David A. Black/Ruby Power and Light, LLC (http://www.rubypal.com)