aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/gna/bug086
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2018-02-27 06:59:52 +0100
committerTristan Gingold <tgingold@free.fr>2018-02-27 06:59:52 +0100
commit4d62517b8c26d9f86ba4daf4ee6a77d84c07bf12 (patch)
tree7687a1d6d82679c0d3406dc54bf26891832305d3 /testsuite/gna/bug086
parent48ab280fccb209c223259f8d4df339948c548539 (diff)
downloadghdl-4d62517b8c26d9f86ba4daf4ee6a77d84c07bf12.tar.gz
ghdl-4d62517b8c26d9f86ba4daf4ee6a77d84c07bf12.tar.bz2
ghdl-4d62517b8c26d9f86ba4daf4ee6a77d84c07bf12.zip
Add testcase.
Diffstat (limited to 'testsuite/gna/bug086')
-rw-r--r--testsuite/gna/bug086/sig.vhdl28
-rwxr-xr-xtestsuite/gna/bug086/testsuite.sh10
2 files changed, 38 insertions, 0 deletions
diff --git a/testsuite/gna/bug086/sig.vhdl b/testsuite/gna/bug086/sig.vhdl
new file mode 100644
index 000000000..20d75216e
--- /dev/null
+++ b/testsuite/gna/bug086/sig.vhdl
@@ -0,0 +1,28 @@
+entity sig is
+end;
+
+architecture behav of sig is
+ signal s : natural;
+ signal last : time;
+begin
+
+ s <= 1 after 20 ns;
+
+ b: block
+ port (q : boolean);
+ port map (q => s'quiet(10 ns));
+ begin
+ process (q)
+ begin
+ report "q is " & boolean'image (q);
+ last <= now;
+ end process;
+ end block;
+
+ process
+ begin
+ wait for 100 ns;
+ assert last = 30 ns severity failure;
+ wait;
+ end process;
+end;
diff --git a/testsuite/gna/bug086/testsuite.sh b/testsuite/gna/bug086/testsuite.sh
new file mode 100755
index 000000000..c28dcd1d1
--- /dev/null
+++ b/testsuite/gna/bug086/testsuite.sh
@@ -0,0 +1,10 @@
+#! /bin/sh
+
+. ../../testenv.sh
+
+analyze sig.vhdl
+elab_simulate sig
+
+clean
+
+echo "Test successful"