Hostname: page-component-77c89778f8-vsgnj Total loading time: 0 Render date: 2024-07-17T11:46:32.224Z Has data issue: false hasContentIssue false

Extending the lambda-calculus with unbind and rebind

Published online by Cambridge University Press:  15 March 2011

Mariangiola Dezani-Ciancaglini
Affiliation:
Dip. di Informatica, Univ. di Torino, Italy; dezani@di.unito.it
Paola Giannini
Affiliation:
Dip. di Informatica, Univ. del Piemonte Orientale, Italy.
Elena Zucca
Affiliation:
DISI, Univ. di Genova, Italy.
Get access

Abstract

We extend the simply typed λ-calculus with unbind and rebind primitive constructs. That is, a value can be a fragment of open code, which in order to be used should be explicitly rebound. This mechanism nicely coexists with standard static binding. The motivation is to provide an unifying foundation for mechanisms of dynamic scoping, where the meaning of a name is determined at runtime, rebinding, such as dynamic updating of resources and exchange of mobile code, and delegation, where an alternative action is taken if a binding is missing. Depending on the application scenario, we consider two extensions which differ in the way type safety is guaranteed. The former relies on a combination of static and dynamic type checking. That is, rebind raises a dynamic error if for some variable there is no replacing term or it has the wrong type. In the latter, this error is prevented by a purely static type system, at the price of more sophisticated types.

Type
Research Article
Copyright
© EDP Sciences, 2011

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)

References

Ancona, D., Fagorzi, S. and Zucca, E., A parametric calculus for mobile open code. Electronic Notes in Theoretical Computer Science 192 (2008) 322. CrossRef
G. Bierman, M.W. Hicks, P. Sewell, G. Stoyle and K. Wansbrough, Dynamic rebinding for marshalling and update, with destruct-time $\lambda$ , in ICFP'03. ACM Press (2003), 99–110.
Dami, L., A lambda-calculus for dynamic binding. Theoret. Comput. Sci. 192 (1997) 201231. CrossRef
M. Dezani-Ciancaglini, P. Giannini and O. Nierstrasz, A calculus of evolving objects. Scientific Annals of Computer Science (2008) 63–98.
M. Dezani-Ciancaglini, P. Giannini and E. Zucca, Intersection types for unbind and rebind, in ITRS'10. Electronic Proceedings in Theoretical Computer Science 45 (2010) 45–59. CrossRef
O. Kiselyov, C.-C. Shan and A. Sabry, Delimited dynamic binding, in ICFP'06, ACM Press (2006), 26–37.
Moreau, L., A syntactic theory of dynamic binding. Higher Order and Symbolic Computation 11 (1998) 233279. CrossRef
Sewell, P., Leifer, J.J., Wansbrough, K., Allen-Williams, M., Nardelli, F.Z., Habouzit, P. and Vafeiadis, V., Acute: High-level programming language design for distributed computation: Design rationale and language definition. J. Funct. Prog. 17 (2007) 547612. CrossRef
Taha, W. and Sheard, T., MetaML and multi-stage programming with explicit annotations. Theoret. Comput. Sci. 248 (2000) 211242. CrossRef
É. Tanter, Beyond static and dynamic scope, in DLS'09. ACM Press (2009), 3–14.