From: ceriel Date: Wed, 19 Aug 1987 15:23:41 +0000 (+0000) Subject: some minor corrections X-Git-Tag: release-5-5~3881 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=7dc04a3207efd60f724eb8f7ed43b64317ac98c9;p=ack.git some minor corrections --- diff --git a/lang/cem/cemcom/arith.c b/lang/cem/cemcom/arith.c index e96b383cf..e07a2dc37 100644 --- a/lang/cem/cemcom/arith.c +++ b/lang/cem/cemcom/arith.c @@ -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; } } diff --git a/lang/cem/cemcom/cstoper.c b/lang/cem/cemcom/cstoper.c index b561225f3..0208e1939 100644 --- a/lang/cem/cemcom/cstoper.c +++ b/lang/cem/cemcom/cstoper.c @@ -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]; } diff --git a/lang/cem/cemcom/declar.g b/lang/cem/cemcom/declar.g index 15bdb1d64..0453d846e 100644 --- a/lang/cem/cemcom/declar.g +++ b/lang/cem/cemcom/declar.g @@ -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; } | diff --git a/lang/cem/cemcom/ival.g b/lang/cem/cemcom/ival.g index 77d3fd13e..35557de91 100644 --- a/lang/cem/cemcom/ival.g +++ b/lang/cem/cemcom/ival.g @@ -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; }