simple question about typedef....

Started by
2 comments, last by Metal Typhoon 21 years, 5 months ago
what is this meaning ? typedef void (WINAPI *cfunc) (); changing void to something... i dont get it.. i''m learning how to load use a dll thx in advance Metal Typhoon
Metal Typhoon
Advertisement
That defines a function pointer type for function pointers that point to a function with the prototype:
void WINAPI myfunc();


[edited by - Asgard on November 1, 2002 5:48:17 PM]
----------------------XEngine - The Platform- and API-Independent 3D Engine with Programmable Pipeline Support: http://xengine.sourceforge.net My Music on MP3.com: http://www.mp3.com/GroovingArts
It makes a type that is a function pointer, for functions that take no parameters and return nothing (with whatever storage modifiers WINAPI is defined as). And it calls the type cfunc.
so if i want to typedef a function that returns a poointer it should be like this ?

typedef RETURNTYPE (WINAPI *NAME) (); ???
and one last question how would u export a class...

extern "C"_declspec (dllexport)

// CLASS

?? or do i have to do in every fucntion definition for the class ?

thx alot..

Metal Typhoon
Metal Typhoon

This topic is closed to new replies.

Advertisement