| 134 | const CDecimal128 c1(1); |
| 135 | |
| 136 | unsigned digits(const unsigned pMax, unsigned char* const coeff, int& exp) |
| 137 | { |
| 138 | for (unsigned i = 0; i < pMax; ++i) |
| 139 | { |
| 140 | if (coeff[i]) |
| 141 | { |
| 142 | if (i) |
| 143 | { |
| 144 | memmove(coeff, &coeff[i], pMax - i); |
| 145 | memset(&coeff[pMax - i], 0, i); |
| 146 | exp -= i; |
| 147 | } |
| 148 | |
| 149 | i = pMax - i; |
| 150 | |
| 151 | while (!coeff[i - 1]) |
| 152 | { |
| 153 | fb_assert(i > 0); |
| 154 | --i; |
| 155 | } |
| 156 | |
| 157 | return i; |
| 158 | } |
| 159 | } |
| 160 | |
| 161 | return 0; |
| 162 | } |
| 163 | |
| 164 | // offsets down from MAX_SLONG |
| 165 | const ULONG OFF_inf = 3; |
no outgoing calls
no test coverage detected