MCPcopy Create free account
hub / github.com/apache/arrow / CheckDecimalToReal

Function CheckDecimalToReal

cpp/src/arrow/util/decimal_test.cc:1112–1118  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1110
1111template <typename Decimal, typename Real>
1112void CheckDecimalToReal(const std::string& decimal_value, int32_t scale, Real expected) {
1113 Decimal dec(decimal_value);
1114 Real actual = dec.template ToReal<Real>(scale);
1115 ASSERT_EQ(actual, expected) << "Decimal value: " << decimal_value
1116 << ", scale: " << scale << ", expected: " << expected
1117 << ", actual: " << actual;
1118}
1119
1120template <typename Decimal, typename Real>
1121void CheckDecimalToRealWithinOneULP(const std::string& decimal_value, int32_t scale,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected