From 48dc55952df05c12e407eb74ced73f62f4d366d2 Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Fri, 3 Dec 2021 18:23:20 +0100 Subject: testsuite/gna: add a test for conformance rules --- testsuite/gna/bug0126/repro.vhdl | 15 +++++++++++++++ testsuite/gna/bug0126/testsuite.sh | 9 +++++++++ 2 files changed, 24 insertions(+) create mode 100644 testsuite/gna/bug0126/repro.vhdl create mode 100755 testsuite/gna/bug0126/testsuite.sh diff --git a/testsuite/gna/bug0126/repro.vhdl b/testsuite/gna/bug0126/repro.vhdl new file mode 100644 index 000000000..eeb770897 --- /dev/null +++ b/testsuite/gna/bug0126/repro.vhdl @@ -0,0 +1,15 @@ +entity repro is +end repro; + +architecture behav of repro is + subtype data_word_t is bit_vector (31 downto 0); + + function f1 (data : data_word_t) return bit; + + function f1 (data : bit_vector(31 downto 0)) return bit is + begin + return '0'; + end f1; + +begin +end behav; diff --git a/testsuite/gna/bug0126/testsuite.sh b/testsuite/gna/bug0126/testsuite.sh new file mode 100755 index 000000000..5defdcf1e --- /dev/null +++ b/testsuite/gna/bug0126/testsuite.sh @@ -0,0 +1,9 @@ +#! /bin/sh + +. ../../testenv.sh + +analyze_failure repro.vhdl + +clean + +echo "Test successful" -- cgit v1.2.3