Academic Journal

Relating Functional and Imperative Session Types

Bibliographic Details
Title: Relating Functional and Imperative Session Types
Authors: Hannes Saffrich, Peter Thiemann
Superior Title: Logical Methods in Computer Science, Vol Volume 18, Issue 3 (2022)
Publisher Information: Logical Methods in Computer Science e.V., 2022.
Publication Year: 2022
Collection: LCC:Logic
LCC:Electronic computers. Computer science
Subject Terms: computer science - programming languages, d.1.3, d.3.1, f.3.2, Logic, BC1-199, Electronic computers. Computer science, QA75.5-76.95
Description: Imperative session types provide an imperative interface to session-typed communication. In such an interface, channel references are first-class objects with operations that change the typestate of the channel. Compared to functional session type APIs, the program structure is simpler at the surface, but typestate is required to model the current state of communication throughout. Following an early work that explored the imperative approach, a significant body of work on session types has neglected the imperative approach and opts for a functional approach that uses linear types to manage channel references soundly. We demonstrate that the functional approach subsumes the early work on imperative session types by exhibiting a typing and semantics preserving translation into a system of linear functional session types. We further show that the untyped backwards translation from the functional to the imperative calculus is semantics preserving. We restrict the type system of the functional calculus such that the backwards translation becomes type preserving. Thus, we precisely capture the difference in expressiveness of the two calculi and conclude that the lack of expressiveness in the imperative calculus is largely due to restrictions imposed by its type system.
Document Type: article
File Description: electronic resource
Language: English
ISSN: 1860-5974
Relation: https://lmcs.episciences.org/8815/pdf; https://doaj.org/toc/1860-5974
DOI: 10.46298/lmcs-18(3:33)2022
Access URL: https://doaj.org/article/5922d027f1484764b265df41ee52634c
Accession Number: edsdoj.5922d027f1484764b265df41ee52634c
Database: Directory of Open Access Journals
Description
Description not available.