class chess_board
{
public:
chess_board(const std::pair<int, int>& white, const std::pair<int, int>& black)
: white_{white},
black_{black}
{
if (white == black) {
throw std::domain_error("Both queens cannot occupy the same position.");
}
}
chess_board()
{}
std::pair<int, int> white() const
{
return white_;
}
std::pair<int, int> black() const
{
return black_;
}
private:
const std::pair<int, int> white_ = std::make_pair(0, 3);
const std::pair<int, int> black_ = std::make_pair(7, 3);
};
Perform Move Implementation to Source File on constructor and it only copies up to the first }, creating invalid syntax.