From fdd0d00d1a028e515191a76bcc028acbfc200c56 Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Sat, 25 Jul 2020 11:45:54 +0200 Subject: testsuite/gna: add a test for previous commit. --- testsuite/gna/bug0117/repro7.vhdl | 18 ++++++++++++++++++ testsuite/gna/bug0117/testsuite.sh | 3 +++ 2 files changed, 21 insertions(+) create mode 100644 testsuite/gna/bug0117/repro7.vhdl (limited to 'testsuite') diff --git a/testsuite/gna/bug0117/repro7.vhdl b/testsuite/gna/bug0117/repro7.vhdl new file mode 100644 index 000000000..c60b68580 --- /dev/null +++ b/testsuite/gna/bug0117/repro7.vhdl @@ -0,0 +1,18 @@ +entity repro7 is +end repro7; + +architecture behav of repro7 is + type my_rec is record + addr : bit_vector; + wr : boolean; + desc : string; + end record; + + constant v : my_rec (addr(0 downto 0)) := ( + addr => (others => '0'), + wr => true, + desc => "none"); +begin + assert v.wr; + assert v.desc = "none"; +end behav; diff --git a/testsuite/gna/bug0117/testsuite.sh b/testsuite/gna/bug0117/testsuite.sh index ac83ccfe4..bc39444ad 100755 --- a/testsuite/gna/bug0117/testsuite.sh +++ b/testsuite/gna/bug0117/testsuite.sh @@ -12,6 +12,9 @@ elab_simulate repro4 analyze repro5.vhdl elab_simulate repro5 +analyze repro7.vhdl +elab_simulate repro7 + clean echo "Test successful" -- cgit v1.2.3