Re: Someone explain me this code




"Tran Hong Quang" <TranHongQuang@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:4D3408BE-CF76-44D6-81BB-2095E0DACBCE@xxxxxxxxxxxxxxxx
Hi,
In header file, I see this declaration:

#define DECLARE_VTBL(iname) iname vt##iname;

then, in C file, there are below codes:

typedef struct _Abc {
.........
} abc;
DECLARE_VTBL(abc)

The macro expands to:

abc vtabc;

Which will be a set of function pointers serving as the vtable (native
invocation, as opposed to dispatch invocation) for COM objects written in C.
In C++ they would be member functions and the compiler would create the
vtable.


I don't understant these code. Could someone explain me what it does?

Thanks
Tran Hong Quang


.



Relevant Pages

  • Re: Looking up a value within a range of 3 letter or number codes
    ... correct West or East designation if I were looking for the code "500". ... if the formula was looking in the range for the code "ABC" and it ... Any thoughts on how to make the formula work with both 3 character codes ... if whatever is in the cell B3 is ...
    (microsoft.public.excel.worksheet.functions)
  • Re: [Clax86list] using common macros in NASM and C
    ... %define abc 1 ... so I face a problem in using the same header file containing ... Does NASM support any sort of #ifdef so as to handle the ... compiler constant that can be checked? ...
    (comp.lang.asm.x86)
  • Re: A question about the Count/CountIf function
    ... the amount of times that they appear in that specific column. ... So I have one column with codes in (e.g. ABC and DEF) and I ... amount of times that ABC appears when it weighs less than 1.0 and is ...
    (microsoft.public.excel.worksheet.functions)
  • Re: Interfacing static C libraries with JNI
    ... > public native void abc(int flag, String message, String command); ... nm confirms that abc is *undefined* in your shared library. ... DO I need to include header file for abcas well in ...
    (comp.lang.java.programmer)
  • Re: Thou shalt have no other gods before the ANSI C standard
    ... >> for) ABC. ... >manages its buffers in a better manner. ... When dealing with collections of data from a database, ... whose return codes I also check, and treat as locally fatal errors. ...
    (sci.crypt)