Posts Tagged ‘ECT’

Object-Oriented on Erlang VM

September 6, 2009

Erlang is a *super* concurrent-oriented functional language.

Here, I listed some way to write object-oriented code for erlang. (Not just some shapes trick)

1. mudole as value.

ModuleName = math,
X = ModuleName:sqrt(16.0).

Ok, it’s not OO enough.

2. build-in parameter module and extends module.

f1() -> super_f1.

Try to call sub:f1().

-module(pmodule, [X]).
x() -> X.

And you can do this:

Obj = pmodule:new(cool),

It’s true. You can do it right now! Although these features are experimented. see Inheritance in Erlang.

3. other object-oriented languages run on erlang vm.


ruby-style, every object is a gen_server.

Now, it’s compiler just compile the reia code into the erlang code.

See slide.

ECT(Erlang Class Transformation)

add object-oriented programming to Erlang.

see Object-oriented extension to Erlang.

WOOPER(Wrapper for Object-Oriented Programming in Erlang)

eXAT(erlang eXperimental Agent Tool)

Too old.