From c6c44c5c9d50438f62c85959e67f426ee2f2d632 Mon Sep 17 00:00:00 2001 From: nella Date: Tue, 12 May 2026 15:58:46 +0200 Subject: [PATCH] Undo rewrite_parameter changes. --- frontends/ast/ast.cc | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/frontends/ast/ast.cc b/frontends/ast/ast.cc index 50271bc91..c190bc7d4 100644 --- a/frontends/ast/ast.cc +++ b/frontends/ast/ast.cc @@ -1875,10 +1875,8 @@ std::string AstModule::derive_common(RTLIL::Design *design, const dictchildren[0]->realvalue = std::stod(it->second.decode_string()); } else if ((it->second.flags & RTLIL::CONST_FLAG_STRING) != 0) child->children[0] = AstNode::mkconst_str(loc, it->second.decode_string()); - else { - bool is_signed = child->is_signed || ((it->second.flags & RTLIL::CONST_FLAG_SIGNED) != 0); - child->children[0] = AstNode::mkconst_bits(loc, it->second.to_bits(), is_signed, (it->second.flags & RTLIL::CONST_FLAG_UNSIZED) != 0); - } + else + child->children[0] = AstNode::mkconst_bits(loc, it->second.to_bits(), (it->second.flags & RTLIL::CONST_FLAG_SIGNED) != 0, (it->second.flags & RTLIL::CONST_FLAG_UNSIZED) != 0); rewritten.insert(it->first); }