Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!lll-winken!elroy.jpl.nasa.gov!decwrl!sgi!shinobu!odin!sgi.com!linton From: linton@sgi.com (Mark Linton) Newsgroups: comp.lang.c++ Subject: Re: Nonvirtual base classes in MI Message-ID: <1991Jan31.164927.3234@odin.corp.sgi.com> Date: 31 Jan 91 16:49:27 GMT References: <1159@zinn.MV.COM> Sender: news@odin.corp.sgi.com (Net News) Reply-To: linton@sgi.com (Mark Linton) Organization: sgi Lines: 14 In article <1159@zinn.MV.COM>, mjv@objects.mv.com (Michael J. Vilot) writes: |> Scott Meyers asked for an example of using multiple inheritance without using |> virtual base classes. I used exactly this approach in the design of the C++ |> Booch Components library, to use mixin classes to achieve a couple of purposes. I think you missed the point of Scott's question. You describe a situation in which you did not need virtual base classes. What Scott asked is if any one needs non-virtual base classes. Presumably, your code would have functioned correctly if you had made all your derivations virtual (in fact, you really should make all your reference counting derivations virtual because you don't want a descendant to have multiple ref counts). I would like to echo the original question, as I also have not encountered a situation where I need non-virtual base classes.