From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32628 invoked by alias); 13 Jul 2008 06:07:48 -0000 Received: (qmail 32620 invoked by uid 22791); 13 Jul 2008 06:07:48 -0000 X-Spam-Check-By: sourceware.org Received: from server265-han.de-nserver.de (HELO server265-han.de-nserver.de) (85.158.176.48) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sun, 13 Jul 2008 06:07:27 +0000 Received: (qmail 8615 invoked from network); 13 Jul 2008 08:07:16 +0200 Received: from 77-57-88-156.dclient.hispeed.ch (HELO macpro.local) (77.57.88.156) (smtp-auth username martinka, mechanism plain) by server265-han.de-nserver.de (qpsmtpd/0.40) with ESMTPA; Sun, 13 Jul 2008 08:07:16 +0200 Received: from macpro.krischik.com (macpro.krischik.com [192.168.0.31]) by macpro.local (Postfix) with ESMTP id 609F184665D for ; Sun, 13 Jul 2008 08:07:21 +0200 (CEST) From: Martin Krischik To: gcc-help@gcc.gnu.org Subject: Re: single virtual inheritance Date: Sun, 13 Jul 2008 06:57:00 -0000 User-Agent: KMail/1.9.7 References: <25c035550807121715n386444v9cbfce8b03e599ea@mail.gmail.com> In-Reply-To: <25c035550807121715n386444v9cbfce8b03e599ea@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart46767036.VUBvhJiPft"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200807130807.14765.krischik@users.sourceforge.net> X-User-Auth: Auth by martinka through 77.57.88.156 X-IsSubscribed: yes Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2008-07/txt/msg00169.txt.bz2 --nextPart46767036.VUBvhJiPft Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Content-length: 719 Am Sonntag 13 Juli 2008 schrieb - -: > What is the cost, if any, of inheriting a virtual base class only once > (not using multiple inheritance) vs. non-virtual single inheritance? The cost is a single pointer redirection - the same as between=20 using "some_type some_var" and "some_type& some_var". But the gain is extensabitlity and maintainabiltiy. I have seen the neibour= ing=20 team doing a one week 5 person refactoring run because they dicovered the=20 value of virtual inheritance to late. Always remember: there is a cost of not using a feature as well - and it mi= ght=20 be your weekend not beeing at home but doing refactoring. Martin --=20 Martin Krischik mailto://krischik@users.sourceforge.net --nextPart46767036.VUBvhJiPft Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part. Content-length: 186 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (Darwin) iD8DBQBIeZuPijwKaHyem9cRAj6hAJ0ZdZRK4yOTBFM7GVHRUmibh8/d7ACffU26 GorSDVu7jlp/gNFrUVriOQw= =OONt -----END PGP SIGNATURE----- --nextPart46767036.VUBvhJiPft--