aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/synth/issue1460/rightmost01.vhdl
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2020-09-19 09:53:09 +0200
committerTristan Gingold <tgingold@free.fr>2020-09-19 09:53:09 +0200
commit1337962c251723acaf021a8df2efbc261804f88a (patch)
treec0db2bfd47044a576f8cc519783275f9606e17c5 /testsuite/synth/issue1460/rightmost01.vhdl
parent2fb5d3fa8e642f5f268f106a99af771e2076c8d2 (diff)
downloadghdl-1337962c251723acaf021a8df2efbc261804f88a.tar.gz
ghdl-1337962c251723acaf021a8df2efbc261804f88a.tar.bz2
ghdl-1337962c251723acaf021a8df2efbc261804f88a.zip
testsuite/synth: add tests for find_leftmost/find_rightmost.
For #1460
Diffstat (limited to 'testsuite/synth/issue1460/rightmost01.vhdl')
-rw-r--r--testsuite/synth/issue1460/rightmost01.vhdl14
1 files changed, 14 insertions, 0 deletions
diff --git a/testsuite/synth/issue1460/rightmost01.vhdl b/testsuite/synth/issue1460/rightmost01.vhdl
new file mode 100644
index 000000000..30ae1c64b
--- /dev/null
+++ b/testsuite/synth/issue1460/rightmost01.vhdl
@@ -0,0 +1,14 @@
+library ieee;
+use ieee.std_logic_1164.all;
+use ieee.numeric_std.all;
+
+entity rightmost01 is
+ port (d : unsigned (7 downto 0);
+ res : out integer);
+end rightmost01;
+
+architecture behav of rightmost01 is
+begin
+ res <= find_rightmost (d, '1');
+end behav;
+