Consistent use of anonymous namespace

Also change `bindThisThread` to match the current code style for function naming.

closes https://github.com/official-stockfish/Stockfish/pull/5118

No functional change
This commit is contained in:
Disservin
2024-03-17 10:33:03 +01:00
parent ed60460004
commit 134e6d7bb4
6 changed files with 45 additions and 36 deletions

View File

@@ -51,10 +51,10 @@ void hint_common_parent_position(const Position& pos, const Networks& networks)
networks.big.hint_common_access(pos, false);
}
namespace {
// Converts a Value into (centi)pawns and writes it in a buffer.
// The buffer must have capacity for at least 5 chars.
static void format_cp_compact(Value v, char* buffer) {
void format_cp_compact(Value v, char* buffer) {
buffer[0] = (v < 0 ? '-' : v > 0 ? '+' : ' ');
@@ -90,7 +90,7 @@ static void format_cp_compact(Value v, char* buffer) {
// Converts a Value into pawns, always keeping two decimals
static void format_cp_aligned_dot(Value v, std::stringstream& stream) {
void format_cp_aligned_dot(Value v, std::stringstream& stream) {
const double pawns = std::abs(0.01 * UCI::to_cp(v));
@@ -99,6 +99,7 @@ static void format_cp_aligned_dot(Value v, std::stringstream& stream) {
: ' ')
<< std::setiosflags(std::ios::fixed) << std::setw(6) << std::setprecision(2) << pawns;
}
}
// Returns a string with the value of each piece on a board,