Do first-class methods exist?

Posted by gdhoward on Programmers See other posts from Programmers or by gdhoward
Published on 2014-08-23T07:18:58Z Indexed on 2014/08/23 10:34 UTC
Read the original article Hit count: 192

Okay, I know first-class functions are cool, closures even better, etc. But is there any language with first-class methods?

In my mind, I see a first-class method as an "object" that has both a function pointer and a pointer to a specific instance of the class/object, but the implementation doesn't matter. I just want to know if there is any language that uses them.

And as a bonus, how were they implemented?

© Programmers or respective owner

Related posts about programming-languages

Related posts about language-agnostic