Cargando…

Nested Session Types

Session types statically describe communication protocols between concurrent message-passing processes. Unfortunately, parametric polymorphism even in its restricted prenex form is not fully understood in the context of session types. In this paper, we present the metatheory of session types extende...

Descripción completa

Detalles Bibliográficos
Autores principales: Das, Ankush, DeYoung, Henry, Mordido, Andreia, Pfenning, Frank
Formato: Online Artículo Texto
Lenguaje:English
Publicado: 2021
Materias:
Acceso en línea:https://www.ncbi.nlm.nih.gov/pmc/articles/PMC7984581/
http://dx.doi.org/10.1007/978-3-030-72019-3_7
_version_ 1783668096223936512
author Das, Ankush
DeYoung, Henry
Mordido, Andreia
Pfenning, Frank
author_facet Das, Ankush
DeYoung, Henry
Mordido, Andreia
Pfenning, Frank
author_sort Das, Ankush
collection PubMed
description Session types statically describe communication protocols between concurrent message-passing processes. Unfortunately, parametric polymorphism even in its restricted prenex form is not fully understood in the context of session types. In this paper, we present the metatheory of session types extended with prenex polymorphism and, as a result, nested recursive datatypes. Remarkably, we prove that type equality is decidable by exhibiting a reduction to trace equivalence of deterministic first-order grammars. Recognizing the high theoretical complexity of the latter, we also propose a novel type equality algorithm and prove its soundness. We observe that the algorithm is surprisingly efficient and, despite its incompleteness, sufficient for all our examples. We have implemented our ideas by extending the Rast programming language with nested session types. We conclude with several examples illustrating the expressivity of our enhanced type system.
format Online
Article
Text
id pubmed-7984581
institution National Center for Biotechnology Information
language English
publishDate 2021
record_format MEDLINE/PubMed
spelling pubmed-79845812021-03-23 Nested Session Types Das, Ankush DeYoung, Henry Mordido, Andreia Pfenning, Frank Programming Languages and Systems Article Session types statically describe communication protocols between concurrent message-passing processes. Unfortunately, parametric polymorphism even in its restricted prenex form is not fully understood in the context of session types. In this paper, we present the metatheory of session types extended with prenex polymorphism and, as a result, nested recursive datatypes. Remarkably, we prove that type equality is decidable by exhibiting a reduction to trace equivalence of deterministic first-order grammars. Recognizing the high theoretical complexity of the latter, we also propose a novel type equality algorithm and prove its soundness. We observe that the algorithm is surprisingly efficient and, despite its incompleteness, sufficient for all our examples. We have implemented our ideas by extending the Rast programming language with nested session types. We conclude with several examples illustrating the expressivity of our enhanced type system. 2021-03-23 /pmc/articles/PMC7984581/ http://dx.doi.org/10.1007/978-3-030-72019-3_7 Text en © The Author(s) 2021 Open Access This chapter is licensed under the terms of the Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/), which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license and indicate if changes were made. The images or other third party material in this chapter are included in the chapter's Creative Commons license, unless indicated otherwise in a credit line to the material. If material is not included in the chapter's Creative Commons license and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder.
spellingShingle Article
Das, Ankush
DeYoung, Henry
Mordido, Andreia
Pfenning, Frank
Nested Session Types
title Nested Session Types
title_full Nested Session Types
title_fullStr Nested Session Types
title_full_unstemmed Nested Session Types
title_short Nested Session Types
title_sort nested session types
topic Article
url https://www.ncbi.nlm.nih.gov/pmc/articles/PMC7984581/
http://dx.doi.org/10.1007/978-3-030-72019-3_7
work_keys_str_mv AT dasankush nestedsessiontypes
AT deyounghenry nestedsessiontypes
AT mordidoandreia nestedsessiontypes
AT pfenningfrank nestedsessiontypes