Make sure LPM expression is cast to the output type

This fixes some signed/unsigned bugs identified by the signedX tests.
This commit is contained in:
Nick Gasson 2008-09-02 19:02:54 +01:00
parent 1944f372c5
commit 122890fef4
1 changed files with 1 additions and 1 deletions

View File

@ -323,7 +323,7 @@ int draw_lpm(vhdl_arch *arch, ivl_lpm_t lpm)
out->set_slice(off, ivl_lpm_width(lpm) - 1);
}
arch->add_stmt(new vhdl_cassign_stmt(out, f));
arch->add_stmt(new vhdl_cassign_stmt(out, f->cast(out->get_type())));
return 0;
}