From 3361ad42420e578362dcafb94b639738609bf7d7 Mon Sep 17 00:00:00 2001 From: Marco Costalba Date: Sat, 26 May 2012 22:43:23 +0100 Subject: [PATCH] Rename psq_score in ReducedStateInfo So to be fully in sync with StateInfo, and move struct to position.h, just below StateInfo. No functional change. Signed-off-by: Marco Costalba --- src/position.cpp | 8 -------- src/position.h | 8 ++++++++ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/position.cpp b/src/position.cpp index fd7b1ba2..c26ab1b6 100644 --- a/src/position.cpp +++ b/src/position.cpp @@ -700,14 +700,6 @@ void Position::do_move(Move m, StateInfo& newSt, const CheckInfo& ci, bool moveI // Copy some fields of old state to our new StateInfo object except the ones // which are recalculated from scratch anyway, then switch our state pointer // to point to the new, ready to be updated, state. - struct ReducedStateInfo { - Key pawnKey, materialKey; - Value npMaterial[2]; - int castleRights, rule50, pliesFromNull; - Score psq_score; - Square epSquare; - }; - memcpy(&newSt, st, sizeof(ReducedStateInfo)); newSt.previous = st; diff --git a/src/position.h b/src/position.h index 6351f580..55dc33fe 100644 --- a/src/position.h +++ b/src/position.h @@ -60,6 +60,14 @@ struct StateInfo { StateInfo* previous; }; +struct ReducedStateInfo { + Key pawnKey, materialKey; + Value npMaterial[2]; + int castleRights, rule50, pliesFromNull; + Score psqScore; + Square epSquare; +}; + /// The position data structure. A position consists of the following data: /// -- 2.39.2