Linear type theory for asynchronous session types

被引:120
作者
Gay, Simon J. [1 ]
Vasconcelos, Vasco T. [2 ]
机构
[1] Univ Glasgow, Dept Comp Sci, Glasgow G12 8QQ, Lanark, Scotland
[2] Univ Lisbon, Fac Ciencias, Dept Informat, P-1749016 Lisbon, Portugal
基金
英国工程与自然科学研究理事会;
关键词
LANGUAGE PRIMITIVES; DISCIPLINE;
D O I
10.1017/S0956796809990268
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Session types Support a type-theoretic formulation of structured patterns of communication, so that the communication behaviour of agents in a distributed system call be verified by static typechecking. Applications include network protocols, business processes and operating system services-In this paper we define a multithread functional language with session types, which unifies, simplifies and extends previous work. There are four main contributions. First is an operational semantics with buffered channels, instead of the synchronous communication of previous work. Second, we prove that the session type of a channel gives all upper bound on the necessary size of the buffer. Third, Session types are Manipulated by means of the standard structures Of a linear type theory, rather than by means of new forms of typing judgement. Fourth, a notion Of subtyping, including the standard subtyping relation for session types (imported into the functional setting), and a novel form of subtyping between standard and linear function types, which allows the typechecker to handle linear types conveniently. Our new approach significantly simplifies session types ill the functional setting clarifies their essential features and provides a secure foundation for language developments Such as polymorphism and object-orientation.
引用
收藏
页码:19 / 50
页数:32
相关论文
共 35 条
[1]  
[Anonymous], 1999, TYPE EFFECT SYSTEMS
[2]  
Bonelli E, 2005, J FUNCT PROGRAM, V15, P219, DOI 10.1017/S09567968O400543X
[3]   Amalgamating sessions and methods in object-oriented languages with generics [J].
Capecchi, Sara ;
Coppo, Mario ;
Dezani-Ciancaglini, Mariangiola ;
Drossopoulou, Sophia ;
Giachino, Elena .
THEORETICAL COMPUTER SCIENCE, 2009, 410 (2-3) :142-167
[4]  
Coppo M, 2007, LECT NOTES COMPUT SC, V4468, P1
[5]   Enforcing high-level protocols in low-level software [J].
DeLine, R ;
Fähndrich, M .
ACM SIGPLAN NOTICES, 2001, 36 (05) :59-69
[6]  
Dezani-Ciancaglini M, 2005, LECT NOTES COMPUT SC, V3705, P299, DOI 10.1007/11580850_16
[7]  
Dezani-Ciancaglini M, 2006, LECT NOTES COMPUT SC, V4067, P328
[8]   Adoption and focus:: Practical linear types for imperative programming [J].
Fähndrich, M ;
DeLine, R .
ACM SIGPLAN NOTICES, 2002, 37 (05) :13-24
[9]  
FAHNDRICH M, 2006, P EUROSYS C SIGOPS O, V40, P177
[10]   Subtyping for session types in the pi calculus [J].
Gay, S ;
Hole, M .
ACTA INFORMATICA, 2005, 42 (2-3) :191-225