We present a translation from Fickle, a small object-oriented language allowing objects to change their class at runtime, into Java. The translation is provenly correct in the sense that it preserves the static and dynamic semantics. Moreover, it is compatible with separate compilation, since the translation of a Fickle class does not depend on the implementation of used classes. Based on the formal system, we have developed an implementation.The translation turned out to be a more subtle problem than we expected. In this article, we discuss four possible approaches we considered for the design of the translation and to justify our choice, we present formally the translation and proof of preservation of the static and dynamic semantics, and discuss the prototype implementation. Moreover, we outline an alternative translation based on generics that avoids most of the casts (but not all) needed in the previous translation.The language Fickle has undergone and is still undergoing several phases of development. In this article we are discussing the translation of FickleII.

A provenly correct translation of Fickle into Java

DAMIANI, Ferruccio;
2007-01-01

Abstract

We present a translation from Fickle, a small object-oriented language allowing objects to change their class at runtime, into Java. The translation is provenly correct in the sense that it preserves the static and dynamic semantics. Moreover, it is compatible with separate compilation, since the translation of a Fickle class does not depend on the implementation of used classes. Based on the formal system, we have developed an implementation.The translation turned out to be a more subtle problem than we expected. In this article, we discuss four possible approaches we considered for the design of the translation and to justify our choice, we present formally the translation and proof of preservation of the static and dynamic semantics, and discuss the prototype implementation. Moreover, we outline an alternative translation based on generics that avoids most of the casts (but not all) needed in the previous translation.The language Fickle has undergone and is still undergoing several phases of development. In this article we are discussing the translation of FickleII.
29(2)
1
67
http://dl.acm.org/citation.cfm?id=1216381
Type and effect systems; Semantics preserving translation
D. ANCONA; C. ANDERSON; F. DAMIANI; S. DROSSOPOULOU; P. GIANNINI; E. ZUCCA
File in questo prodotto:
File Dimensione Formato  
toplas2007.pdf

Accesso riservato

Tipo di file: PDF EDITORIALE
Dimensione 915.35 kB
Formato Adobe PDF
915.35 kB Adobe PDF   Visualizza/Apri   Richiedi una copia

I documenti in IRIS sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.

Utilizza questo identificativo per citare o creare un link a questo documento: https://hdl.handle.net/2318/40734
Citazioni
  • ???jsp.display-item.citation.pmc??? ND
  • Scopus 5
  • ???jsp.display-item.citation.isi??? 3
social impact