Click here to Skip to main content
15,925,255 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: dialog Pin
Joaquín M López Muñoz7-Nov-02 12:05
Joaquín M López Muñoz7-Nov-02 12:05 
GeneralRe: dialog Pin
pnpfriend8-Nov-02 3:28
pnpfriend8-Nov-02 3:28 
GeneralC++ Help Needed Pin
Anonymous7-Nov-02 9:19
Anonymous7-Nov-02 9:19 
GeneralRe: C++ Help Needed Pin
Marc Clifton7-Nov-02 9:23
mvaMarc Clifton7-Nov-02 9:23 
QuestionMulti-View Single Doc example? Pin
Nick Jacobs7-Nov-02 9:10
Nick Jacobs7-Nov-02 9:10 
GeneralSAPI Pin
Anonymous7-Nov-02 9:14
Anonymous7-Nov-02 9:14 
Generalvirtual function confusion VTABLE Pin
ns7-Nov-02 8:47
ns7-Nov-02 8:47 
GeneralRe: virtual function confusion VTABLE Pin
Tim Smith7-Nov-02 8:51
Tim Smith7-Nov-02 8:51 
First off, you really shouldn't care about the vtable since it can change from implementation to implementation.

Now, for the information you requested.

A VTable is just a pointer to an array of function pointers. In MSVC, this pointer is at the start of the structure or class. It will be 4 bytes wide. The reason that your structure is 32 bytes in size is that doubles are naturally aligned and thus must be on an 8 byte boundary. This means that 4 bytes of padding after the vtable is required to align the first double. Thus, 3 * 8 + 4(vtable) + 4(pad) = 32


Tim Smith

I'm going to patent thought. I have yet to see any prior art.
GeneralRe: virtual function confusion VTABLE Pin
ns7-Nov-02 8:59
ns7-Nov-02 8:59 
GeneralRe: virtual function confusion VTABLE Pin
Tim Smith7-Nov-02 10:03
Tim Smith7-Nov-02 10:03 
GeneralRe: virtual function confusion VTABLE Pin
Joaquín M López Muñoz7-Nov-02 8:48
Joaquín M López Muñoz7-Nov-02 8:48 
GeneralRe: virtual function confusion VTABLE Pin
ns7-Nov-02 9:02
ns7-Nov-02 9:02 
GeneralRe: virtual function confusion VTABLE Pin
Joaquín M López Muñoz7-Nov-02 9:04
Joaquín M López Muñoz7-Nov-02 9:04 
GeneralThank you! Pin
ns7-Nov-02 9:12
ns7-Nov-02 9:12 
GeneralToolbar tooltip question Pin
Stevenpph7-Nov-02 8:41
Stevenpph7-Nov-02 8:41 
GeneralRe: Toolbar tooltip question Pin
Joaquín M López Muñoz7-Nov-02 9:28
Joaquín M López Muñoz7-Nov-02 9:28 
GeneralRe: Toolbar tooltip question Pin
Stevenpph7-Nov-02 10:06
Stevenpph7-Nov-02 10:06 
GeneralRe: Toolbar tooltip question Pin
Joaquín M López Muñoz7-Nov-02 10:11
Joaquín M López Muñoz7-Nov-02 10:11 
GeneralDynamic Prop. Sheet Pin
john john mackey7-Nov-02 8:31
john john mackey7-Nov-02 8:31 
GeneralRe: Dynamic Prop. Sheet Pin
Joaquín M López Muñoz7-Nov-02 8:44
Joaquín M López Muñoz7-Nov-02 8:44 
GeneralRe: Dynamic Prop. Sheet Pin
Joan M7-Nov-02 8:52
professionalJoan M7-Nov-02 8:52 
GeneralLock xadd Pin
José Luis Sogorb7-Nov-02 6:57
José Luis Sogorb7-Nov-02 6:57 
GeneralRe: Lock xadd Pin
Daniel Turini7-Nov-02 7:07
Daniel Turini7-Nov-02 7:07 
QuestionCRichEditCtrl printng... What's wrong with my code? Pin
Nasty_p7-Nov-02 5:04
Nasty_p7-Nov-02 5:04 
AnswerRe: CRichEditCtrl printng... What's wrong with my code? Pin
dabs7-Nov-02 5:38
dabs7-Nov-02 5:38 

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.