From 1b789a5fb8b11e7c378731589d9cb54a8f53c27f Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Wed, 29 Jul 2020 07:49:00 +0200 Subject: testsuite/gna: add a reproducer for #1415 --- testsuite/gna/issue1415/repro.vhdl | 27 +++++++++++++++++++++++++++ testsuite/gna/issue1415/testsuite.sh | 11 +++++++++++ 2 files changed, 38 insertions(+) create mode 100644 testsuite/gna/issue1415/repro.vhdl create mode 100755 testsuite/gna/issue1415/testsuite.sh (limited to 'testsuite/gna/issue1415') diff --git a/testsuite/gna/issue1415/repro.vhdl b/testsuite/gna/issue1415/repro.vhdl new file mode 100644 index 000000000..b1ff6d94c --- /dev/null +++ b/testsuite/gna/issue1415/repro.vhdl @@ -0,0 +1,27 @@ +package repro_pkg is + type wishbone_type is record + data : bit_vector; + stb : bit; + end record; +end; + +entity reprob is + port (b : bit_vector); +end; + +architecture behav of reprob is +begin + assert b'length = 4; +end; + +use work.repro_pkg.all; + +entity repro is +end repro; + +architecture behav of repro is + signal s : wishbone_type (data(3 downto 0)); +begin + dut: entity work.reprob + port map (b => s.data); +end behav; diff --git a/testsuite/gna/issue1415/testsuite.sh b/testsuite/gna/issue1415/testsuite.sh new file mode 100755 index 000000000..8d22a2073 --- /dev/null +++ b/testsuite/gna/issue1415/testsuite.sh @@ -0,0 +1,11 @@ +#! /bin/sh + +. ../../testenv.sh + +export GHDL_STD_FLAGS=--std=08 +analyze repro.vhdl +elab_simulate repro + +clean + +echo "Test successful" -- cgit v1.2.3