diff options
author | Tristan Gingold | 2014-01-08 21:15:58 +0100 |
---|---|---|
committer | Tristan Gingold | 2014-01-08 21:15:58 +0100 |
commit | 946b468a8143e94c329ed4a7b1a085221b3f5472 (patch) | |
tree | eda0986769ddab5f3365eaafd0f8d47471fda060 /testsuite/gna/bug20767/aggr.vhdl | |
parent | d0a2d9ebd5dc8aceb21e5528721cfb31d55ecad1 (diff) | |
download | ghdl-946b468a8143e94c329ed4a7b1a085221b3f5472.tar.gz ghdl-946b468a8143e94c329ed4a7b1a085221b3f5472.tar.bz2 ghdl-946b468a8143e94c329ed4a7b1a085221b3f5472.zip |
Rework implementation of -frelaxed-rules, add bug20767.
Diffstat (limited to 'testsuite/gna/bug20767/aggr.vhdl')
-rw-r--r-- | testsuite/gna/bug20767/aggr.vhdl | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/testsuite/gna/bug20767/aggr.vhdl b/testsuite/gna/bug20767/aggr.vhdl new file mode 100644 index 0000000..2fb3202 --- /dev/null +++ b/testsuite/gna/bug20767/aggr.vhdl @@ -0,0 +1,30 @@ +package pkg1 is + type int_arr is array (natural range <>) of integer; +end pkg1; + +use work.pkg1.all; + +package pkg2 is + function func (a : int_arr) return natural; +end pkg2; + +package body pkg2 is + function func (a : int_arr) return natural is + begin + return a'length; + end func; +end pkg2; + +entity tb is +end tb; + +use work.pkg2.all; + +architecture behav of tb is +begin + process + constant c : natural := func (a => (1, 2, 3)); + begin + wait; + end process; +end behav; |