aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2015-01-20 15:22:19 +0100
committerTristan Gingold <tgingold@free.fr>2015-01-20 15:22:19 +0100
commit057fe02c3e99bee64cea06c057afc2d50732baad (patch)
tree8d8bbdaae16d2667c0df2d9d5f116edfd052df9d
parent4b6f841fcd09ce8f0a80e87d4031d9417c0eabb5 (diff)
downloadghdl-057fe02c3e99bee64cea06c057afc2d50732baad.tar.gz
ghdl-057fe02c3e99bee64cea06c057afc2d50732baad.tar.bz2
ghdl-057fe02c3e99bee64cea06c057afc2d50732baad.zip
Add bug07 testcase (locally discrete array compare).
-rw-r--r--testsuite/gna/bug07/repro.vhdl21
-rwxr-xr-xtestsuite/gna/bug07/testsuite.sh10
2 files changed, 31 insertions, 0 deletions
diff --git a/testsuite/gna/bug07/repro.vhdl b/testsuite/gna/bug07/repro.vhdl
new file mode 100644
index 000000000..89d6f2924
--- /dev/null
+++ b/testsuite/gna/bug07/repro.vhdl
@@ -0,0 +1,21 @@
+entity repro is
+end repro;
+
+architecture behav of repro is
+ type int_vector is array (natural range <>) of integer;
+
+ constant c1 : int_vector (0 to 1) := 12 & 13;
+ constant c2 : int_vector (0 to 1) := 14 & 15;
+ constant p : boolean := c1 = c2;
+ constant p1 : boolean := c1 < c2;
+begin
+ process
+ begin
+ case true is
+ when p => null;
+ when true => null;
+ end case;
+ wait;
+ end process;
+end behav;
+
diff --git a/testsuite/gna/bug07/testsuite.sh b/testsuite/gna/bug07/testsuite.sh
new file mode 100755
index 000000000..7da7af956
--- /dev/null
+++ b/testsuite/gna/bug07/testsuite.sh
@@ -0,0 +1,10 @@
+#! /bin/sh
+
+. ../../testenv.sh
+
+analyze repro.vhdl
+elab_simulate repro
+
+clean
+
+echo "Test successful"