class HRManagement
{
public:
HRManagement(void);
~HRManagement(void);
void displayHr() const;
private:
SnowPark *s;
};
The following are the errors i'm getting:
hrmanagement.h(19): error C2143: syntax error : missing ';' before '*'
hrmanagement.h(19): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
hrmanagement.h(19): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
Hi guys, I'm new at cpp. Sorry if I made a very silly mistake, but I really dont see any. I checked for a missing ; but as you can see I haven't missed a ; anywhere. I dont understand why the compiler (visual 2010 express) is throwing these errors.
You have a circular reference and you are not using header guards (or #pragma once). You need to forward declare one of the classes and avoid the circular reference between the two headers.