diff --git a/elab_expr.cc b/elab_expr.cc index c496b04de..d9a693711 100644 --- a/elab_expr.cc +++ b/elab_expr.cc @@ -287,6 +287,20 @@ NetExpr* PEBinary::elaborate_expr_base_lshift_(Design*des, { NetExpr*tmp; + long use_wid = lp->expr_width(); + if (expr_wid > 0) + use_wid = expr_wid; + + if (use_wid == 0) { + if (debug_elaborate) + cerr << get_fileline() << ": debug: " + << "Oops, left expression width is not known, " + << "so expression width is not known. Punt." << endl; + tmp = new NetEBShift(op_, lp, rp); + tmp->set_line(*this); + return tmp; + } + if (NetEConst*lpc = dynamic_cast (lp)) { if (NetEConst*rpc = dynamic_cast (rp)) { // Handle the super-special case that both diff --git a/pform_dump.cc b/pform_dump.cc index f506bd655..3dae41844 100644 --- a/pform_dump.cc +++ b/pform_dump.cc @@ -274,6 +274,9 @@ void PEBinary::dump(ostream&out) const case 'l': out << "<<"; break; + case 'L': + out << "<="; + break; case 'n': out << "!="; break;