PIObject Property const char *

This commit is contained in:
Andrey
2022-04-29 18:17:03 +03:00
parent 97dd19f0c7
commit 8c8553a6af
7 changed files with 44 additions and 46 deletions

View File

@@ -63,7 +63,7 @@ const char PIString::toBaseN[] = { '0', '1', '2', '3', '4', '5', '6', '7', '8',
'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J',
'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T',
'U', 'V', 'W', 'X', 'Y', 'Z', '[', '\\', ']', '^'};
const int PIString::fromBaseN[] = { -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
const char PIString::fromBaseN[] = { -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, -1, -1, -1, -1, -1, -1,
@@ -168,7 +168,7 @@ llong PIString::toNumberBase(const PIString & value, int base, bool * ok) {
PIVector<int> digits;
llong ret = 0, m = 1;
bool neg = false;
int cs;
char cs;
for (int i = 0; i < v.size_s(); ++i) {
if (v[i] == PIChar('-')) {
neg = !neg;