Behavior should be identical now to rev. 0b4a64ac6adbd6 (next: testing before constfo...
[yosys.git] / frontends / ast / genrtlil.cc
index a4e01899c263b254a6b1b97aa6790221c1a47a7a..ff4841ec4472abef669517e7ec3d7090ccf74dbe 100644 (file)
@@ -570,6 +570,8 @@ void AstNode::detectSignWidthWorker(int &width_hint, bool &sign_hint)
                                this_width = range->range_left - range->range_right + 1;
                } else
                        width_hint = std::max(width_hint, this_width);
+               if (!id2ast->is_signed)
+                       sign_hint = false;
                break;
 
        case AST_TO_SIGNED: