Lines Matching refs:radix
151 inline bool isDigit(int x, int radix) {
152 return (x >= '0' && x <= '9' && x < '0' + radix) ||
153 (radix > 10 && x >= 'a' && x < 'a' + radix - 10) ||
154 (radix > 10 && x >= 'A' && x < 'A' + radix - 10);
181 // Parsing integers with radix 2, 4, 8, 16, 32. Assumes current != end.
195 const int radix = (1 << radix_log_2);
197 int lim_0 = '0' + (radix < 10 ? radix : 10);
198 int lim_a = 'a' + (radix - 10);
199 int lim_A = 'A' + (radix - 10);
217 number = number * radix + digit;
236 if (current == end || !isDigit(*current, radix)) break;
290 // ES6 18.2.5 parseInt(string, radix) (with NumberParseIntHelper subclass);
296 StringToIntHelper(IsolateT* isolate, Handle<String> subject, int radix)
297 : isolate_(isolate), subject_(subject), radix_(radix) {
308 // buffer of one-byte digits, along with an optional radix prefix.
348 int radix() { return radix_; }
471 NumberParseIntHelper(Isolate* isolate, Handle<String> string, int radix)
472 : StringToIntHelper(isolate, string, radix) {}
479 if (radix() == 10) return HandleBaseTenCase(current, end);
480 if (base::bits::IsPowerOfTwo(radix())) {
518 switch (radix()) {
578 int lim_0 = '0' + (radix() < 10 ? radix() : 10);
579 int lim_a = 'a' + (radix() - 10);
580 int lim_A = 'A' + (radix() - 10);
610 uint32_t m = multiplier * static_cast<uint32_t>(radix());
612 part = part * radix() + d;
914 double StringToInt(Isolate* isolate, Handle<String> string, int radix) {
915 NumberParseIntHelper helper(isolate, string, radix);
933 // one-byte ASCII digits, along with an optional radix prefix.
948 this->radix() != 10) {
997 current = accumulator_.Parse(current, end, this->radix());
1339 char* DoubleToRadixCString(double value, int radix) {
1340 DCHECK(radix >= 2 && radix <= 36);
1371 fraction *= radix;
1372 delta *= radix;
1393 if (digit + 1 < radix) {
1405 while (base::Double(integer / radix).Exponent() > 0) {
1406 integer /= radix;
1410 double remainder = Modulo(integer, radix);
1412 integer = (integer - remainder) / radix;