In languages like C++, the mechanism of protected members is critical to making inheritance work. It allows access to some of the internals of a base class B to the designer of a derived class D, while denying it to clients of B. We develop a formal approach in which class behavior is precisely specified in terms of an abstract specification and a concrete specification, the former for use by a client, the latter containing information about how the protected members change, for use by a derived class designer. We present rules that allow us to establish that a class meets both specifications
To submit an update or takedown request for this paper, please submit an Update/Correction/Removal Request.