nvc
nvc copied to clipboard
broken case statement choice coverage testing
library ieee;
use ieee.std_logic_1164.all;
entity test is
end test;
architecture fum of test is
signal foo : std_logic_vector(1 downto 0);
alias foo1 is foo(1);
alias foo0 is foo(0);
begin
dummy:
process is
begin
for i in foo'range loop -- range is 1 downto 0
case i is
when 0 =>
report "foo(0) = " & std_ulogic'image(foo0);
when 1 =>
report "foo(1) = " & std_ulogic'image(foo1);
end case;
end loop;
wait;
end process dummy;
end architecture fum;
Which gives:
nvc -a nvc_test.vhdl
** Error: case choices do not cover the following values of STD.STANDARD.NATURAL:
2 to 2147483647
File nvc_test.vhdl, Line 17
case i is ...
^^^^^^^^^^^^^