n4mwd wrote:
Then enlighten me please. Windows requires a C/PASCAL function call. C++ calls don't work. Without making C style calls, how would C++ do this?
What are you talking about? Are you honestly saying that C++ calls don't work in Windows without some kind of special library? If so, you're wrong.
There is a large portion of the Win32 API that requires either the cdecl or pascal calling convention. Most of these are native C functions and their calling conventions are defined as such in their respective header files. For example:
Code:
int PASCAL FAR closesocket ( IN SOCKET s);
or
Code:
HRESULT __cdecl Initialize (void);
Since this is in the header file, the compiler can build the function call rather than having to do it at run-time. That means the C++ compiler can build the function call exactly the same as the C compiler which should yield equal efficiency.
I'm also not sure why you're grouping "C/PASCAL" since their calling conventions are totally different.