diff options
Diffstat (limited to 'testsuite')
-rw-r--r-- | testsuite/gna/issue637/example.vhdl | 16 | ||||
-rwxr-xr-x | testsuite/gna/issue637/testsuite.sh | 11 |
2 files changed, 27 insertions, 0 deletions
diff --git a/testsuite/gna/issue637/example.vhdl b/testsuite/gna/issue637/example.vhdl new file mode 100644 index 000000000..d13664393 --- /dev/null +++ b/testsuite/gna/issue637/example.vhdl @@ -0,0 +1,16 @@ +entity example is +end entity; + +architecture tb of example is + type arrType is array (1 downto 0) of integer; + type arrTypePtr is access arrType; +begin + process (all) + variable ptr : arrTypePtr; + begin + ptr := new arrType'(10, 5); -- works + ptr.all(0) := 5; -- crash + ptr(0) := 5; --crash + end process; + +end architecture; diff --git a/testsuite/gna/issue637/testsuite.sh b/testsuite/gna/issue637/testsuite.sh new file mode 100755 index 000000000..9cc19eab3 --- /dev/null +++ b/testsuite/gna/issue637/testsuite.sh @@ -0,0 +1,11 @@ +#! /bin/sh + +. ../../testenv.sh + +export GHDL_STD_FLAGS=--std=08 +analyze example.vhdl +elab_simulate example + +clean + +echo "Test successful" |