MCPcopy Create free account
hub / github.com/bytedance/bolt / valueToString

Function valueToString

bolt/type/FloatingDecimal.cpp:32–41  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

30namespace {
31
32std::string valueToString(int128_t value, int32_t& scale, int32_t& nDigits) {
33 while (value > 0 && value % 10 == 0) {
34 scale--;
35 value /= 10;
36 }
37 std::string valueStr;
38 valueStr = std::to_string(value);
39 nDigits = valueStr.size();
40 return valueStr;
41}
42
43int countBits(int64_t v) {
44 if (v == 0L) {

Callers 4

toStringMethod · 0.85
toStringMethod · 0.85
toDoubleFromValueMethod · 0.85
toFloatFromValueMethod · 0.85

Calls 2

to_stringFunction · 0.70
sizeMethod · 0.45

Tested by

no test coverage detected