getexpress(), cleanup
This commit is contained in:
parent
4402686c69
commit
47db566181
|
|
@ -1358,14 +1358,14 @@ getexpress(const char * const s, SPICE_DSTRINGPTR tstr_p, const char **pi)
|
|||
ia_ptr++;
|
||||
p = ia_ptr - 1;
|
||||
|
||||
while (((p + 1) < ls_ptr) && ((p + 1)[-1] != '"'))
|
||||
while (((p + 1) < ls_ptr) && (*p != '"'))
|
||||
p++;
|
||||
|
||||
tpe = NUPA_STRING;
|
||||
|
||||
do
|
||||
p++;
|
||||
while (((p + 1) <= ls_ptr) && ((p + 1)[-1] <= ' '));
|
||||
while (((p + 1) <= ls_ptr) && (*p <= ' '));
|
||||
|
||||
} else {
|
||||
|
||||
|
|
@ -1381,7 +1381,7 @@ getexpress(const char * const s, SPICE_DSTRINGPTR tstr_p, const char **pi)
|
|||
if ((p + 1) > ls_ptr)
|
||||
c = ';';
|
||||
else
|
||||
c = (p + 1)[-1];
|
||||
c = *p;
|
||||
|
||||
if (c == '(') {
|
||||
/* sub-formula */
|
||||
|
|
@ -1393,7 +1393,7 @@ getexpress(const char * const s, SPICE_DSTRINGPTR tstr_p, const char **pi)
|
|||
if ((p + 1) > ls_ptr)
|
||||
d = '\0';
|
||||
else
|
||||
d = (p + 1)[-1];
|
||||
d = *p;
|
||||
|
||||
if (d == '(')
|
||||
level++;
|
||||
|
|
@ -1410,7 +1410,7 @@ getexpress(const char * const s, SPICE_DSTRINGPTR tstr_p, const char **pi)
|
|||
|
||||
pscopy(tstr_p, ia_ptr - 1, 0, (int) (p + 1 - ia_ptr));
|
||||
|
||||
if ((p + 1)[-1] == '}')
|
||||
if (*p == '}')
|
||||
p++;
|
||||
|
||||
if (tpe == NUPA_STRING)
|
||||
|
|
|
|||
Loading…
Reference in New Issue