| 502 | } |
| 503 | |
| 504 | void fxBigIntParseX(txBigInt* bigint, txString p, txSize length) |
| 505 | { |
| 506 | txU4 data[1] = { 0 }; |
| 507 | txBigInt digit = { .sign=0, .size=1, .data=data }; |
| 508 | bigint->sign = 0; |
| 509 | bigint->size = 1; |
| 510 | bigint->data[0] = 0; |
| 511 | while (length) { |
| 512 | char c = *p++; |
| 513 | if (('0' <= c) && (c <= '9')) |
| 514 | data[0] = c - '0'; |
| 515 | else if (('a' <= c) && (c <= 'f')) |
| 516 | data[0] = 10 + c - 'a'; |
| 517 | else |
| 518 | data[0] = 10 + c - 'A'; |
| 519 | fxBigInt_uadd(NULL, bigint, fxBigInt_ulsl1(NULL, bigint, bigint, 4), &digit); |
| 520 | length--; |
| 521 | } |
| 522 | } |
| 523 | |
| 524 | #ifndef mxCompile |
| 525 |
no test coverage detected