Another opposite extreme is an OOP language which has no methods. And instead each "method" is really just a data variable which is a closure, making it behave nearly identically to a real method. You could avoid needing these "methods" defined for every instance by simulating inheritance using lexical scoping from a parent class.
Although you would need to provide dynamic scope or pass the first argument as self for it to truly behave like a normal method.
The simplicity of this model is appealing to me but I do not know if any existing languages use it?
Although you would need to provide dynamic scope or pass the first argument as self for it to truly behave like a normal method.
The simplicity of this model is appealing to me but I do not know if any existing languages use it?