0

Hi all,

I have a file called Client.cpp, which has main() contained in it.

my problem is at the start of the file:

#include <iostream>
using namespace std;
#include "Student.h"

enum User { NO_USER = 0, STUDENT = 1, ADMIN = 2};

I get errors on the line with the enum, when I get rid of
#include "Student.h" the program works.

I know there is nothing wrong with the student class.

could it have something to do with the pre-processor?

any help is appreciated.
thanks.

1
Contributor
1
Reply
2
Views
7 Years
Discussion Span
Last Post by Danny_501
0

I figured it out lol.
Its because I had STUDENT as one of the enums, and that was clashing with the student class in the compiler.

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.