程序段如下:
LIBRARY IEEE;
USE IEEE.STD_LOGIC_1164.ALL;
ENTITY andn IS
GENERIC(n:INTEGER);
PORT(a:IN STD_LOGIC_VECTER(n-1 DOWNTO 0);
c:OUT STD_LOGIC);
END andn;
ARCHITECTURE behav OF andn IS
BEGIN
PROCESS(a)
VARIABLE int: STD_LOGIC;
BEGIN
int:='1';
FOR I IN a'LENGTH-1 DOWNTO 0 LOOP
IF a(i)='0'THEN int:='0';
END IF;
END LOOP;
c<=int;
END PROCESS;
END behav;
程序段中下划线处不明白:哪位哥哥姐姐帮忙解释以下,十分感谢 |