For the Haskell Communities and Activities Report:
Java VM Bridge
Java VM Bridge is a GHC package intended to allow full access to the Java
Virtual Machine from Haskell, as a simple way of providing a wide range
of imperative functionality. Its big advantage over earlier attempts at
this is that it includes a straightforward way of creating Java classes
at run-time that have Haskell methods (using DefineClass and the Java
Class File Format). It also features reconciliation of thread models
without requiring GPH.
It is intended to make writing "Java in Haskell" as straightforward as
possible. To this end, each Java class is a separate type, and the
argument lists of methods of automatically-generated interfaces to Java
classes make use of subtype class relations to minimise explicit upward
casting. Java exceptions are represented as Haskell monadic exceptions,
and may be caught or thrown accordingly. Also, the two garbage collectors
are integrated in such a way that cross-collector reference loops won't
As a point of cleanliness and principle, it makes no use of "unsafe"
Haskell calls (or pure function FFI). The layered design allows access to
either lifted monads that keep track of context data (specifically, the
JNIEnv pointer) and do all the work of preloading for you, or "IO"-based
functions if you want to do all that yourself.
A beta-quality 0.1 was released in December 2001, for x86 Unix only.
Release 0.2 will also be available for Windows and MacOS X, just as soon
as stable 5.04 GHC is available on those platforms (unless I get tired
Contact: Ashley Yakeley <ashley@...>
Ashley Yakeley, Seattle WA
Get latest updates about Open Source Projects, Conferences and News.