MCPcopy Create free account
hub / github.com/bitcoinxt/bitcoinxt / ArrayToString

Function ArrayToString

src/test/arith_uint256_tests.cpp:56–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

54
55const arith_uint256 HalfL = (OneL << 255);
56std::string ArrayToString(const unsigned char A[], unsigned int width)
57{
58 std::stringstream Stream;
59 Stream << std::hex;
60 for (unsigned int i = 0; i < width; ++i)
61 {
62 Stream<<std::setw(2)<<std::setfill('0')<<(unsigned int)A[width-i-1];
63 }
64 return Stream.str();
65}
66
67BOOST_AUTO_TEST_CASE( basics ) // constructors, equality, inequality
68{

Callers 1

BOOST_AUTO_TEST_CASEFunction · 0.70

Calls 1

strMethod · 0.80

Tested by

no test coverage detected