1) Can someone explain the following?
void OnCreate(HWND hWnd, const LPCREATESTRUCT lpCreateStruct)
{
lpCreateStruct->x = 2; // this compiles
}
void OnCreate(HWND hWnd, const CREATESTRUCT * lpCreateStruct)
{
lpCreateStruct->x = 2; // this does not compile
}
2) Is it faster to pass by pointer or by reference? Or the same?