[#927] UnboundMethod#to_proc — Dave Thomas <dave@...>

I'm wondering what I can do with a Proc generated by

17 messages 2003/04/06

Re: UnboundMethod#to_proc

From: matz@... (Yukihiro Matsumoto)
Date: 2003-04-08 04:49:41 UTC
List: ruby-core #947
Hi,

In message "Re: UnboundMethod#to_proc"
    on 03/04/08, Dave Thomas <dave@thomases.com> writes:

|> Not necessarily indeed.  It's just because implementation
|> convenience.
|
|Could 'arity' be a mixin?

Making a new Mix-in is kinda against "less class (module this case)
policy".  Besides, a Mix-in only mixable to Method or UnboundMethod is
not useful for users anyway.

But, the idea of making Method and UnboundMethod independent itself is
very interesting.  In [ruby-core:00944], Michael disagreed this idea,
but it is very rare to polymorphize (right word?) UnboundMethod and
Method.  They are very different in nature, just like class and its
instance.
							matz.

In This Thread