From: <da...@us...> - 2003-06-27 01:59:18
|
Update of /cvsroot/cerber/cerb-ng/ucerb In directory sc8-pr-cvs1:/tmp/cvs-serv31012 Modified Files: libcerb.c Log Message: Fixed too high register detection. This was handled property: reg[16] = 5; someval = 5; But this not: someval = 5; reg[16] = 5; Index: libcerb.c =================================================================== RCS file: /cvsroot/cerber/cerb-ng/ucerb/libcerb.c,v retrieving revision 1.63 retrieving revision 1.64 diff -u -d -r1.63 -r1.64 --- libcerb.c 26 Jun 2003 22:34:42 -0000 1.63 +++ libcerb.c 27 Jun 2003 01:59:15 -0000 1.64 @@ -592,13 +592,14 @@ value.v_type = CB_DEF_T; tmpval = tmpres1.res_val.v_val; if (setvar_flag == ASSIGNING) { - if (assignment_table[tmpval] == UNASSIGNED) { - if (tmpval >= LOCAL_VAR_MIN) { - croak("ERROR: assignment to high register detected " - "(%i), use registers 0 .. %i", tmpval, LOCAL_VAR_MIN-1); - } - assignment_table[tmpval] = expr_no; + if (tmpval >= LOCAL_VAR_MIN) { + croak("ERROR: assignment to high " + "register detected (%i), use " + "registers 0 .. %i", tmpval, + LOCAL_VAR_MIN - 1); } + if (assignment_table[tmpval] == UNASSIGNED) + assignment_table[tmpval] = expr_no; setvar_flag = ASSIGNED; } else if (assignment_table[tmpval] == UNASSIGNED || assignment_table[tmpval] >= expr_no ) { |