X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fmovegen.h;h=5eee2f1acf8647cdbefce1ce5f60cc0153c29678;hb=243f7b264a81c2981cec2818b47d609d9d3ca119;hp=daee502d8ccfae5badf28894f28f1fc38317c1c9;hpb=28b6a457c24d9202ba43a6d6703221250f0f8749;p=stockfish diff --git a/src/movegen.h b/src/movegen.h index daee502d..5eee2f1a 100644 --- a/src/movegen.h +++ b/src/movegen.h @@ -1,8 +1,6 @@ /* Stockfish, a UCI chess playing engine derived from Glaurung 2.1 - Copyright (C) 2004-2008 Tord Romstad (Glaurung author) - Copyright (C) 2008-2015 Marco Costalba, Joona Kiiski, Tord Romstad - Copyright (C) 2015-2017 Marco Costalba, Joona Kiiski, Gary Linscott, Tord Romstad + Copyright (C) 2004-2023 The Stockfish developers (see AUTHORS file) Stockfish is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -21,10 +19,13 @@ #ifndef MOVEGEN_H_INCLUDED #define MOVEGEN_H_INCLUDED -#include +#include // IWYU pragma: keep +#include #include "types.h" +namespace Stockfish { + class Position; enum GenType { @@ -55,8 +56,9 @@ inline bool operator<(const ExtMove& f, const ExtMove& s) { template ExtMove* generate(const Position& pos, ExtMove* moveList); -/// The MoveList struct is a simple wrapper around generate(). It sometimes comes -/// in handy to use this class instead of the low level generate() function. +/// The MoveList struct wraps the generate() function and returns a convenient +/// list of moves. Using MoveList is sometimes preferable to directly calling +/// the lower level generate() function. template struct MoveList { @@ -72,4 +74,6 @@ private: ExtMove moveList[MAX_MOVES], *last; }; +} // namespace Stockfish + #endif // #ifndef MOVEGEN_H_INCLUDED