This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Documentation for attribute "comobject" (win32)


Hello,

In the other e-mail they are the patches for inclusion of the attribute
" comobject ", with this e-mail, I intend to supply the necessary
documentation.

The COM objects use a vtable in the form of an array of pointers for
virtual methods, when we used the " vtable-thunks ", we approached a lot
the format of the vtable of the gcc with used them in the COM. The
problem is in the first two entrances where don't exist corresponding in
the COM objects. This attribute allows the retreat of the first two
entrances without damage in the calls of the functions.

Attention, the attribute should just be used in objects that will make
the interface with Windows, in the other objects, we should work in the
normal way (with thunks or not, the person's will), since the first two
entrances are of internal use of the gcc.

So that this is possible, it should be made an alteration in the file "
objbase.h " that accompanies MSSDK increasing it the attribute in the
declare_interface corresponding to C++.

I created a " objbase.h " with the necessary minimum to work with
DirectX, case somebody is disposed to improve it, inform me so that I
can also modernize here mine.

This file is used for many other files of headers of MSSDK, besides for
OLE, I didn't still test that, but like Microsoft (they excuse for the
citation of the name) it shows in its MSSDK the OLE with possessing COM
objects, I believe that works without problems. (I think answered the
question fact for Mumit Khan regarding that).

In case the attribute is not documented correctly, I will be the
disposition to remove any doubt or still to improve the documentation
(in this case, indicate me the points to improve).

Regards

Antonio Mendes de Oliveira Neto (new e-mail address:
anmendes@splicenet.com.br)
Home page in http://www.geocities.com/SiliconValley/Sector/6464/


objbase.h


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]