mirror of
https://github.com/opelly27/Stockfish.git
synced 2026-05-20 02:47:45 +00:00
Explicitly pass RootMoves to TB probes
Currently Search::RootMoves is accessed and even modified by TB probing functions in a hidden and sneaky way. This is bad practice and makes the code tricky. Instead explicily pass the vector as function argument so to clarify that the vector is modified inside the functions. No functional change.
This commit is contained in:
committed by
Joona Kiiski
parent
eeb6d923fa
commit
ba1464751d
@@ -1,15 +1,17 @@
|
||||
#ifndef TBPROBE_H
|
||||
#define TBPROBE_H
|
||||
|
||||
#include "../search.h"
|
||||
|
||||
namespace Tablebases {
|
||||
|
||||
extern int TBLargest;
|
||||
extern int MaxCardinality;
|
||||
|
||||
void init(const std::string& path);
|
||||
int probe_wdl(Position& pos, int *success);
|
||||
int probe_dtz(Position& pos, int *success);
|
||||
bool root_probe(Position& pos, Value& TBScore);
|
||||
bool root_probe_wdl(Position& pos, Value& TBScore);
|
||||
bool root_probe(Position& pos, Search::RootMoveVector& rootMoves, Value& score);
|
||||
bool root_probe_wdl(Position& pos, Search::RootMoveVector& rootMoves, Value& score);
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user