Fix: sometimes generated illegal register messages for parameters
This commit is contained in:
parent
a28c551213
commit
9381b34dfa
|
@ -536,14 +536,14 @@ declare_formals(idf, fp)
|
|||
parameter starts on a new word boundary.
|
||||
*/
|
||||
f_offset = align(f_offset + def->df_type->tp_size, (int) word_size);
|
||||
RegisterAccount(def->df_address, def->df_type->tp_size,
|
||||
regtype(def->df_type),
|
||||
def->df_sc);
|
||||
/* cvt int to char or short and double to float, if necessary
|
||||
*/
|
||||
formal_cvt(hasproto, def);
|
||||
|
||||
def->df_level = L_FORMAL2; /* CJ */
|
||||
RegisterAccount(def->df_address, def->df_type->tp_size,
|
||||
regtype(def->df_type),
|
||||
def->df_sc);
|
||||
if (nparams++ >= STDC_NPARAMS)
|
||||
strict("number of formal parameters exceeds ANSI limit");
|
||||
#ifdef DBSYMTAB
|
||||
|
|
|
@ -205,6 +205,7 @@ LoadLocal(off, sz)
|
|||
if (p) p->t_count++;
|
||||
#endif
|
||||
#endif
|
||||
if (p && p->t_size != sz) p->t_regtype = -1;
|
||||
if (sz == word_size) C_lol(off);
|
||||
else if (sz == dword_size) C_ldl(off);
|
||||
else {
|
||||
|
@ -224,6 +225,7 @@ StoreLocal(off, sz)
|
|||
if (p) p->t_count++;
|
||||
#endif
|
||||
#endif
|
||||
if (p && p->t_size != sz) p->t_regtype = -1;
|
||||
if (sz == word_size) C_stl(off);
|
||||
else if (sz == dword_size) C_sdl(off);
|
||||
else {
|
||||
|
|
Loading…
Reference in a new issue