diff options
author | Tristan Gingold <tgingold@free.fr> | 2022-10-10 18:20:39 +0200 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2022-10-10 18:20:39 +0200 |
commit | f2c863f7e030796cb325885654ffe3e945f35198 (patch) | |
tree | 319d452db49cb1e002265f5e9393f1a8d47e65f2 /testsuite/gna | |
parent | 5726f0eccf874b872ce0729aab42f587d915a3f5 (diff) | |
download | ghdl-f2c863f7e030796cb325885654ffe3e945f35198.tar.gz ghdl-f2c863f7e030796cb325885654ffe3e945f35198.tar.bz2 ghdl-f2c863f7e030796cb325885654ffe3e945f35198.zip |
testsuite/gna: add a test for #2212
Diffstat (limited to 'testsuite/gna')
-rw-r--r-- | testsuite/gna/issue2212/minimal.vhdl | 22 | ||||
-rwxr-xr-x | testsuite/gna/issue2212/testsuite.sh | 11 |
2 files changed, 33 insertions, 0 deletions
diff --git a/testsuite/gna/issue2212/minimal.vhdl b/testsuite/gna/issue2212/minimal.vhdl new file mode 100644 index 000000000..82f034123 --- /dev/null +++ b/testsuite/gna/issue2212/minimal.vhdl @@ -0,0 +1,22 @@ +library IEEE; + use IEEE.std_logic_1164.all; + use IEEE.numeric_std.all; + +entity minimal is + port( + duty_cycle: in std_logic_vector(7 downto 0) + ); +end entity minimal; + +architecture rtl of minimal is + +begin + + DECIDE_STATE: process(all) is +--DECIDE_STATE: process(duty_cycle) is -- uncomment to run + variable duty : boolean; + begin + duty := true when signed(duty_cycle) > 0 else false; + end process; + +end architecture rtl; diff --git a/testsuite/gna/issue2212/testsuite.sh b/testsuite/gna/issue2212/testsuite.sh new file mode 100755 index 000000000..2865dbca5 --- /dev/null +++ b/testsuite/gna/issue2212/testsuite.sh @@ -0,0 +1,11 @@ +#! /bin/sh + +. ../../testenv.sh + +export GHDL_STD_FLAGS=--std=08 +analyze minimal.vhdl +elab_simulate minimal + +clean + +echo "Test successful" |