On understanding types, data abstraction, and polymorphism
ACM Computing Surveys (CSUR) - The MIT Press scientific computation series
How to make ad-hoc polymorphism less ad hoc
POPL '89 Proceedings of the 16th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Higher-order modules and the phase distinction
POPL '90 Proceedings of the 17th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
F-bounded polymorphism for object-oriented programming
FPCA '89 Proceedings of the fourth international conference on Functional programming languages and computer architecture
Dynamic typing in a statically typed language
ACM Transactions on Programming Languages and Systems (TOPLAS)
Inheritance as implicit coercion
Information and Computation
Type classes and overloading resolution via order-sorted unification
Proceedings of the 5th ACM conference on Functional programming languages and computer architecture
On the complexity of ML typeability with overloading
Proceedings of the 5th ACM conference on Functional programming languages and computer architecture
A gentle introduction to Haskell
ACM SIGPLAN Notices - Haskell special issue
Report on the programming language Haskell: a non-strict, purely functional language version 1.2
ACM SIGPLAN Notices - Haskell special issue
LFP '92 Proceedings of the 1992 ACM conference on LISP and functional programming
Type inference in the presence of overloading, subtyping and recursive types
LFP '92 Proceedings of the 1992 ACM conference on LISP and functional programming
ACM Transactions on Programming Languages and Systems (TOPLAS)
POPL '93 Proceedings of the 20th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Semantics of type classes revisited
LFP '94 Proceedings of the 1994 ACM conference on LISP and functional programming
Compiling polymorphism using intensional type analysis
POPL '95 Proceedings of the 22nd ACM SIGPLAN-SIGACT symposium on Principles of programming languages
A type-based compiler for standard ML
PLDI '95 Proceedings of the ACM SIGPLAN 1995 conference on Programming language design and implementation
Kinded type inference for parametric overloading
Acta Informatica
Theory and Practice of Object Systems - Special issue: type systems
TIL: a type-directed optimizing compiler for ML
PLDI '96 Proceedings of the ACM SIGPLAN 1996 conference on Programming language design and implementation
ACM Transactions on Programming Languages and Systems (TOPLAS)
Vortex: an optimizing compiler for object-oriented languages
Proceedings of the 11th ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications
Making the future safe for the past: adding genericity to the Java programming language
Proceedings of the 13th ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications
Compatible genericity with run-time types for the Java programming language
Proceedings of the 13th ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications
Dynamic typing for distributed programming in polymorphic languages
ACM Transactions on Programming Languages and Systems (TOPLAS)
Proceedings of the fourth ACM SIGPLAN international conference on Functional programming
A Machine-Oriented Logic Based on the Resolution Principle
Journal of the ACM (JACM)
Deciding type equivalence in a language with singleton kinds
Proceedings of the 27th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Object-Oriented Software Construction
Object-Oriented Software Construction
The Definition of Standard ML
Parametric Overloading in Polymorphic Programming Languages
ESOP '88 Proceedings of the 2nd European Symposium on Programming
ML Typing, Explicit Polymorphism and Qualified Types
TACS '94 Proceedings of the International Conference on Theoretical Aspects of Computer Software
Rationale for the design of the Ada programming language
ACM SIGPLAN Notices - Rationale for the deisgn of the Ada programming language
Constraint-set satisfiability for overloading
PPDP '04 Proceedings of the 6th ACM SIGPLAN international conference on Principles and practice of declarative programming
ACM Transactions on Programming Languages and Systems (TOPLAS)
Hi-index | 5.23 |
Constrained genericity is an extension of parametric polymorphism, that allows type parameters in polymorphic procedures to be constrained to have certain operations defined over them. It is realized in the Ada and Haskell programming languages, as exemplified by type classes in Haskell. Type classes only allow a single global scope for instances of type classes. This article introduces a type system and a semantics that allows both dynamic and static scoping of such operations to be mixed in a program. Applications include overcoming scoping problems with constrained genericity, enabling program optimizations, and programming with dynamic data structures. Type classes with "open" scope obey the usual semantics for Haskell type classes, based on call-site "type dictionaries". Type classes with "closed" scope use run-time type descriptions to dispatch to instances. The type system to support this combines operator kinds, refinement kinds and singleton kinds. The system is extended to allow overlapping specialized instance types, in order to support specialized representations for data structures (for example, arrays of integers, arrays of floats and arrays of boxed values). This extension requires the combination of both type dictionaries and run-time type information for type class dispatching.