Click here to Skip to main content
16,011,120 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: any limitations to VTable ??? Pin
Chris Losinger29-Jun-05 3:33
professionalChris Losinger29-Jun-05 3:33 
GeneralRe: any limitations to VTable ??? Pin
Chintoo72329-Jun-05 3:41
Chintoo72329-Jun-05 3:41 
GeneralRe: any limitations to VTable ??? Pin
Chintoo72329-Jun-05 3:42
Chintoo72329-Jun-05 3:42 
GeneralRe: any limitations to VTable ??? Pin
Chris Losinger29-Jun-05 3:48
professionalChris Losinger29-Jun-05 3:48 
GeneralRe: any limitations to VTable ??? Pin
Chintoo72329-Jun-05 3:55
Chintoo72329-Jun-05 3:55 
GeneralRe: any limitations to VTable ??? Pin
Chintoo72329-Jun-05 3:56
Chintoo72329-Jun-05 3:56 
GeneralRe: any limitations to VTable ??? Pin
Chris Losinger29-Jun-05 4:03
professionalChris Losinger29-Jun-05 4:03 
GeneralRe: any limitations to VTable ??? Pin
Chintoo72329-Jun-05 4:18
Chintoo72329-Jun-05 4:18 
The first one is no surprise as the compiler will pick the method of class on which you are calling the function. The second one is interesting, but it too is not a surprise to me as you have defined doo as virtual in the base class. Can you do a couple more tests:

1. Do not define doo as virtual in foo, and try this:
<br />
foo *f = new voo;<br />
f->doo(3,3); <br />


2. what if both the prototypes are in the same class, which one does the compiler pick:
<br />
class foo {<br />
   void doo(int i, ...) {<br />
       TRACE ("int i, ...");<br />
   }<br />
   void doo(int i, int j) {<br />
       TRACE("int i, int j");<br />
   }   <br />
}<br />
foo f;<br />
f.doo(3, 3);<br />

GeneralRe: any limitations to VTable ??? Pin
Chris Losinger29-Jun-05 4:23
professionalChris Losinger29-Jun-05 4:23 
GeneralRe: any limitations to VTable ??? Pin
Chintoo72329-Jun-05 4:34
Chintoo72329-Jun-05 4:34 
Generalcan't compile my codes...pls help Pin
Member 208234129-Jun-05 2:11
Member 208234129-Jun-05 2:11 
GeneralRe: can't compile my codes...pls help Pin
Cillieacc0rd5o429-Jun-05 2:14
Cillieacc0rd5o429-Jun-05 2:14 
GeneralRe: can't compile my codes...pls help Pin
Ravi Bhavnani29-Jun-05 2:24
professionalRavi Bhavnani29-Jun-05 2:24 
GeneralRe: can't compile my codes...pls help Pin
ThatsAlok29-Jun-05 2:26
ThatsAlok29-Jun-05 2:26 
GeneralRe: can't compile my codes...pls help Pin
ThatsAlok29-Jun-05 2:25
ThatsAlok29-Jun-05 2:25 
GeneralRe: can't compile my codes...pls help Pin
krmed29-Jun-05 3:03
krmed29-Jun-05 3:03 
GeneralRe: can't compile my codes...pls help Pin
Member 208234129-Jun-05 11:10
Member 208234129-Jun-05 11:10 
GeneralRe: can't compile my codes...pls help Pin
krmed30-Jun-05 0:52
krmed30-Jun-05 0:52 
GeneralRe: can't compile my codes...pls help Pin
toxcct29-Jun-05 5:37
toxcct29-Jun-05 5:37 
GeneralC++ Loop statment Or LoopFor Pin
Cillieacc0rd5o429-Jun-05 2:06
Cillieacc0rd5o429-Jun-05 2:06 
GeneralRe: C++ Loop statment Or LoopFor Pin
Ravi Bhavnani29-Jun-05 2:27
professionalRavi Bhavnani29-Jun-05 2:27 
GeneralRe: C++ Loop statment Or LoopFor Pin
Cillieacc0rd5o429-Jun-05 2:32
Cillieacc0rd5o429-Jun-05 2:32 
GeneralRe: C++ Loop statment Or LoopFor Pin
Ravi Bhavnani29-Jun-05 2:41
professionalRavi Bhavnani29-Jun-05 2:41 
GeneralRe: C++ Loop statment Or LoopFor Pin
Cillieacc0rd5o429-Jun-05 2:42
Cillieacc0rd5o429-Jun-05 2:42 
GeneralRe: C++ Loop statment Or LoopFor Pin
Maximilien29-Jun-05 2:45
Maximilien29-Jun-05 2:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.