I am pleased to announce that the first public release of the
Diamondback Ruby static type inference system is now available!
Diamondback Ruby (DRuby) is a research project that aims to bring the
benefits of static typing to Ruby without compromising the feel of the
language. The main features of DRuby are:
Type inference: DRuby uses inference to model most of Ruby’s idioms
as precisely as possible without any need for programmer
Type annotations: Methods may be given explicit type annotations
with an easy to use syntax inspired by RDoc.
Dynamic checking: When necessary, methods can be type checked at
runtime, using contracts to isolate and properly blame any errant
code, similar to gradual typing.
Metaprogramming support: DRuby includes a combined static and
dynamic analysis to precisely model dynamic meta-programming
constructs, such as eval and method_missing.
Although still in development, DRuby is already able to type small,
self-contained applications. We are working to improve DRuby’s
analysis so that it can type larger code bases, including the standard
library which is not yet supported. Most of DRuby is implemented in
OCaml, but pre-compiled binary gems are available for several
platforms from our webpage. Anyone who is interested in developing
their own program analyses for Ruby are also encouraged to check out
DRuby, as the core implementation is intended to be of general use.
If you are interested in hearing about future releases, or have any
questions or comments, please join our mailing list (see the above