CML: A higher concurrent language
PLDI '91 Proceedings of the ACM SIGPLAN 1991 conference on Programming language design and implementation
A syntactic approach to type soundness
Information and Computation
POPL '96 Proceedings of the 23rd ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Objective ML: an effective object-oriented extension to ML
Theory and Practice of Object Systems - Third workshop on foundations of object-oriented languages (FOOL 3)
Communications of the ACM
Enforcing high-level protocols in low-level software
Proceedings of the ACM SIGPLAN 2001 conference on Programming language design and implementation
The Java Language Specification
The Java Language Specification
Getting Erlang to talk to the outside world
Proceedings of the 2002 ACM SIGPLAN workshop on Erlang
Language Primitives and Type Discipline for Structured Communication-Based Programming
ESOP '98 Proceedings of the 7th European Symposium on Programming: Programming Languages and Systems
Towards a theory of type structure
Programming Symposium, Proceedings Colloque sur la Programmation
Strongly typed heterogeneous collections
Haskell '04 Proceedings of the 2004 ACM SIGPLAN workshop on Haskell
Proceedings of the 32nd ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Composable memory transactions
Proceedings of the tenth ACM SIGPLAN symposium on Principles and practice of parallel programming
Subtyping for session types in the pi calculus
Acta Informatica
Continuations and transducer composition
Proceedings of the 2006 ACM SIGPLAN conference on Programming language design and implementation
Language support for fast and reliable message-based communication in singularity OS
Proceedings of the 1st ACM SIGOPS/EuroSys European Conference on Computer Systems 2006
Type checking a multithreaded functional language with session types
Theoretical Computer Science
Polymorphic delimited continuations
APLAS'07 Proceedings of the 5th Asian conference on Programming languages and systems
A distributed object-oriented language with session types
TGC'05 Proceedings of the 1st international conference on Trustworthy global computing
Session types for object-oriented languages
ECOOP'06 Proceedings of the 20th European conference on Object-Oriented Programming
Parameterised notions of computation
MSFP'06 Proceedings of the 2006 international conference on Mathematically Structured Functional Programming
Modular session types for distributed object-oriented programming
Proceedings of the 37th annual ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Information flow enforcement in monadic libraries
Proceedings of the 7th ACM SIGPLAN workshop on Types in language design and implementation
Combinators for message-passing in Haskell
PADL'11 Proceedings of the 13th international conference on Practical aspects of declarative languages
Linear logical relations for session-based concurrency
ESOP'12 Proceedings of the 21st European conference on Programming Languages and Systems
Hi-index | 0.05 |
We describe an implementation of session types in Haskell. Session types statically enforce that client-server communication proceeds according to protocols. They have been added to several concurrent calculi, but few implementations of session types are available. Our embedding takes advantage of Haskell where appropriate, but we rely on no exotic features. Thus our approach translates with minimal modification to other polymorphic, typed languages such as ML and Java. Our implementation works with existing Haskell concurrency mechanisms, handles multiple communication channels and recursive session types, and infers protocols automatically. While our implementation uses unsafe operations in Haskell, it does not violate Haskell's safety guarantees. We formalize this claim in a concurrent calculus with unsafe communication primitives over which we layer our implementation of session types, and we prove that the session types layer is safe. In particular, it enforces that channel-based communication follows consistent protocols.