From 267d924d2ed89d062a16e5514d55bb1b85dbdec8 Mon Sep 17 00:00:00 2001 From: frstrtr Date: Thu, 16 Jul 2026 05:29:37 +0000 Subject: [PATCH] btc(msvc): disambiguate second HexStr C2668 at coin/node.hpp:131 MSVC C2668: HexStr(std::vector) is viable for all three Span overloads (uint8_t/char/std::byte). This is the SAME ambiguity #711 fixed in share_tracker.hpp, at a second call site the block-submit fallback path uses. Feed the exact Span the intended overload wants, matching the #711 pattern byte-for-byte. Swept all HexStr call sites reachable from the MSVC btc build: the only other bare-container sites (config_coin prefix, config_pool m_prefix) are std::vector, which match a single overload and are already unambiguous. No third site remains. --- src/impl/btc/coin/node.hpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/impl/btc/coin/node.hpp b/src/impl/btc/coin/node.hpp index e7b78abdd..940795d1b 100644 --- a/src/impl/btc/coin/node.hpp +++ b/src/impl/btc/coin/node.hpp @@ -128,7 +128,11 @@ class Node : public btc::interfaces::Node { if (!m_rpc) return false; - return m_rpc->submit_block_hex(HexStr(block_bytes), /*ignore_failure=*/true); + // MSVC: disambiguate HexStr overload (std::vector is viable + // for all span overloads). Feed the exact byte span the uint8_t overload wants. + return m_rpc->submit_block_hex( + HexStr(Span(block_bytes.data(), block_bytes.size())), + /*ignore_failure=*/true); } /// Broadcast a WON block with FALLBACK semantics: P2P relay is primary,