diff options
author | Tristan Gingold | 2015-09-26 21:08:29 +0200 |
---|---|---|
committer | Tristan Gingold | 2015-09-26 21:08:29 +0200 |
commit | 15449f26754603d49ea2ba4f58a2b2f3495a6568 (patch) | |
tree | bb2282594d61d55cd23f5da6003554436fff2bd0 /testsuite | |
parent | 0f36f7436d0370abdc570afcd6c2eb46074da3b1 (diff) | |
download | ghdl-15449f26754603d49ea2ba4f58a2b2f3495a6568.tar.gz ghdl-15449f26754603d49ea2ba4f58a2b2f3495a6568.tar.bz2 ghdl-15449f26754603d49ea2ba4f58a2b2f3495a6568.zip |
Testcase from ticket96
Diffstat (limited to 'testsuite')
-rw-r--r-- | testsuite/gna/ticket96/ent.vhd | 30 | ||||
-rwxr-xr-x | testsuite/gna/ticket96/testsuite.sh | 10 |
2 files changed, 40 insertions, 0 deletions
diff --git a/testsuite/gna/ticket96/ent.vhd b/testsuite/gna/ticket96/ent.vhd new file mode 100644 index 0000000..d876cc1 --- /dev/null +++ b/testsuite/gna/ticket96/ent.vhd @@ -0,0 +1,30 @@ +entity ent is +end entity; + +architecture a of ent is + procedure proc( + constant seq : in string; + signal clk : in bit) is + begin + for i in seq'left to seq'right loop + report ("left=" & integer'image(seq'left) & + ", right=" & integer'image(seq'right) & + ", i=" & integer'image(i)); + report "seq(i)=" & character'image(seq(i)); + wait until rising_edge(clk); + end loop; + end procedure; + + signal clk : bit := '0'; +begin + + clk <= not clk after 1 ns; + main : process + variable var : string(1 to 10 - 1); + begin + var := (others => '0'); + proc(var & "0", clk); + wait; + end process; +end architecture; + diff --git a/testsuite/gna/ticket96/testsuite.sh b/testsuite/gna/ticket96/testsuite.sh new file mode 100755 index 0000000..604fe24 --- /dev/null +++ b/testsuite/gna/ticket96/testsuite.sh @@ -0,0 +1,10 @@ +#! /bin/sh + +. ../../testenv.sh + +GHDL_STD_FLAGS=--std=08 +analyze ent.vhd +elab_simulate ent --stop-time=10ns +clean + +echo "Test successful" |