From 5ab55827b84f1aef79478ec9b030330973036bda Mon Sep 17 00:00:00 2001 From: Marco Costalba Date: Sun, 26 Oct 2014 08:14:36 +0100 Subject: [PATCH 1/1] Fix an obscure gcc warning MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit warning: narrowing conversion from ‘int’ to ‘char’ inside { } is ill-formed in C++11 [-Wnarrowing] When pedantic meets esoteric! No functional change. --- src/uci.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/uci.cpp b/src/uci.cpp index 819e02bc..cfd11217 100644 --- a/src/uci.cpp +++ b/src/uci.cpp @@ -241,7 +241,8 @@ string UCI::format_value(Value v, Value alpha, Value beta) { std::string UCI::format_square(Square s) { - char ch[] = { 'a' + file_of(s), '1' + rank_of(s), 0 }; // Zero-terminating + char ch[] = { char('a' + file_of(s)), + char('1' + rank_of(s)), 0 }; // Zero-terminating return ch; } -- 2.39.2