It does not seem to make a difference.
If none of the functions are static, it works fine. it's because they are static, but there's got to be some way for this to work...
Pointers to static member functions take the same form as a standard C++
function pointer.
The compiler gave the game away in the way it wrote it error message.
1 2 3 4 5 6 7 8 9 10 11 12
class Packages {
public:
staticvoid Load( constchar* dir );
private:
staticvoid LoadPkgRootFile( constchar* dir, String& file );
staticvoid ScanDir( constchar* dir, void (*func)( constchar*, String& ) ); //NOTE: Normal function pointer syntax when dealing with pointer to static member functions.
};
void Packages::Load( constchar* dir ) {
ScanDir( dir, &Packages::LoadPkgRootFile); //Now OK.
}