Skip to content

Commit

Permalink
空白やインデントを微調整
Browse files Browse the repository at this point in the history
  • Loading branch information
KazApps committed Aug 6, 2024
1 parent b11fb96 commit fa48833
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion source/bitboard.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ void Bitboards::init()
// dirの方角に壁にぶつかる(盤外)まで延長していく。このとき、sq1から見てsq2のDirectionsは (1 << dir)である。
auto delta = Effect8::DirectToDeltaWW(dir);
for (auto sq2 = to_sqww(sq1) + delta; is_ok(sq2); sq2 += delta)
Effect8::direc_table[sq1][sqww_to_sq(sq2)] = Effect8::to_directions(dir);
Effect8::direc_table[sq1][sqww_to_sq(sq2)] = Effect8::to_directions(dir);
}


Expand Down
10 changes: 5 additions & 5 deletions source/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -467,10 +467,10 @@ enum Value: int32_t
};

// ply手で詰ませるときのスコア
constexpr Value mate_in(int ply) { return (Value)(VALUE_MATE - ply);}
constexpr Value mate_in(int ply) { return (Value)(VALUE_MATE - ply); }

// ply手で詰まされるときのスコア
constexpr Value mated_in(int ply) { return (Value)(-VALUE_MATE + ply);}
constexpr Value mated_in(int ply) { return (Value)(-VALUE_MATE + ply); }


// --------------------
Expand Down Expand Up @@ -660,11 +660,11 @@ std::string to_usi_string(Move16 m);
// それらを明確に区別したい時に用いる。
struct Move16
{
Move16():move(0){}
Move16(u16 m): move(m) {}
Move16() : move(0) {}
Move16(u16 m) : move(m) {}

// Moveからの暗黙変換はできないとMOVE_NONEの代入などで困る。
Move16(Move m) :move((u16)m){}
Move16(Move m) : move((u16)m) {}

// uint16_tのまま取り出す。
// Moveに変換が必要なときは、そのあとMove()にcastすることはできる。(上位16bitは0のまま)
Expand Down

0 comments on commit fa48833

Please sign in to comment.