Typing record concatenation for free

Didier Rémy 1
INRIA Rocquencourt
Abstract : We show that any functional language with record extension pocesses record concatenation for free. We exhibit a translation from the latter into the former. We obtain a type system for a language with record concatenation by composing the translation with type-checking in a language with record extension. We apply this method to a version of ML with record extension and obtain an extension of ML with either asymmetric or symmetric concatenation. The latter extension is simple, flexible and has a very efficient type inference algorithm in practice. Concatenation together with removal of fields needs one more construct than extension of records. It can be added to the version of ML with record extension. However, many typed languages with record cannot type such a construct. The method still applies to them, producing type systems for record concatenation without removal of fields. Object systems also benefit of the encoding which shows that multiple inheritance does not actually require the concatenation of records but only their extension.
Type de document :
[Research Report] RR-1739, INRIA. 1992
Liste complète des métadonnées

Contributeur : Rapport de Recherche Inria <>
Soumis le : lundi 29 mai 2006 - 11:45:00
Dernière modification le : lundi 8 janvier 2018 - 16:54:04
Document(s) archivé(s) le : lundi 5 avril 2010 - 21:28:03



  • HAL Id : inria-00076978, version 1



Didier Rémy. Typing record concatenation for free. [Research Report] RR-1739, INRIA. 1992. 〈inria-00076978〉



Consultations de la notice


Téléchargements de fichiers