X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fposition.h;h=0bb7b0b99ada88507cecd6f6f0518031c4e5c7a5;hp=3c7cf0f2a9cad7d33ebb33e664090bbdf4f8f517;hb=60c121f3b1ee7d5ced3435cc1718e4e6e6fd8383;hpb=aea2fde6117be2fbda1caa62c842dea766780be5 diff --git a/src/position.h b/src/position.h index 3c7cf0f2..0bb7b0b9 100644 --- a/src/position.h +++ b/src/position.h @@ -1,7 +1,7 @@ /* Stockfish, a UCI chess playing engine derived from Glaurung 2.1 Copyright (C) 2004-2008 Tord Romstad (Glaurung author) - Copyright (C) 2008-2014 Marco Costalba, Joona Kiiski, Tord Romstad + Copyright (C) 2008-2015 Marco Costalba, Joona Kiiski, Tord Romstad Stockfish is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -22,6 +22,7 @@ #include #include // For offsetof() +#include #include "bitboard.h" #include "types.h" @@ -81,12 +82,11 @@ class Position { friend std::ostream& operator<<(std::ostream&, const Position&); - Position(const Position&); // Disable the default copy constructor - public: static void init(); - Position() {} // To define the global object RootPos + Position() = default; // To define the global object RootPos + Position(const Position&) = delete; Position(const Position& pos, Thread* th) { *this = pos; thisThread = th; } Position(const std::string& f, bool c960, Thread* th) { set(f, c960, th); } Position& operator=(const Position&); // To assign RootPos from UCI @@ -174,7 +174,7 @@ public: Value non_pawn_material(Color c) const; // Position consistency check, for debugging - bool pos_is_ok(int* step = NULL) const; + bool pos_is_ok(int* step = nullptr) const; void flip(); private: