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

Method LargePowerOfTen

cpp/src/arrow/util/decimal.cc:84–91  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

82 // Return 10**exp, with a fast lookup if possible
83 template <typename Real>
84 static Real LargePowerOfTen(int32_t exp) {
85 constexpr int N = kPrecomputedPowersOfTen;
86 if (ARROW_PREDICT_TRUE(exp >= -N && exp <= N)) {
87 return RealTraits<Real>::powers_of_ten()[exp + N];
88 } else {
89 return std::pow(static_cast<Real>(10), static_cast<Real>(exp));
90 }
91 }
92};
93
94template <typename DecimalType, typename Derived>

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected