Erlang for .NET

Wednesday, September 19, 2007

Stranger Bedfellows: Erlang and the Dynamic Language Runtime

The Dynamic Language Runtime (DLR) sprung from IronPython internals and will provide the integration point between the CLR and dynamic languages (Python, Ruby, JavaScript and others) and define interoperation between components in different dynamic languages. The former includes abstract syntax for dynamic languages, a member resolution cache, and call-site thunks that cache method resolution. The member resolution cache is purged when a type is introduced or a type's representation changes. The call-site thunks can be strongly typed (at least, for up to six arguments); 'object' acts as a type wildcard the binding of which determines cache validity.

Is the DLR relevant to Erlang? Erlang is untyped, but crucially symbol resolution is straightforward and static, unlike Ruby/Python/etc. member resolution. The DLR is probably useful around the edges, for example in CLR interoperability, where DLR dynamic sites could cache the result of Reflection look-ups on plain old CLR objects, which must presumably appear to Erlang programs as processes (or Erlang must be heavily bastardized.) Erlang .NET's internals will probably more closely resemble F#--pattern matching and tuples--than any DLR language.

0 Comments:

Post a Comment



<< Home