Proposal for making Eiffel type-safe

42Citations
Citations of this article
32Readers
Mendeley users who have this article in their library.
Get full text

Abstract

Statically type-correct Eiffel programs may produce run-time errors because (1) attributes may be redeclared during inheritance, invalidating assignments in the superclass, (2) a formal method argument type may be restricted in violation of the contravariance of function types, and (3) two applications of a generic class are assumed to conform if the actual arguments conform. The third problem is solved by case analysis on the variance of generic parameters. Declaration by association provides a solution to the first two problems, but it suffers from additional difficulties. Type attributes, or generic parameters with default values, are suggested as a replacement for most cases of declaration by association. The special association type used to express type recursion cannot be explained using type attributes, and it appears to be a truly novel construct for typing object-oriented programs. One consequence of this construct is that Eiffel's conformance hierarchy is a proper subset of its inheritance hierarchy.

Cite

CITATION STYLE

APA

Cook, W. R. (1989). Proposal for making Eiffel type-safe. Computer Journal, 32(4), 305–311. https://doi.org/10.1093/comjnl/32.4.305

Register to see more suggestions

Mendeley helps you to discover research relevant for your work.

Already have an account?

Save time finding and organizing research with Mendeley

Sign up for free