From 0598bc8708d942a0e533ddeba6a4f7b5effe7f39 Mon Sep 17 00:00:00 2001 From: Clifford Wolf Date: Mon, 28 Jul 2014 15:19:34 +0200 Subject: Fixed width detection for part selects --- frontends/ast/genrtlil.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'frontends') diff --git a/frontends/ast/genrtlil.cc b/frontends/ast/genrtlil.cc index 5545fc16..9e186683 100644 --- a/frontends/ast/genrtlil.cc +++ b/frontends/ast/genrtlil.cc @@ -599,8 +599,8 @@ void AstNode::detectSignWidthWorker(int &width_hint, bool &sign_hint, bool *foun } else this_width = range->range_left - range->range_right + 1; sign_hint = false; - } else - width_hint = std::max(width_hint, this_width); + } + width_hint = std::max(width_hint, this_width); if (!id_ast->is_signed) sign_hint = false; break; -- cgit v1.2.3