summaryrefslogtreecommitdiff
path: root/testsuite/gna/ticket9/index_range_test_B.vhd
blob: d28a358bdbd152ba4d392980c0059f99fae9b336 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
--
-- indexing testcase "B" derived from gna bug16782
--
--  ghdl-0.31-mcode on win32 : indexing off the end of a bit_vector results in an overflow exception message
--

entity index_range_test_B is 
end entity;

architecture arch of index_range_test_B is

 signal a    : bit_vector(15 downto 0);
 signal tmp  : bit;
 signal i    : integer;

 constant DATAPATH : natural := a'length;

begin

 i   <= DATAPATH + 3;

 tmp <= a(i);

end architecture;