POV-Ray : Newsgroups : povray.off-topic : Microsoft may have done something right... : Re: Microsoft may have done something right... Server Time
10 Oct 2024 23:19:45 EDT (-0400)
  Re: Microsoft may have done something right...  
From: Warp
Date: 26 Mar 2008 09:56:49
Message: <47ea6431@news.povray.org>
Orchid XP v7 <voi### [at] devnull> wrote:
> Well, take multiple inheritance for example. If your language supports 
> multiple inheritance, it can't support using the "super" keyword, 
> because it could refer to several different classes. (With single 
> inheritance, it is obviously quite unambiguous.) So even if you never 
> ever actually use MI, if the language your using supports it, it stops 
> you from being able to have a super keyword to use. You'll have to refer 
> to superclasses some other way.

  The solution is rather simple: One of the base classes is the "super"
class, the rest aren't. (This can be differentiated with keywords when
inheriting, or even by the order in which the inheritance list is
specified: The first base class mentioned can be the "super" class.)

  Think of it as the rest of the base classes being interfaces with
support for member variables and function implementations.

-- 
                                                          - Warp


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.