some minor corrections

This commit is contained in:
ceriel 1987-08-19 15:23:41 +00:00
parent cc524c3d9a
commit 7dc04a3207
4 changed files with 8 additions and 7 deletions

View file

@ -245,10 +245,10 @@ int2int(expp, tp)
*/
extern long full_mask[];
long remainder = exp->VL_VALUE &
~full_mask[tp->tp_size];
~full_mask[(int)(tp->tp_size)];
if (remainder == 0 ||
remainder == ~full_mask[tp->tp_size]) {
remainder == ~full_mask[(int)(tp->tp_size)]) {
exp->VL_VALUE &= ~remainder;
}
}

View file

@ -232,6 +232,6 @@ init_cst()
mach_long_sign = 1L << (mach_long_size * 8 - 1);
if (long_size < mach_long_size)
fatal("sizeof (long) insufficient on this machine");
max_int = full_mask[int_size] & ~(1L << (int_size * 8 - 1));
max_unsigned = full_mask[int_size];
max_int = full_mask[(int)int_size] & ~(1L << (int_size * 8 - 1));
max_unsigned = full_mask[(int)int_size];
}

View file

@ -125,6 +125,8 @@ single_type_specifier(register struct decspecs *ds;):
|
IDENTIFIER
{error("%s is not a type identifier", dot.tk_idf->id_text);
dot.tk_idf->id_def->df_type = error_type;
dot.tk_idf->id_def->df_sc = TYPEDEF;
ds->ds_type = error_type;
}
|

View file

@ -554,7 +554,6 @@ ch_array(tpp, ex)
}
else {
arith dim = tp->tp_size / tp->tp_up->tp_size;
extern char options[];
if (length > dim) {
expr_warning(ex, "too many initialisers");
@ -578,10 +577,10 @@ str_cst(str, len)
register char *str;
register int len;
{
arith chunksize = ((127 + word_size) / word_size) * word_size;
int chunksize = ((127 + (int) word_size) / (int) word_size) * (int) word_size;
while (len > chunksize) {
C_con_scon(str, chunksize);
C_con_scon(str, (arith) chunksize);
len -= chunksize;
str += chunksize;
}