作者
Manuel Fahndrich, Robert DeLine
发表日期
2002/5/17
图书
Proceedings of the ACM SIGPLAN 2002 Conference on Programming language design and implementation
页码范围
13-24
简介
A type system with linearity is useful for checking software protocols andresource management at compile time. Linearity provides powerful reasoning about state changes, but at the price of restrictions on aliasing. The hard division between linear and nonlinear types forces the programmer to make a trade-off between checking a protocol on an object and aliasing the object. Most onerous is the restriction that any type with a linear component must itself be linear. Because of this, checking a protocol on an object imposes aliasing restrictions on any data structure that directly or indirectly points to the object. We propose a new type system that reduces these restrictions with the adoption and focus constructs. Adoption safely allows a programmer to alias objects on which she is checking protocols, and focus allows the reverse. A programmer can alias data structures that point to linear objects and use focus for safe …
引用总数
200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320241026282432192322211821121782014681010353
学术搜索中的文章
M Fahndrich, R DeLine - Proceedings of the ACM SIGPLAN 2002 Conference …, 2002