| 641 | } |
| 642 | |
| 643 | void AddHexInteger(const char* pos, const char* end) |
| 644 | { |
| 645 | pos += 2; |
| 646 | // skip leading zeros |
| 647 | while(*pos == '0') |
| 648 | pos++; |
| 649 | if(int(end - pos) > 16) |
| 650 | ThrowError(pos, "ERROR: overflow in hexadecimal constant"); |
| 651 | long long num = parseLong(pos, end, 16); |
| 652 | // If number overflows integer number, create long number |
| 653 | if(int(num) == num) |
| 654 | CodeInfo::nodeList.push_back(new NodeNumber(int(num), typeInt)); |
| 655 | else |
| 656 | CodeInfo::nodeList.push_back(new NodeNumber(num, typeLong)); |
| 657 | } |
| 658 | |
| 659 | void AddOctInteger(const char* pos, const char* end) |
| 660 | { |
no test coverage detected