[plt-scheme] Twitter's experience Ruby -> Scala (dynamic to static typing)

From: Marek Kubica (marek at xivilization.net)
Date: Mon Apr 6 10:28:37 EDT 2009

On Mon, 6 Apr 2009 14:24:00 +0100
Noel Welsh <noelwelsh at gmail.com> wrote:

> Steve Jenson: ... Another thing we really like about Scala is static
> typing that’s not painful. Sometimes it would be really nice in Ruby
> to say things like, here’s an optional type annotation. This is the
> type we really expect to see here. And we find that really useful in
> Scala, to be able to specify the type information.

Optional run-time type checking is trivial to implement, actually. So
there are two choices: either they want types to get more performance
(and I doubt that optional type checking in Ruby would give better
performance unless someone will do a lot of work to optimize the VMs
for that) or they want type checking on compile-time but I imagine that
it would be quite tricky to fuse a static type system with dynamic
types since you can never know for sure what types one would get from
non-annotated code.


Posted on the users mailing list.