2003 · 10 citations · 4 references
ComputingComputer ScienceCompilersProgramming LanguagesSyntaxCompiler ConstructionControl-flow AnalysisData TypesObject-oriented ProgrammingType CheckingType SystemsCovarianceHierarchyPolymorphism StudiesRuntime Type CheckingRuntime Type SystemsStatic Type CheckingType PolymorphismType Safety
Goals of expressiveness and flexibility in typed object-oriented programming suggest a “covariant” type policy, where routine redefinitions can change the types of both arguments and results in the same direction as the inheritance hierarchy. Unfortunately, a careless covariant policy, when combined with polymorphism, genericity and dynamic binding — other O-O mechanisms that are just as fundamental — may lead to run-time type violations known as catcalls. We present a new solution to this problem, resulting from recent advances in the Eiffel language, which enables compilers to spot all potential catcalls and forces programmer to resolve them. The resulting language rules statically guarantee type safety; they only require local analysis and are easy to explain to programmers.
4
F-bounded polymorphism for object-oriented programming
Peter S. Canning, William R. Cook, Walter L. Hill et al. · 1989 · 330 citations
A Proposal for Making Eiffel Type-safe
William R. Cook · The Computer Journal · 1989 · 185 citations · Full text