diff options
author | Tristan Gingold <tgingold@free.fr> | 2020-01-11 17:27:38 +0100 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2020-01-12 09:15:37 +0100 |
commit | 6782adcb601253cd9836302ba8be4ea500b7911e (patch) | |
tree | 925fc33c29665d8a67ad2988679a6acdf77fde3b /testsuite/synth/issue1083/test.vhdl | |
parent | 2448cf3ff2f3b723fdece48c953a9f4c9b585570 (diff) | |
download | ghdl-6782adcb601253cd9836302ba8be4ea500b7911e.tar.gz ghdl-6782adcb601253cd9836302ba8be4ea500b7911e.tar.bz2 ghdl-6782adcb601253cd9836302ba8be4ea500b7911e.zip |
testsuite/synth: add a test for #1083
Diffstat (limited to 'testsuite/synth/issue1083/test.vhdl')
-rw-r--r-- | testsuite/synth/issue1083/test.vhdl | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/testsuite/synth/issue1083/test.vhdl b/testsuite/synth/issue1083/test.vhdl new file mode 100644 index 000000000..a08c5872a --- /dev/null +++ b/testsuite/synth/issue1083/test.vhdl @@ -0,0 +1,24 @@ +library ieee; +use ieee.std_logic_1164.all; +use ieee.numeric_std.all; + +entity test is + port ( + a_in : in std_ulogic_vector(9 downto 0); + b_out : out std_ulogic + ); +end entity test; + +architecture behaviour of test is + type array_type_t is array(0 to 1023) of std_ulogic; + + constant ary : array_type_t := ( + 2#0000000010# => '1', + 2#0100000010# => '1', + 2#1000000010# => '1', + 2#1100000010# => '1', + others => '0' + ); +begin + b_out <= ary(to_integer(unsigned(a_in))); +end architecture behaviour; |