ICTCS 2003: Theoretical Computer Science pp 97-110 | Cite as
Refined Effects for Unanticipated Object Re-classification: \(\mathcal{F}ickle_{\rm 3}\)
Abstract
In previous work on the language \(\mathcal{F}ickle\) and its extension \(\mathcal{F}ickle_{II}\) Dezani and us introduced language features for object re-classification for imperative, typed, class-based, object-oriented languages.
In this paper we present the language \(\mathcal{F}ickle_{3}\), which on one side refines \(\mathcal{F}ickle_{II}\) with more expressive effect annotations, and on the other eliminates the need to declare explicitly which are the classes of the objects that may be re-classified. Therefore, \(\mathcal{F}ickle_{3}\) allows to correctly type meaningful programs which \(\mathcal{F}ickle_{II}\) rejects. Moreover, re-classification may be decided by the client of a class, allowing unanticipated object re-classification. As for \(\mathcal{F}ickle_{II}\), also the type and effect system for \(\mathcal{F}ickle_{3}\) guarantees that, even though objects may be re-classified across classes with different members, they will never attempt to access non existing members.
The type and effect system of \(\mathcal{F}ickle_{3}\) has some significant differences from the one of \(\mathcal{F}ickle_{II}\). In particular, besides the fact that intra-class type checking has to track the more refined effects, when a class is combined with other classes some additional inter-class checking is introduced.
Keywords
Class Membership Operational Semantic Object Orient Program Typing Rule Class HierarchyPreview
Unable to display preview. Download preview PDF.
References
- 1.Ancona, D., Anderson, C., Damiani, F., Drossopoulou, S., Giannini, P., Zucca, E.: An Effective Translation of Fickle into Java. In: Restivo, A., Ronchi Della Rocca, S., Roversi, L. (eds.) ICTCS 2001. LNCS, vol. 2202, pp. 215–234. Springer, Heidelberg (2001)CrossRefGoogle Scholar
- 2.Chambers, C.: Predicate Classes. In: Nierstrasz, O. (ed.) ECOOP 1993. LNCS, vol. 707, pp. 268–296. Springer, Heidelberg (1993)CrossRefGoogle Scholar
- 3.P. Costanza. Dynamic Object Replacement and Implementation-Only Classes. In WCOP 2001 (at ECOOP 2001) (2001), Available from http://www.cs.uni-bonn.de/~costanza/implementationonly.pdf
- 4.Damiani, F., Dezani-Ciancaglini, M., Drossopoulou, S., Giannini, P.: Refined Effects for Re-classification: FickleIII(2002). Report for the IST-2001-33477 DART project - available at the http://www.cee.hw.ac.uk/DART/reports/D3.1/DDDG02b.pdf
- 5.Drossopoulou, S., Damiani, F., Dezani-Ciancaglini, M., Giannini, P.: Fickle: Dynamic Object Re-classification. In: Knudsen, J.L. (ed.) ECOOP 2001. LNCS, vol. 2072, pp. 130–149. Springer, Heidelberg (2001); A shorter version is available in: Electronic proceedings of FOOL8, http://www.cs.williams.edu/~kim/FOOL/ CrossRefGoogle Scholar
- 6.Drossopoulou, S., Damiani, F., Dezani-Ciancaglini, M., Giannini, P.: More Dynamic Object Re-classification: Fickle II. ACM Transactions On Programming Languages and Systems 24(2), 153–191 (2002)CrossRefGoogle Scholar
- 7.Drossopoulou, S., Eisenbach, S., Khurshid, S.: Is the Java Type System Sound? Theory and Practice of Object Systems 5(1), 3–24 (1999)CrossRefGoogle Scholar
- 8.Ghelli, G., Palmerini, D.: Foundations of Extended Objets with Roles (extended abstract). In: FOOL6 (1999), Available from http://www.cs.williams.edu/~kim/FOOL/FOOL6.html
- 9.Lucassen, M., Gifford, D.K.: Polymorphic Effect Systems. In: POPL 1988, pp. 47–57. ACM Press, New York (1988)CrossRefGoogle Scholar
- 10.Serrano, M.: Wide Classes. In: Guerraoui, R. (ed.) ECOOP 1999. LNCS, vol. 1628, pp. 391–415. Springer, Heidelberg (1999)CrossRefGoogle Scholar
- 11.Tailvasaari, A.: Object Oriented Programming with Modes. Journal of Object Oriented Programming 6(3), 27–32 (1993)Google Scholar
- 12.Talpin, J.-P., Jouvelot, P.: Polymorphic Type, Region and Effect Inference. Journal of Functional Programming 2(3), 245–271 (1992)MATHCrossRefMathSciNetGoogle Scholar