Quote Originally Posted by Wh1t3gh0st View Post
[...] how do you access the private data members of the base class?
... or simply make them protected rather than private. That way they are visible to derived classes but not to "the outside world", which may be exactly what you're looking for.

However, similar to Paul, I tend to question some fundamental aspect of your design: IMO it doesn't make much sense to derive a date class from a day class. I'd rather use composition, i.e. make the day a member of the date class.

Also I don't quite see a need for a day class in the first place. If I would write a date class, the day would probably either be an int member, an accessor method to such a member or a method that calculates the day based on some other (i.e. no integral year month and day components) internal representation of the date.