473,503 Members | 1,657 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

virtual inheritance

Hello everyone,
I have learned public/private/protected inheritance, but what is virtual
inheritance? Here is the sample,

class Usable : public virtual Usable_lock

http://www.research.att.com/~bs/bs_f...#no-derivation
thanks in advance,
George
Oct 22 '07 #1
4 899
http://en.wikipedia.org/wiki/Virtual_inheritance

--
Cholo Lennon
Bs.As.
ARG
"George" <Ge****@discussions.microsoft.comwrote in message
news:30**********************************@microsof t.com...
Hello everyone,
I have learned public/private/protected inheritance, but what is virtual
inheritance? Here is the sample,

class Usable : public virtual Usable_lock

http://www.research.att.com/~bs/bs_f...#no-derivation
thanks in advance,
George

Oct 22 '07 #2
Thanks Cholo,
I can not access the page, can you help to paste some information here please?
regards,
George

"Cholo Lennon" wrote:
http://en.wikipedia.org/wiki/Virtual_inheritance

--
Cholo Lennon
Bs.As.
ARG
"George" <Ge****@discussions.microsoft.comwrote in message
news:30**********************************@microsof t.com...
Hello everyone,
I have learned public/private/protected inheritance, but what is virtual
inheritance? Here is the sample,

class Usable : public virtual Usable_lock

http://www.research.att.com/~bs/bs_f...#no-derivation
thanks in advance,
George


Oct 22 '07 #3
George wrote:
Hello everyone,
I have learned public/private/protected inheritance, but what is
virtual inheritance? Here is the sample,

class Usable : public virtual Usable_lock

http://www.research.att.com/~bs/bs_f...#no-derivation
The C++ FAQ is your friend:

http://www.parashift.com/c++-faq-lit....html#faq-25.8

-cd
Oct 22 '07 #4
Thanks cd,
Very useful resource.
regards,
George

"Carl Daniel [VC++ MVP]" wrote:
George wrote:
Hello everyone,
I have learned public/private/protected inheritance, but what is
virtual inheritance? Here is the sample,

class Usable : public virtual Usable_lock

http://www.research.att.com/~bs/bs_f...#no-derivation

The C++ FAQ is your friend:

http://www.parashift.com/c++-faq-lit....html#faq-25.8

-cd
Oct 23 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

18
2186
by: nenad | last post by:
Wouldn't it be nice if we could do something like this: class Funky{ public: auto virtual void doStuff(){ // dostuff } };
4
2881
by: JKop | last post by:
I'm starting to think that whenever you derive one class from another, that you should use virtual inheritance *all* the time, unless you have an explicit reason not to. I'm even thinking that...
14
1893
by: Bruno van Dooren | last post by:
Hi all, i am having a problems with inheritance. consider the following: class A { public: A(int i){;} };
3
1697
by: Imre | last post by:
Hi! I've got some questions regarding heavy use of virtual inheritance. First, let's see a theoretical situation, where I might feel tempted to use a lot of virtual inheritance. Let's...
3
4532
by: kikazaru | last post by:
Is it possible to return covariant types for virtual methods inherited from a base class using virtual inheritance? I've constructed an example below, which has the following structure: Shape...
12
2637
by: mijobee | last post by:
I'm very new to c++ and just writing some code to learn. I've run into a problem, with a javaish design, and want to know if there is any possible solution without modifying the design. I've read...
5
1968
by: toton | last post by:
Hi, I want a few of my class to overload from a base class, where the base class contains common functionality. This is to avoid repetition of code, and may be reducing amount of code in binary,...
23
4577
by: Dave Rahardja | last post by:
Since C++ is missing the "interface" concept present in Java, I've been using the following pattern to simulate its behavior: class Interface0 { public: virtual void fn0() = 0; };
12
2339
by: Massimo | last post by:
Hi to all, I'm facing a problem in a particularly complex inheritance hierarchy, and I'd like to know what the standard says about it and if my compiler is correct in what it does. I have two...
0
1293
by: =?Utf-8?B?Zmplcm9uaW1v?= | last post by:
Hi all, As I mentioned in a previous thread (see 'Dbghelp, symbols and templates' in microsoft.public.windbg), we created a powerful symbol engine using dbghelp to dump the contents of the stack...
0
7072
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7319
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6979
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7449
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
3160
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3149
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1498
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
730
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
373
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.