aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAdam <adammegarules1@gmail.com>2026-08-11 10:30:29 +0200
committerAdam <adammegarules1@gmail.com>2026-08-11 10:30:29 +0200
commitb806cc058bd001dbfbc28412d29eae7f4d8005df (patch)
treee8c8db23a9cf4dc59c66944c7ea8312b020b271d /src
parent54b882a31b1b6fb6ca49fd3b6877bac29207ff52 (diff)
polishing
Diffstat (limited to 'src')
-rw-r--r--src/misc.cpp9
-rw-r--r--src/misc.hpp5
-rw-r--r--src/uci.cpp2
3 files changed, 5 insertions, 11 deletions
diff --git a/src/misc.cpp b/src/misc.cpp
index 6e87351..79cf74f 100644
--- a/src/misc.cpp
+++ b/src/misc.cpp
@@ -1,14 +1,9 @@
#include "misc.hpp"
#include "moves.hpp"
#include <cstdint>
-#include <string>
+#include <string_view>
-std::string version = "1";
-std::string name = "Mono";
-
-std::string engine_version() { return name + " " + version; };
-
-std::string engine_info() { return engine_version() + "\n"; }
+std::string_view engine_info() { return "Mono 1\n"; }
uint64_t MoveGenTest(int depth, Game *g) {
uint64_t num = 0;
diff --git a/src/misc.hpp b/src/misc.hpp
index c84edef..6d269b0 100644
--- a/src/misc.hpp
+++ b/src/misc.hpp
@@ -3,10 +3,9 @@
#include "board/board.hpp"
#include <cstdint>
-#include <string>
+#include <string_view>
-std::string engine_info();
-std::string engine_version();
+std::string_view engine_info();
uint64_t MoveGenTest(int depth, Game *g);
diff --git a/src/uci.cpp b/src/uci.cpp
index 5a4726a..23fe123 100644
--- a/src/uci.cpp
+++ b/src/uci.cpp
@@ -196,7 +196,7 @@ void Uci() {
DebugBitboards(&game);
}
if (cmd == "uci") {
- cout << "id name " << engine_version() << "\n";
+ cout << "id name " << engine_info();
cout << "uciok\n";
cout.flush();
}