aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/gna/bug02/repro.vhdl
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/gna/bug02/repro.vhdl')
-rw-r--r--testsuite/gna/bug02/repro.vhdl29
1 files changed, 29 insertions, 0 deletions
diff --git a/testsuite/gna/bug02/repro.vhdl b/testsuite/gna/bug02/repro.vhdl
new file mode 100644
index 000000000..317d6c43f
--- /dev/null
+++ b/testsuite/gna/bug02/repro.vhdl
@@ -0,0 +1,29 @@
+entity repro is
+
+end repro;
+
+architecture behav of repro is
+ function inc (a : integer) return integer is
+ begin
+ return a + 1;
+ end inc;
+
+ function inc (a : time) return time is
+ begin
+ return a + 1 ns;
+ end inc;
+
+ procedure inc (a : inout integer) is
+ begin
+ a := inc (a);
+ end inc;
+begin -- behav
+
+ process
+ variable a : integer := 2;
+ begin
+ inc (a);
+ assert a = 3 report "bad value of a";
+ wait;
+ end process;
+end behav;