From: ceriel Date: Wed, 22 Aug 1990 15:33:43 +0000 (+0000) Subject: avoid double LINs and corrected bug in symbol table entries for records X-Git-Tag: release-5-5~1590 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=2a26b4d335745b36f0c2d8d9f1aee6ee3130dced;p=ack.git avoid double LINs and corrected bug in symbol table entries for records --- diff --git a/lang/m2/comp/stab.c b/lang/m2/comp/stab.c index 657a8f6d9..deca994a1 100644 --- a/lang/m2/comp/stab.c +++ b/lang/m2/comp/stab.c @@ -207,8 +207,8 @@ stb_type(tp, assign_num) stb_type(sdef->df_type, 0); adds_db_str(sprint(buf, ",%ld,%ld;", - sdef->df_type->tp_size*8, - sdef->fld_off*8)); + sdef->fld_off*8, + sdef->df_type->tp_size*8)); sdef = sdef->df_nextinscope; } } diff --git a/lang/m2/comp/walk.c b/lang/m2/comp/walk.c index 52fda8a61..8eb4c975e 100644 --- a/lang/m2/comp/walk.c +++ b/lang/m2/comp/walk.c @@ -556,7 +556,11 @@ WalkStat(nd, exit_label, end_reached) if (! end_reached & REACH_FLAG) { node_warning(nd, W_ORDINARY, "statement not reached"); } - DoLineno(nd); + if (nd->nd_symb != WHILE || + nd->nd_lineno != left->nd_lineno) { + /* Avoid double linenumber generation in while statements */ + DoLineno(nd); + } options['R'] = (nd->nd_flags & ROPTION); options['A'] = (nd->nd_flags & AOPTION); switch(nd->nd_symb) {