Overloaded Function

14,000,000 Leading Edge Experts on the ideXlab platform

Scan Science and Technology

Contact Leading Edge Experts & Companies

Scan Science and Technology

Contact Leading Edge Experts & Companies

The Experts below are selected from a list of 45 Experts worldwide ranked by ideXlab platform

Giorgio Ghelli - One of the best experts on this subject based on the ideXlab platform.

  • LISP and Functional Programming - A calculus for Overloaded Functions with subtyping
    Proceedings of the 1992 ACM conference on LISP and functional programming - LFP '92, 1992
    Co-Authors: Giuseppe Castagna, Giorgio Ghelli, Giuseppe Longo
    Abstract:

    We present a simple extension of typed λ-claculus where Functions can be Overloaded by adding different “pieces of code”. In short, the code of an Overloaded Function is formed by several branches of code; the branch to execute is chosen, when the Function is applied, according to a particular selection rule which depends on the type of the argument. The crucial feature of the present approach is that a subtyping relation is defied among types, such that the type of a term generally decreases during computation, and this fact induces a distinction between the “compile-time” type and the “run-time”type of a term. We study the case of Overloaded Functions where the branch selection depends on the run-time type of the argument, so that overloading cannot be eliminated by a static analysis of code, but is an essential feature to be dealt with during computation. We prove Confluence and Strong Normalization for this calculus as well as a generalized Subject-Reduction theorem (but proofs are ommitted in this abstract. The definition of this calculus is driven by the understanding of object-oriented features and the connections between our calculus and object-orientedness are extensively stressed. We show that this calculus provides a foundation for typed object-oriented languages which solves some of the problems of the standard record-based approach. It also provides a type-discipline for a relevant fragment of the “core framework” of CLOS.

  • OOPSLA - A static type system for message passing
    ACM SIGPLAN Notices, 1991
    Co-Authors: Giorgio Ghelli
    Abstract:

    Much research has been performed with the aim of isolating the basic notions of object-oriented languages and of describing them by basic operators which can be embedded in strongly-typed languages. In this context we define an atomic linguistic construct to capture the notion of message passing, and we define a static and strong type system, based on subtyping, for this construct. Message passing is modelled as the application of an Overloaded Function, whose behavior is determined only at compile-time on the basis of the class which created a distinguished argument, the object “receiving” the message. By embedding this mechanism in a strongly-typed language with subtyping and abstract data types we can obtain the full Functionality of object-oriented languages. We show that this approach is strictly more expressive then the usual interpretation of message passing as selection plus application of a Functional record field.

Lisa Marie Levy Kortright - One of the best experts on this subject based on the ideXlab platform.

  • A type system for overloading and parametric polymorphism in programming languages
    1992
    Co-Authors: Lisa Marie Levy Kortright
    Abstract:

    In this work, we examine the problem of typing, at compile-time, a program containing polymorphic and Overloaded Function identifiers in a language in which type information is not explicitly provided for user-defined identifiers and expressions. We develop a type system that integrates overloading and parametric polymorphism in a consistent manner. This type system is obtained by extending the Hindley/Milner parametric polymorphic type system with types suitable for Overloaded Function identifiers. This results in uniform treatment of expressions containing Overloaded Function identifiers and parametric polymorphic identifiers. We proceed as follows. First, we determine the form of a type for an Overloaded Function identifier. The central idea in our development of a type for an Overloaded identifier is that of a restriction set. In our type system, type variables have restriction sets associated with them. The restriction set restricts the types that a type variable may assume. We next develop type inference rules for assigning types to expressions involving overloading and parametric polymorphism. Then, we develop a type inference algorithm that assigns a type in this extended type system to an expression in the absence of explicit type declarations. Since no explicit type declarations are required in our type system, after the types of the individual definitions of an Overloaded Function identifier have been assigned, a type must be constructed from this set of types representing the type of the Overloaded identifier itself. Both the type inference rules and the type inference algorithm require a Function to find the most general scheme of a set of type expressions. This most general scheme is the type assigned to the Overloaded Function identifier. The type inference algorithm uses unification to solve the set of type equations which are generated from the expression being typed. We give the unification algorithm needed to unify type expressions that contain type variables having restriction sets associated with them.

Longogiuseppe - One of the best experts on this subject based on the ideXlab platform.

Giuseppe Longo - One of the best experts on this subject based on the ideXlab platform.

  • LISP and Functional Programming - A calculus for Overloaded Functions with subtyping
    Proceedings of the 1992 ACM conference on LISP and functional programming - LFP '92, 1992
    Co-Authors: Giuseppe Castagna, Giorgio Ghelli, Giuseppe Longo
    Abstract:

    We present a simple extension of typed λ-claculus where Functions can be Overloaded by adding different “pieces of code”. In short, the code of an Overloaded Function is formed by several branches of code; the branch to execute is chosen, when the Function is applied, according to a particular selection rule which depends on the type of the argument. The crucial feature of the present approach is that a subtyping relation is defied among types, such that the type of a term generally decreases during computation, and this fact induces a distinction between the “compile-time” type and the “run-time”type of a term. We study the case of Overloaded Functions where the branch selection depends on the run-time type of the argument, so that overloading cannot be eliminated by a static analysis of code, but is an essential feature to be dealt with during computation. We prove Confluence and Strong Normalization for this calculus as well as a generalized Subject-Reduction theorem (but proofs are ommitted in this abstract. The definition of this calculus is driven by the understanding of object-oriented features and the connections between our calculus and object-orientedness are extensively stressed. We show that this calculus provides a foundation for typed object-oriented languages which solves some of the problems of the standard record-based approach. It also provides a type-discipline for a relevant fragment of the “core framework” of CLOS.

Castagnagiuseppe - One of the best experts on this subject based on the ideXlab platform.