diff options
Diffstat (limited to 'frontends')
| -rw-r--r-- | frontends/ast/ast.cc | 2 | 
1 files changed, 1 insertions, 1 deletions
diff --git a/frontends/ast/ast.cc b/frontends/ast/ast.cc index 5a2ade04a..91001c70d 100644 --- a/frontends/ast/ast.cc +++ b/frontends/ast/ast.cc @@ -847,7 +847,7 @@ RTLIL::Const AstNode::bitsAsConst(int width, bool is_signed)  		bits.resize(width);  	if (width >= 0 && width > int(bits.size())) {  		RTLIL::State extbit = RTLIL::State::S0; -		if (is_signed && !bits.empty()) +		if ((is_signed || is_unsized) && !bits.empty())  			extbit = bits.back();  		while (width > int(bits.size()))  			bits.push_back(extbit);  | 
