1. Mixin modules in a call-by-value setting
- Author
-
Hirschowitz, Tom and Leroy, Xavier
- Subjects
Calculus -- Analysis ,Recursion theory -- Analysis - Abstract
The ML module system provides powerful parameterization facilities, but lacks the ability to split mutually recursive definitions across modules and provides insufficient support for incremental programming. A promising approach to solve these issues is Ancona and Zucca's mixin module calculus CMS. However, the straightforward way to adapt it to ML fails, because it allows arbitrary recursive definitions to appear at any time, which ML does not otherwise support. In this article, we enrich CMS with a refined type system that controls recursive definitions through the use of dependency graphs. We then develop and prove sound a separate compilation scheme, directed by dependency graphs, that translates mixin modules down to a call-by-value [lambda]-calculus extended with a nonstandard 1et rec construct. Categories and Subject Descriptors: D.3.1 [Programming Languages]: Formal Definitions and Theory--Semantics; D.3.2 [Programming Languages]: Language Classifications--Applicative (functional) languages; object-oriented languages; D.3.3 [Programming Languages]: Language Constructs and Features Inheritance;modules;packages;recursion;F.3.2[LogicsandMeanings of Programs]: Semantics of Programming Languages--Operational semantics; F.3.3 [Logics and Meanings of Programs]: Studies of Program Constructs--Type structure General Terms: Languages, Theory Additional Key Words and Phrases: Mixins, modules, recursion, type systems
- Published
- 2005