aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--testsuite/gna/bug039/repro.vhdl16
-rwxr-xr-xtestsuite/gna/bug039/testsuite.sh10
2 files changed, 26 insertions, 0 deletions
diff --git a/testsuite/gna/bug039/repro.vhdl b/testsuite/gna/bug039/repro.vhdl
new file mode 100644
index 000000000..a27050c8d
--- /dev/null
+++ b/testsuite/gna/bug039/repro.vhdl
@@ -0,0 +1,16 @@
+entity repro is
+end repro;
+
+architecture behav of repro is
+ constant c1 : character := character'value("ack");
+ constant c2 : character := character'value("'Z'");
+ constant c3 : character := character'value("'a'");
+ constant c4 : boolean := boolean'value("TruE");
+ constant c5 : boolean := boolean'value("TruE ");
+ constant c6 : boolean := boolean'value(" TruE ");
+begin
+ assert c1 = ack report "value incorrect for ack" severity failure;
+ assert c2 = 'Z' report "value incorrect for 'Z'" severity failure;
+ assert c3 = 'a' report "value incorrect for 'a'" severity failure;
+ assert c4 and c5 and c6 severity failure;
+end behav;
diff --git a/testsuite/gna/bug039/testsuite.sh b/testsuite/gna/bug039/testsuite.sh
new file mode 100755
index 000000000..7da7af956
--- /dev/null
+++ b/testsuite/gna/bug039/testsuite.sh
@@ -0,0 +1,10 @@
+#! /bin/sh
+
+. ../../testenv.sh
+
+analyze repro.vhdl
+elab_simulate repro
+
+clean
+
+echo "Test successful"