I keep getting this linker error below
and it seems to be caused by the constructor below
/*Card.h*/
#ifndef Card_H
#define Card_H
#pragma once
#include <iostream>
using namespace std;
#include <cassert> //for assert()
#include <string>
#include <time.h>
using namespace std;
/*Card.h*/
enum color { club, diamond, heart, spade };
class Card {
public:
Card(color c = club, int v = 1);//this line
private:
color col;
int val;
};
/*Constructor*/
Card::Card(color c, int v) {// and this too
col = c;
val = v;
}
#endif
I am confused as to how neither of the player or myFile could have redefined card given they dont even include the Card.h file.