From eff68560a2914791c8d0377edb5922fd5077f4f3 Mon Sep 17 00:00:00 2001 From: Clifford Wolf Date: Sun, 7 Jul 2013 15:40:26 +0200 Subject: [PATCH] Fixed AST_CONSTANT node generation --- frontends/ast/ast.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontends/ast/ast.cc b/frontends/ast/ast.cc index f7a39cf19..3e9ea50ac 100644 --- a/frontends/ast/ast.cc +++ b/frontends/ast/ast.cc @@ -661,7 +661,7 @@ AstNode *AstNode::mkconst_bits(const std::vector &v, bool is_signe node->integer |= (node->bits.back() == RTLIL::S1) << i; } node->range_valid = true; - node->range_left = node->bits.size(); + node->range_left = node->bits.size()-1; node->range_right = 0; return node; }