aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/synth/latch01/latch01.vhdl
blob: fc31d3cb1b59973df1bfea72388e9e0d77d0a9d1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
library ieee;
use ieee.std_logic_1164.all;

entity latch01 is
  port (q : out std_logic;
        d : std_logic;
        en : std_logic);
end latch01;

architecture behav of latch01 is
begin
  process (en, d) is
  begin
    if en = '1' then
      q <= d;
    end if;
  end process;
end behav;