apparently the default value of a paramter goes in
the declaration and not the defintion, i didn't know that
This commit is contained in:
parent
8da349579d
commit
fa57dcfc30
@ -18,9 +18,8 @@ keep_only_blocking(const std::vector<Move> candidates, const Board& board) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
std::vector<Move> legal_moves(
|
||||
int8_t p, const Board& b, const Coords xy, bool looking_for_check = false
|
||||
) {
|
||||
std::vector<Move>
|
||||
legal_moves(int8_t p, const Board& b, const Coords xy, bool looking_for_check) {
|
||||
std::vector<Move> ret;
|
||||
switch (p) {
|
||||
case Piece::Pawn:
|
||||
|
@ -24,7 +24,7 @@ enum Colour : int8_t {
|
||||
class Board;
|
||||
struct Coords;
|
||||
|
||||
std::vector<Move> legal_moves(int8_t, const Board&, const Coords, bool);
|
||||
std::vector<Move> legal_moves(int8_t, const Board&, const Coords, bool = false);
|
||||
std::vector<Move> keep_only_blocking(const std::vector<Move>, const Board&);
|
||||
std::optional<Move> move_for_position(const Board&, const Coords, const Coords);
|
||||
std::vector<Move> look_direction(const Board&, const Coords, int, int);
|
||||
|
Loading…
x
Reference in New Issue
Block a user