Private data in this class is Card TheCards[3] and int numCards.
The below function I wrote as a member function.
In the .h
1 2
//post-increment - adds to numCards by one
Hand operator++( int );
In the .cpp
1 2 3 4 5 6 7
/ Hand Hand::operator++( int ) {
Hand temp = *this;
setCard(getNumCards(), Card) //this is line 61 in my code
(*this)++;
return temp; // value return; not a reference return
}
The error it is giving me is;
In member function `Hand Hand::operator++(int)':
61: error: expected primary-expression before ')' token