diff options
author | Tristan Gingold | 2015-07-11 07:31:14 +0200 |
---|---|---|
committer | Tristan Gingold | 2015-07-11 07:31:14 +0200 |
commit | d12616d2738c6158654d9058fd788f5ec0306109 (patch) | |
tree | f5c0580e83f5325977988c6ed37d0a1640d6904e /testsuite | |
parent | 3756de36c89a5d8e3da0820c3de3d63af0e3f57a (diff) | |
download | ghdl-d12616d2738c6158654d9058fd788f5ec0306109.tar.gz ghdl-d12616d2738c6158654d9058fd788f5ec0306109.tar.bz2 ghdl-d12616d2738c6158654d9058fd788f5ec0306109.zip |
Add test for duplicate error message.
Diffstat (limited to 'testsuite')
-rw-r--r-- | testsuite/gna/bug16/pkg.vhdl | 2 | ||||
-rw-r--r-- | testsuite/gna/bug16/repro.vhdl | 29 | ||||
-rw-r--r-- | testsuite/gna/bug16/repro1.vhdl | 28 | ||||
-rw-r--r-- | testsuite/gna/bug16/repro2.vhdl | 18 | ||||
-rwxr-xr-x | testsuite/gna/bug16/testsuite.sh | 14 |
5 files changed, 91 insertions, 0 deletions
diff --git a/testsuite/gna/bug16/pkg.vhdl b/testsuite/gna/bug16/pkg.vhdl new file mode 100644 index 0000000..21c115a --- /dev/null +++ b/testsuite/gna/bug16/pkg.vhdl @@ -0,0 +1,2 @@ +package pkg is +end pkg; diff --git a/testsuite/gna/bug16/repro.vhdl b/testsuite/gna/bug16/repro.vhdl new file mode 100644 index 0000000..d82cc58 --- /dev/null +++ b/testsuite/gna/bug16/repro.vhdl @@ -0,0 +1,29 @@ +entity repro is +end repro; + +architecture behav of repro is + component comp is + port (s : bit); + end component; + signal s : bit; +begin + c : comp port map (s); +end behav; + +entity comp is + port (s : bit); +end comp; + +configuration conf of repro is + for behav + for c : comp + use entity work.compx (behav); + end for; + end for; +end conf; + +architecture behav of comp is +begin + assert s = '1'; +end behav; + diff --git a/testsuite/gna/bug16/repro1.vhdl b/testsuite/gna/bug16/repro1.vhdl new file mode 100644 index 0000000..6553079 --- /dev/null +++ b/testsuite/gna/bug16/repro1.vhdl @@ -0,0 +1,28 @@ +entity repro is +end repro; + +entity comp is + port (s : bit); +end comp; + +architecture behav of repro is + component comp is + port (s : bit); + end component; + signal s : bit; +begin + c : comp port map (s); +end behav; + +use work.pkg.all; +entity comp2 is + port (s : bit); +end comp2; + +architecture behav of comp is + component comp2 is + port (s : bit); + end component; +begin + c2: comp2 port map (s); +end behav; diff --git a/testsuite/gna/bug16/repro2.vhdl b/testsuite/gna/bug16/repro2.vhdl new file mode 100644 index 0000000..8691979 --- /dev/null +++ b/testsuite/gna/bug16/repro2.vhdl @@ -0,0 +1,18 @@ +configuration conf of repro is + for behav + for c : comp + use entity work.comp; + for behav + for c2 : comp2 + use entity work.comp2 (behav); + end for; + end for; + end for; + end for; +end conf; + +architecture behav of comp2 is +begin + assert s = '1'; +end behav; + diff --git a/testsuite/gna/bug16/testsuite.sh b/testsuite/gna/bug16/testsuite.sh new file mode 100755 index 0000000..5311492 --- /dev/null +++ b/testsuite/gna/bug16/testsuite.sh @@ -0,0 +1,14 @@ +#! /bin/sh + +. ../../testenv.sh + +analyze_failure repro.vhdl + +analyze pkg.vhdl +analyze repro1.vhdl +analyze pkg.vhdl +analyze_failure repro2.vhdl + +clean + +echo "Test successful" |