@MISC{Lea90customizationin, author = {Douglas Lea}, title = {Customization in C++}, year = {1990} }
Years of Citing Articles
Bookmark
OpenURL
Abstract
Extensions to C ++ are proposed that would enable the directed synthesis of code as an alternative to dispatch-based code generation. The strategies are similar to those used in the SELF compiler, which uses customization techniques to impressive effect. The language extensions required to support customization also enhance support for other uses of inheritance in C++ , and are useful in conjunction with proposed additions of parametric types. 1 Introduction One of the smallest, but most important features introduced in C++ 2.0 is improved support for abstract base classes (ABCs) via the use of "pure virtual" member functions. For example, 1 class Matrix -- public: virtual ~Matrix() -- virtual int rows() const = 0; virtual int cols() const = 0; virtual float elem(int i, int j) const = 0; int size() -- return rows() * cols(); ; This declares a Matrix class in terms of its protocol or interface (i.e., the signatures of member functions), but not in terms of member function implement...