HashCaml--an extension of the OCaml bytecode compiler with support for type-safe marshalling and related naming features.

HashCaml

Peter Sewell and crew follow up on their work on Acute:

In this paper we put these ideas into practice, describing the HashCaml extension to the OCaml bytecode compiler, which supports type-safe and abstraction-safe marshalling, together with related naming constructs. Our contribution is threefold: (1) We show how to define globally meaningful runtime type names for key OCaml type constructs that were not covered in our previous work, dealing with the generativity issues involved: user-defined variant and record types, substructures, functors, arbitrary ascription, separate compilation, and external C functions. (2) We support marshalling within polymorphic functions by type-passing, requiring us to build compositional runtime type names and revisit the OCaml relaxed value restriction. We show that with typed marshalling one must fall back to the SML97 value restriction. (3) We show how the above can be implemented with reasonable performance as an unintrusive modification to the existing OCaml language, implementation, and standard libraries. An alpha release of HashCaml, capable of bootstrapping itself, is available, along with an example type-safe distributed communication library written in the language.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

vs. Alice?

Anybody know how this compares in practice with Alice ML's support for distributed systems? I only have a vague high-level hand-wavy sense of these things. The paper itself states, "[Alice ML's approach] is rather less flexible than HashCaml." (On the other hand, pragmatically speaking, Alice is apparently perhaps more actively developed than HashCaml. (On the other other hand, Alice doesn't have a debugger.))