Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!att!mtuxo!rolls!westmark!mole-end!mat From: mat@mole-end.UUCP (Mark A Terribile) Newsgroups: comp.lang.c++ Subject: Re: MI and namespaces Keywords: MI namespaces Message-ID: <195@mole-end.UUCP> Date: 20 May 89 05:52:36 GMT References: <192@mole-end.UUCP> <11541@ulysses.homer.nj.att.com> Organization: mole-end--private system. admin: mole-end!newtnews Lines: 37 > >I fear that inheriting from lots and lots of base classes ... is almost sure > >to lead, sooner or later, to enough ``print''s and ``dump''s ... that we > >are either going to begin prefixing these names with the class qualifer out > >of habit or we are going to prepend the class's name to the member name > >we would like to use. > I suggest that when you derive a class D from multiple base classes > that both have a "print", or "dump", you have a real ambiguity and > the programmer must resolve it by supplying a "D::print" a "D::dump", > etc. ... [I think] that the name space controls we have are inadequate. It does, however, create problems for maintainance and enhancement. If XYZ company releases an improved version of their ZeeYooXee class and library, they can create an ambiguity in my code. The inability to say ``you can get the name, but we won't press it on you,'' leaves no ``out'' for the designer of a class who has to get everything right for all time. > I agree that MI makes it more delicate to add members to base > classes. There has always been the potential for problems when you > do this, but they are more likely to arise in the presense of MI. It makes it much harder or more dangerous to use MI freely in large, real-world projects. C++ is the only thing that can support MI (or something like it) with reasonable efficiency. Having people ``protect'' all their (potentially) virtual function calls with class quailfiers to safeguard the next generation of developers seems to me to impair the usefulness of the semantics. I realize that, as with everything else, it's easier to botch language changes of this sort than to get them right. I also don't expect to hit this problem for a few years. I would like, though, to believe that someone is thinking about the problem. -- (This man's opinions are his own.) From mole-end Mark Terribile