From a22f41e442f1d82f7b18460f16844d5ce083d372 Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Mon, 22 Jan 2018 12:13:16 +0100 Subject: Add testcase for #521 --- testsuite/gna/issue521/pkg.vhdl | 3 +++ testsuite/gna/issue521/testsuite.sh | 16 ++++++++++++++++ testsuite/gna/issue521/tieee.vhdl | 10 ++++++++++ testsuite/gna/issue521/tieee2.vhdl | 5 +++++ 4 files changed, 34 insertions(+) create mode 100644 testsuite/gna/issue521/pkg.vhdl create mode 100755 testsuite/gna/issue521/testsuite.sh create mode 100644 testsuite/gna/issue521/tieee.vhdl create mode 100644 testsuite/gna/issue521/tieee2.vhdl diff --git a/testsuite/gna/issue521/pkg.vhdl b/testsuite/gna/issue521/pkg.vhdl new file mode 100644 index 000000000..ad1b62ba7 --- /dev/null +++ b/testsuite/gna/issue521/pkg.vhdl @@ -0,0 +1,3 @@ +package pkg is + constant cst : natural := 5; +end pkg; diff --git a/testsuite/gna/issue521/testsuite.sh b/testsuite/gna/issue521/testsuite.sh new file mode 100755 index 000000000..f5b4bfe61 --- /dev/null +++ b/testsuite/gna/issue521/testsuite.sh @@ -0,0 +1,16 @@ +#! /bin/sh + +. ../../testenv.sh + +# Check that it is possible to override ieee library +analyze --work=ieee pkg.vhdl + +analyze tieee.vhdl +elab_simulate tieee + +analyze_failure tieee2.vhdl + +clean +clean ieee + +echo "Test successful" diff --git a/testsuite/gna/issue521/tieee.vhdl b/testsuite/gna/issue521/tieee.vhdl new file mode 100644 index 000000000..4bbc48460 --- /dev/null +++ b/testsuite/gna/issue521/tieee.vhdl @@ -0,0 +1,10 @@ +library ieee; +use ieee.pkg.all; + +entity tieee is +end; + +architecture behav of tieee is +begin + assert cst = 5 severity failure; +end behav; diff --git a/testsuite/gna/issue521/tieee2.vhdl b/testsuite/gna/issue521/tieee2.vhdl new file mode 100644 index 000000000..abdd17d43 --- /dev/null +++ b/testsuite/gna/issue521/tieee2.vhdl @@ -0,0 +1,5 @@ +library ieee; +use ieee.std_logic_1164.all; + +entity tieee2 is +end; -- cgit v1.2.3