diff --git a/game_state.h b/game_state.h index be7541e..7d7b424 100644 --- a/game_state.h +++ b/game_state.h @@ -73,11 +73,11 @@ constexpr Card y4 = {1, 4}; * - Number of clues */ -template +template using Stacks = std::array; -template -std::ostream &operator<<(std::ostream &os, const Stacks &stacks); +template +std::ostream& operator<<(std::ostream &os, const Stacks &stacks); struct CardMultiplicity { Card card; diff --git a/game_state.hpp b/game_state.hpp index a0a3cfd..298ab2c 100644 --- a/game_state.hpp +++ b/game_state.hpp @@ -27,8 +27,8 @@ namespace Hanabi { return os; } - template - std::ostream &operator<<(std::ostream &os, const Stacks &stacks) { + template + std::ostream& operator<<(std::ostream &os, const Stacks &stacks) { for (size_t i = 0; i < stacks.size() - 1; i++) { os << starting_card_rank - stacks[i] << ", "; } @@ -189,7 +189,7 @@ namespace Hanabi { template void HanabiState::print(std::ostream &os) const { -// os << "Stacks: " << _stacks << " (score " << +_score << ")"; + os << "Stacks: " << _stacks << " (score " << +_score << ")"; os << ", clues: " << +_num_clues << ", turn: " << +_turn << std::endl; os << "Draw pile: "; for (const auto &[card, mul]: _draw_pile) {